Skip to content

Commit

Permalink
Fix zoom full
Browse files Browse the repository at this point in the history
  • Loading branch information
ValentinBuira committed Nov 19, 2024
1 parent cdb2d43 commit 53ad133
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion Mergin/version_viewer_dialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -620,7 +620,12 @@ def add_all_to_project(self):

def zoom_full(self):
if self.current_diff:
self.map_canvas.setExtent(self.current_diff.extent())

layerExtent = self.current_diff.extent()
# transform extent
layerExtent = self.map_canvas.mapSettings().layerExtentToOutputExtent( self.current_diff, layerExtent );

self.map_canvas.setExtent(layerExtent)
self.map_canvas.refresh()

def zoom_selected(self):
Expand Down

0 comments on commit 53ad133

Please sign in to comment.