void () { if (myIsDisposed) return; IdeGlassPane GP = IdeGlassPaneUtil.find(myComponent); assert GP != null; GP.addMousePreprocessor(myMouseListener, this); GP.addMouseMotionPreprocessor(myMouseMotionListener, this); myHideCanceller = new MyAwtPreprocessor(); Toolkit.getDefaultToolkit().addAWTEventListener(myHideCanceller, AWTEvent.MOUSE_MOTION_EVENT_MASK | AWTEvent.KEY_EVENT_MASK | AWTEvent.MOUSE_EVENT_MASK); Topics.subscribe(ApplicationActivationListener.TOPIC, this, new MyFrameStateListener()); }