< prev index next >

src/java.desktop/windows/classes/sun/awt/windows/WWindowPeer.java

Print this page




 277     native void updateInsets(Insets i);
 278 
 279     static native int getSysMinWidth();
 280     static native int getSysMinHeight();
 281     static native int getSysIconWidth();
 282     static native int getSysIconHeight();
 283     static native int getSysSmIconWidth();
 284     static native int getSysSmIconHeight();
 285     /**windows/classes/sun/awt/windows/
 286      * Creates native icon from specified raster data and updates
 287      * icon for window and all descendant windows that inherit icon.
 288      * Raster data should be passed in the ARGB form.
 289      * Note that raster data format was changed to provide support
 290      * for XP icons with alpha-channel
 291      */
 292     native void setIconImagesData(int[] iconRaster, int w, int h,
 293                                   int[] smallIconRaster, int smw, int smh);
 294 
 295     synchronized native void reshapeFrame(int x, int y, int width, int height);
 296 
 297     public boolean requestWindowFocus(CausedFocusEvent.Cause cause) {
 298         if (!focusAllowedFor()) {
 299             return false;
 300         }
 301         return requestWindowFocus(cause == CausedFocusEvent.Cause.MOUSE_EVENT);
 302     }
 303     private native boolean requestWindowFocus(boolean isMouseEventCause);
 304 
 305     public boolean focusAllowedFor() {
 306         Window window = (Window)this.target;
 307         if (!window.isVisible() ||
 308             !window.isEnabled() ||
 309             !window.isFocusableWindow())
 310         {
 311             return false;
 312         }
 313         if (isModalBlocked()) {
 314             return false;
 315         }
 316         return true;
 317     }
 318 
 319     @Override
 320     void hide() {
 321         WindowListener listener = windowListener;




 277     native void updateInsets(Insets i);
 278 
 279     static native int getSysMinWidth();
 280     static native int getSysMinHeight();
 281     static native int getSysIconWidth();
 282     static native int getSysIconHeight();
 283     static native int getSysSmIconWidth();
 284     static native int getSysSmIconHeight();
 285     /**windows/classes/sun/awt/windows/
 286      * Creates native icon from specified raster data and updates
 287      * icon for window and all descendant windows that inherit icon.
 288      * Raster data should be passed in the ARGB form.
 289      * Note that raster data format was changed to provide support
 290      * for XP icons with alpha-channel
 291      */
 292     native void setIconImagesData(int[] iconRaster, int w, int h,
 293                                   int[] smallIconRaster, int smw, int smh);
 294 
 295     synchronized native void reshapeFrame(int x, int y, int width, int height);
 296 
 297     public boolean requestWindowFocus(FocusEvent.Cause cause) {
 298         if (!focusAllowedFor()) {
 299             return false;
 300         }
 301         return requestWindowFocus(cause == FocusEvent.Cause.MOUSE_EVENT);
 302     }
 303     private native boolean requestWindowFocus(boolean isMouseEventCause);
 304 
 305     public boolean focusAllowedFor() {
 306         Window window = (Window)this.target;
 307         if (!window.isVisible() ||
 308             !window.isEnabled() ||
 309             !window.isFocusableWindow())
 310         {
 311             return false;
 312         }
 313         if (isModalBlocked()) {
 314             return false;
 315         }
 316         return true;
 317     }
 318 
 319     @Override
 320     void hide() {
 321         WindowListener listener = windowListener;


< prev index next >