@@ -376,8 +376,11 @@ def mouseMoveEvent(self, event):
376
376
if self .mouse_dragging and not self .transform_mode :
377
377
self .original_clip_data = self .transforming_clip .data
378
378
379
+ # Mouse over resize button (and not currently dragging)
380
+ if not self .mouse_dragging and self .resize_button .isVisible () and self .resize_button .rect ().contains (event .pos ()):
381
+ self .setCursor (Qt .ArrowCursor )
379
382
# Determine if cursor is over a handle
380
- if self .transform .mapToPolygon (self .centerHandle .toRect ()).containsPoint (event .pos (), Qt .OddEvenFill ):
383
+ elif self .transform .mapToPolygon (self .centerHandle .toRect ()).containsPoint (event .pos (), Qt .OddEvenFill ):
381
384
if not self .transform_mode or self .transform_mode == 'origin' :
382
385
self .setCursor (self .rotateCursor (self .cursors .get ('hand' ), rotation , shear_x , shear_y ))
383
386
# Set the transform mode
@@ -734,16 +737,12 @@ def delayed_resize_callback(self):
734
737
735
738
# Capture wheel event to alter zoom/scale of widget
736
739
def wheelEvent (self , event ):
737
- if int (QCoreApplication .instance ().keyboardModifiers () & Qt .ControlModifier ) > 0 :
738
- # For each 120 (standard scroll unit) adjust the zoom slider
739
- tick_scale = 1024
740
- self .zoom += event .angleDelta ().y () / tick_scale
741
- if self .zoom <= 0.0 :
742
- # Don't allow zoom to go all the way to zero (or negative)
743
- self .zoom = 0.05
744
- else :
745
- # Otherwise pass on to implement default functionality (scroll in QWebView)
746
- super (type (self ), self ).wheelEvent (event )
740
+ # For each 120 (standard scroll unit) adjust the zoom slider
741
+ tick_scale = 1024
742
+ self .zoom += event .angleDelta ().y () / tick_scale
743
+ if self .zoom <= 0.0 :
744
+ # Don't allow zoom to go all the way to zero (or negative)
745
+ self .zoom = 0.05
747
746
748
747
# Add resize button (if not 100% zoom)
749
748
if self .zoom != 1.0 :
@@ -801,6 +800,7 @@ def __init__(self, *args):
801
800
self .resize_button .hide ()
802
801
self .resize_button .setStyleSheet ('QPushButton { margin: 10px; padding: 2px; }' )
803
802
self .resize_button .clicked .connect (self .resize_button_clicked )
803
+ self .resize_button .setMouseTracking (True )
804
804
805
805
# Initialize cursors
806
806
self .cursors = { "move" : QPixmap (os .path .join (info .IMAGES_PATH , "cursor_move.png" )),
0 commit comments