File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -234,15 +234,15 @@ void QgsBookmarks::zoomToBookmark()
234
234
double ymin = index .sibling ( index .row (), 4 ).data ().toDouble ();
235
235
double xmax = index .sibling ( index .row (), 5 ).data ().toDouble ();
236
236
double ymax = index .sibling ( index .row (), 6 ).data ().toDouble ();
237
- int srid = index .sibling ( index .row (), 7 ).data ().toInt ();
237
+ QString authid = index .sibling ( index .row (), 7 ).data ().toString ();
238
238
239
239
QgsRectangle rect = QgsRectangle ( xmin, ymin, xmax, ymax );
240
240
241
241
// backwards compatibility, older version had -1 in the srid column
242
- if ( srid > 0 &&
243
- srid != QgisApp::instance ()->mapCanvas ()->mapSettings ().destinationCrs ().srsid () )
242
+ if ( ! authid. isEmpty ( ) &&
243
+ authid != QgisApp::instance ()->mapCanvas ()->mapSettings ().destinationCrs ().authid () )
244
244
{
245
- QgsCoordinateTransform ct ( QgsCoordinateReferenceSystem::fromSrsId ( srid ),
245
+ QgsCoordinateTransform ct ( QgsCoordinateReferenceSystem::fromOgcWmsCrs ( authid ),
246
246
QgisApp::instance ()->mapCanvas ()->mapSettings ().destinationCrs () );
247
247
rect = ct.transform ( rect );
248
248
if ( rect.isEmpty () )
You can’t perform that action at this time.
0 commit comments