jdk/src/solaris/classes/sun/awt/motif/MToolkit.java
changeset 2810 fa49c6a06baf
parent 2465 1a6452b990cf
child 3928 be186a33df9b
equal deleted inserted replaced
2809:b373581f6507 2810:fa49c6a06baf
     1 /*
     1 /*
     2  * Copyright 1995-2007 Sun Microsystems, Inc.  All Rights Reserved.
     2  * Copyright 1995-2009 Sun Microsystems, Inc.  All Rights Reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.  Sun designates this
     7  * published by the Free Software Foundation.  Sun designates this
   622 
   622 
   623         return Boolean.valueOf(nativeDynamic);
   623         return Boolean.valueOf(nativeDynamic);
   624     }
   624     }
   625 
   625 
   626     private native int getMulticlickTime();
   626     private native int getMulticlickTime();
   627     private native int getNumMouseButtons();
       
   628 
   627 
   629     protected void initializeDesktopProperties() {
   628     protected void initializeDesktopProperties() {
   630         desktopProperties.put("DnD.Autoscroll.initialDelay",     Integer.valueOf(50));
   629         desktopProperties.put("DnD.Autoscroll.initialDelay",     Integer.valueOf(50));
   631         desktopProperties.put("DnD.Autoscroll.interval",         Integer.valueOf(50));
   630         desktopProperties.put("DnD.Autoscroll.interval",         Integer.valueOf(50));
   632         desktopProperties.put("DnD.Autoscroll.cursorHysteresis", Integer.valueOf(5));
   631         desktopProperties.put("DnD.Autoscroll.cursorHysteresis", Integer.valueOf(5));
   641         // We don't want to call getMultilclickTime() if we're headless
   640         // We don't want to call getMultilclickTime() if we're headless
   642         if (!GraphicsEnvironment.isHeadless()) {
   641         if (!GraphicsEnvironment.isHeadless()) {
   643             desktopProperties.put("awt.multiClickInterval",
   642             desktopProperties.put("awt.multiClickInterval",
   644                                   Integer.valueOf(getMulticlickTime()));
   643                                   Integer.valueOf(getMulticlickTime()));
   645             desktopProperties.put("awt.mouse.numButtons",
   644             desktopProperties.put("awt.mouse.numButtons",
   646                                   Integer.valueOf(getNumMouseButtons()));
   645                                   Integer.valueOf(getNumberOfButtons()));
   647         }
   646         }
   648     }
   647     }
   649 
   648 
   650     public RobotPeer createRobot(Robot target, GraphicsDevice screen) {
   649     public RobotPeer createRobot(Robot target, GraphicsDevice screen) {
   651         /* 'target' is unused for now... */
   650         /* 'target' is unused for now... */