Author: johannes
Date: 2006-08-29 09:43:41 -0500 (Tue, 29 Aug 2006)
New Revision: 8641

Modified:
   branches/forms-0.5/src/uidrivers/wx26/widgets/entry.py
Log:
Block the mouse-wheel-event in dropdowns on msw


Modified: branches/forms-0.5/src/uidrivers/wx26/widgets/entry.py
===================================================================
--- branches/forms-0.5/src/uidrivers/wx26/widgets/entry.py      2006-08-28 
16:29:15 UTC (rev 8640)
+++ branches/forms-0.5/src/uidrivers/wx26/widgets/entry.py      2006-08-29 
14:43:41 UTC (rev 8641)
@@ -165,6 +165,7 @@
     # On Mac we don't bind the button release event, as it does not get fired
     if 'wxMSW' in wx.PlatformInfo:
         item.Bind(wx.EVT_KEY_DOWN, self.__on_key_down)
+        item.Bind(wx.EVT_MOUSEWHEEL, self.__on_cbx_wheel)
 
     elif not 'wxMac' in wx.PlatformInfo:
       item.Bind (wx.EVT_LEFT_UP, self.__leftMouseUp)
@@ -383,9 +384,16 @@
       else:
           event.Skip()
     
+  # ---------------------------------------------------------------------------
 
+  def __on_cbx_wheel(self, event):
 
+      # On wx.MSW we stop the propagation of a mouse wheel event here, to
+      # prevent it from changing options in dropdowns
+      event.StopPropagation()
 
+
+
 # =============================================================================
 # Configuration
 # =============================================================================



_______________________________________________
commit-gnue mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/commit-gnue

Reply via email to