Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 2184f63

Browse files
committed
Merge pull request #5108 from ordirules/viewfix
MNT: remove dead code
2 parents 15b8629 + 1249ec6 commit 2184f63

3 files changed

Lines changed: 3 additions & 9 deletions

File tree

lib/matplotlib/axes/_base.py

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3305,7 +3305,7 @@ def _set_view(self, view):
33053305
self.set_xlim((xmin, xmax))
33063306
self.set_ylim((ymin, ymax))
33073307

3308-
def _set_view_from_bbox(self, bbox, original_view, direction='in',
3308+
def _set_view_from_bbox(self, bbox, direction='in',
33093309
mode=None, twinx=False, twiny=False):
33103310
"""
33113311
Update view from a selection bbox.
@@ -3321,10 +3321,6 @@ def _set_view_from_bbox(self, bbox, original_view, direction='in',
33213321
bbox : tuple
33223322
The selected bounding box limits, in *display* coordinates.
33233323
3324-
original_view : any
3325-
A view saved from before initiating the selection, the result of
3326-
calling :meth:`_get_view`.
3327-
33283324
direction : str
33293325
The direction to apply the bounding box.
33303326
* `'in'` - The bounding box describes the view directly, i.e.,
@@ -3345,8 +3341,6 @@ def _set_view_from_bbox(self, bbox, original_view, direction='in',
33453341

33463342
lastx, lasty, x, y = bbox
33473343

3348-
x0, y0, x1, y1 = original_view
3349-
33503344
# zoom to rect
33513345
inverse = self.transData.inverted()
33523346
lastx, lasty = inverse.transform_point((lastx, lasty))

lib/matplotlib/backend_bases.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3076,7 +3076,7 @@ def release_zoom(self, event):
30763076
else:
30773077
continue
30783078

3079-
a._set_view_from_bbox((lastx, lasty, x, y), view, direction,
3079+
a._set_view_from_bbox((lastx, lasty, x, y), direction,
30803080
self._zoom_mode, twinx, twiny)
30813081

30823082
self.draw()

lib/matplotlib/backend_tools.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -777,7 +777,7 @@ def _release(self, event):
777777
else:
778778
continue
779779

780-
a._set_view_from_bbox((lastx, lasty, x, y), view, direction,
780+
a._set_view_from_bbox((lastx, lasty, x, y), direction,
781781
self._zoom_mode, twinx, twiny)
782782

783783
self._zoom_mode = None

0 commit comments

Comments
 (0)