[BUG][FIX] inconsistent mouse button definitions
Ned Konz
ned at bike-nomad.com
Wed Oct 18 17:08:32 UTC 2000
Using the latest 2.9a stuff.
In EventSensor>>initializeEventSensorConstants (cs 2494)
we initialize the pool EventSensorConstants with:
#(#RedButtonBit 4)
#(#BlueButtonBit 2)
#(#YellowButtonBit 1)
Now, these are only used (AFAICT) in
EventSensor>>mapButtons:modifiers: to generate the
shift- or option- mouse buttons.
But the code elsewhere in the system (that is, xxxButtonPressed
in InputSensor and MorphicEvent) defines:
red button = 4
blue button = 1
yellow button = 2
Shouldn't these be the same definitions for blue and yellow?
And shouldn't the xxxButtonPressed functions use the constants
in EventSensorConstants so this doesn't happen? (and so I can
swap the mouse buttons easily)
Well, I thought so.
Enclosed is a fix for this that also allows swapping yellow/blue
mouse buttons.
--
Ned Konz
currently: Stanwood, WA
email: ned at bike-nomad.com
homepage: http://bike-nomad.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: FixMouseButtons-nk.1.cs
Type: application/octet-stream
Size: 4234 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20001018/22b12941/FixMouseButtons-nk.1.obj
More information about the Squeak-dev
mailing list
|