[kepler-dev] Kepler/Ptolemy on the Mac

Matt Jones jones at nceas.ucsb.edu
Thu May 13 10:54:12 PDT 2004


Dan,

What became of your inquiry into using the apple command key instead of 
the control key on the mac for all modifier operations?  As Mac 
generally uses this command modifier, it seems like the right think to 
do, which would then free up the control key modifier to act in the 
Mac-standard way to get the context menu.  There must be a way to 
automattically map all cntrl funcitons in ptolemy to command functions 
when on the mac.

Matt

higgins at nceas.ucsb.edu wrote:

> Hi All,
> 
> I have been investigating the use of Kepler/Ptolemy on the Mac. I did find
> some threads on Mac use (especial concerning the single button mouse), but I
> was still having some problems. In particular, one can find in the
> 'ActorEditorGraphController' class the code fragment
> 
>         if (UIManager.getLookAndFeel().getName().startsWith("MacOS")) {
>             // On the Mac, do not override Control-Click, which is
>             // used to bring up the context menu
>             _linkCreator.setMouseFilter(_metaFilter);
>         } else {
>             _linkCreator.setMouseFilter(_controlFilter);
>         }
> 
> Note the 'getName()' call and the string comparison to "MacOS". Unfortunately,
> a test on my Mac (OS version 10.3.3) shows that the getName method returns 
> "Mac OS X Aqua" (note the spaces!). Due to the spaces, the names do not match 
> and the Mac is NEVER detected!
> 
> Apple suggests in their tech note 2042 (http://developer.apple.com/
> documentation/Java/Conceptual/Java131Development/x_platform/
> chapter_5_section_5.html) that the statement
> 
> System.getProperty("mrj.version")
> 
> should be used to detect a mac, with any non-null result indicating that the 
> machine is a mac. This approach is independent of the string value which may 
> change.
> 
> I did try changing the Kepler code to correct this detection problem. I was 
> able to get it to properly detect my Mac, but it still does not popup the 
> context menu using the control key + click. Anyone have any ideas?
> 
> Incidently, a 2 button mouse plugged into the Mac USB port does work OK with 
> current code.
> 
> Dan Higgins
> NCEAS
> 
> 
> -------------------------------------------------
> This mail sent through IMP: http://horde.org/imp/
> _______________________________________________
> kepler-dev mailing list
> kepler-dev at ecoinformatics.org
> http://www.ecoinformatics.org/mailman/listinfo/kepler-dev






More information about the Kepler-dev mailing list