Mouse Buttons and Modifier Keys (was Yellow Button and Morphic)

Maloney johnm at wdi.disney.com
Fri May 29 17:20:56 UTC 1998


Hi, Bill.

Re:
At 11:33 AM -0400 5/29/98, William O. Dargel wrote:
>Where should I be looking to get a perspective on how input events,
>particularly the mouse, are handled with Morphic?

Look at the event-handling code in HandMorph.


Re:
>One thing that I noticed: it looks like any mouse button will act like
>the "yellow" one if the "Option" key is pressed. Trouble is, I don't
>have an option key. As I recall, that's something that's on the Mac?
>Does the Mac still sport a single button mouse? Sorry, I'm culturally
>deprived ;-)

The Smalltalk image from which Squeak is derived was designed to
run with a three-button mouse on an Alto or Dorado computer. These
buttons were known as "red", "blue", and "yellow", and some
mice really had buttons of these colors.

Win32 machines have only two mouse buttons, so the mapping is:
	left-mouse		-> "red"
	alt-left-mouse		-> "blue"
	right-mouse		-> "yellow"

The Mac has only a single button, so the mapping is:
	mouse			-> "red"
	cmd-mouse		-> "blue"
	option-mouse		-> "yellow"

I believe the mapping of modifier keys is:
	Mac	Win32	Unix
	shift	shift	shift
	ctrl	ctrl	ctrl
	cmd	alt	meta(?)
	option	---	---

I don't believe there is any Win32 or Unix equivalent of
the option key. Andreas and Ian, please correct me
if I'm wrong. If that's the case, the option key should
be used only to simulate the yellow button on the Mac,
and should not be tested for directly, since functions that
depend on the option key would not be accessible on other
platforms. Unfortunately, this is not the case right now--
we do have some code that tests for the option key.


Re:
>On a more general note: Are there any efforts going on that are related
>to making the user input interface more easily configured or customized,
>without the need to change methods in the base system?

Not that I know of.

	-- John





More information about the Squeak-dev mailing list