Re: MouseEvent, control key, and Macintosh




"Peter Duniho" <NpOeStPeAdM@xxxxxxxxxxxxxxxx> wrote in message
news:op.t4zfrrvb8jd0ej@xxxxxxxxxxxxxxxxxxxxxxx
On Tue, 15 Jan 2008 07:20:24 -0800, Larry A Barowski
<ThisisLarrybarAtEngDotAuburnDotLearninginstitution> wrote:

You shouldn't directly reference the Ctrl key for most anything.

Um...I should, and do, when it's specifically the control key I care
about.

If you use "Shift", "Alt", and the menu shortcut key, you will get
three useable modifier keys on Windows, Mac, and most UNIX/
Linux systems.

Use Toolkit.getDefaultToolkit().getMenuShortcutKeyMask() .

That's fine if I want to react with a menu. But I don't.

This is the "Apple" key on a Mac.

On my Mac, the menu shortcut key is the control key. Are you telling me
that not only is Java blocking mouse dragging feedback when the control
key is down, it incorrectly uses the Apple (Command) key as the menu
shortcut key as well?

getMenuShortcutKeyMask() will return the mask for whichever key
you have mapped to the "Command" action. By default, that is the
"Command" key.

Mac. users will not expect the Ctrl key to
act as a menu shortcut control key,

I don't want them to, though I have to tell you that speaking as a Mac
user whose Mac pops up a context menu when you click with the control key
held down, I think you're wrong about at least some Mac users. In
applications that do have menus, I do expect the control key to act as a
menu shortcut key.

I'm not sure what you're saying here. All of the applications
that I use on a Mac use the key mapped to the Command
action, and only that key, as a menu shortcut key. The only
exceptions I've seen are poorly written Java apps.

or, I suppose, to act as a
flag while dragging as you are using it.

Why not? The control key is a common enough modifier for dragging in
other contexts. Even if it weren't, I have a very simple program that
pretty much only uses dragging gestures from the mouse for input. There
are no menus at all (see my previous reply), so it would be hard to
understand why a user of the program might incorrectly expect a context
menu to show up when they use the control key while clicking the mouse.

I take it that you too do not have an actual answer?

No, I don't know if there is a way to disable the Control key
behavior on Apple's Java implementation. If you find the option
of using a different key unacceptable for some reason, then I
can't help you.


.



Relevant Pages

  • Re: Should I buy an Apple or Windows
    ... Anyway, the problem was that you had to either do it the Apple way, ... which was hold the control key and click, ... Yes the Mac had contextual menus with system 7. ...
    (comp.sys.mac.apps)
  • Re: MouseEvent, control key, and Macintosh
    ... Are you telling me that not only is Java blocking mouse dragging feedback when the control key is down, it incorrectly uses the Apple key as the menu shortcut key as well? ... I don't want them to, though I have to tell you that speaking as a Mac user whose Mac pops up a context menu when you click with the control key held down, I think you're wrong about at least some Mac users. ...
    (comp.lang.java.programmer)
  • Re: How to make Commandbutton caption
    ... Hold down the Control Key or the Command Key while you click the button. ... > this but the Mac mouse has no right click. ... Prev by Date: ...
    (microsoft.public.mac.office.excel)
  • Re: Page number
    ... Just remember that the Control key on the PC is the same as the Command ... Mac Word FAQ: ... Entourage Help Page: ...
    (microsoft.public.mac.office.word)
  • Re: New to Office for MAC
    ... Re the interface differences-- ... The main shortcut key change from Win to Mac is that you use the apple key ... 90% of the time switching the cmd key for the control key will do what you ... under Word | Preferences, or Excel | Preferences. ...
    (microsoft.public.mac.office)