991 } 992 } 993 994 public void doLayout(int x, int y, int width, int height) {} 995 996 public void handleConfigureNotifyEvent(XEvent xev) { 997 Rectangle oldBounds = getBounds(); 998 999 super.handleConfigureNotifyEvent(xev); 1000 if (insLog.isLoggable(PlatformLogger.Level.FINER)) { 1001 insLog.finer("Configure, {0}, event disabled: {1}", 1002 xev.get_xconfigure(), isEventDisabled(xev)); 1003 } 1004 if (isEventDisabled(xev)) { 1005 return; 1006 } 1007 1008 // if ( Check if it's a resize, a move, or a stacking order change ) 1009 // { 1010 Rectangle bounds = getBounds(); 1011 final ComponentAccessor acc = AWTAccessor.getComponentAccessor(); 1012 if (!bounds.getSize().equals(oldBounds.getSize())) { 1013 acc.setSize(target, bounds.width, bounds.height); 1014 postEventToEventQueue(new ComponentEvent(getEventSource(), ComponentEvent.COMPONENT_RESIZED)); 1015 } 1016 if (!bounds.getLocation().equals(oldBounds.getLocation())) { 1017 acc.setLocation(target, bounds.x, bounds.y); 1018 postEventToEventQueue(new ComponentEvent(getEventSource(), ComponentEvent.COMPONENT_MOVED)); 1019 } 1020 // } 1021 } 1022 1023 public void handleMapNotifyEvent(XEvent xev) { 1024 super.handleMapNotifyEvent(xev); 1025 if (log.isLoggable(PlatformLogger.Level.FINE)) { 1026 log.fine("Mapped {0}", this); 1027 } 1028 if (isEventDisabled(xev)) { 1029 return; 1030 } 1031 ComponentEvent ce; 1032 1033 ce = new ComponentEvent(getEventSource(), ComponentEvent.COMPONENT_SHOWN); 1034 postEventToEventQueue(ce); 1035 } 1036 1037 public void handleUnmapNotifyEvent(XEvent xev) { | 991 } 992 } 993 994 public void doLayout(int x, int y, int width, int height) {} 995 996 public void handleConfigureNotifyEvent(XEvent xev) { 997 Rectangle oldBounds = getBounds(); 998 999 super.handleConfigureNotifyEvent(xev); 1000 if (insLog.isLoggable(PlatformLogger.Level.FINER)) { 1001 insLog.finer("Configure, {0}, event disabled: {1}", 1002 xev.get_xconfigure(), isEventDisabled(xev)); 1003 } 1004 if (isEventDisabled(xev)) { 1005 return; 1006 } 1007 1008 // if ( Check if it's a resize, a move, or a stacking order change ) 1009 // { 1010 Rectangle bounds = getBounds(); 1011 if (!bounds.getSize().equals(oldBounds.getSize())) { 1012 postEventToEventQueue(new ComponentEvent(getEventSource(), ComponentEvent.COMPONENT_RESIZED)); 1013 } 1014 if (!bounds.getLocation().equals(oldBounds.getLocation())) { 1015 postEventToEventQueue(new ComponentEvent(getEventSource(), ComponentEvent.COMPONENT_MOVED)); 1016 } 1017 // } 1018 } 1019 1020 public void handleMapNotifyEvent(XEvent xev) { 1021 super.handleMapNotifyEvent(xev); 1022 if (log.isLoggable(PlatformLogger.Level.FINE)) { 1023 log.fine("Mapped {0}", this); 1024 } 1025 if (isEventDisabled(xev)) { 1026 return; 1027 } 1028 ComponentEvent ce; 1029 1030 ce = new ComponentEvent(getEventSource(), ComponentEvent.COMPONENT_SHOWN); 1031 postEventToEventQueue(ce); 1032 } 1033 1034 public void handleUnmapNotifyEvent(XEvent xev) { |