Allow ComboList/Box selection with the mouse wheel
authorStefan Vogel <sv@exept.de>
Fri, 11 Jan 2008 20:30:52 +0100
changeset 3311 0899e8423c9a
parent 3310 1d51f262dbe4
child 3312 ad1dcdaa7ba7
Allow ComboList/Box selection with the mouse wheel
ComboBoxView.st
--- a/ComboBoxView.st	Fri Jan 11 10:03:58 2008 +0100
+++ b/ComboBoxView.st	Fri Jan 11 20:30:52 2008 +0100
@@ -233,6 +233,7 @@
      all of my input goes to the enterfield
     "
     self delegate:(KeyboardForwarder toView:field).
+    field delegate:self.    "delegate mouseWheel events to myself"
 
     menuSelectAction := [:menuValue | field contents:menuValue].
 
@@ -292,6 +293,7 @@
     pullDownButton turnOff.
 
     what := list at:index.
+    currentIndex := index.
 
     menuSelectAction value:what.
     field accept.
@@ -306,5 +308,5 @@
 !ComboBoxView class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libwidg2/ComboBoxView.st,v 1.29 2007-03-06 20:43:23 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg2/ComboBoxView.st,v 1.30 2008-01-11 19:30:52 stefan Exp $'
 ! !