Examples of WindowStateListener


Examples of java.awt.event.WindowStateListener

        }
    }

    protected void processWindowStateEvent(WindowEvent e) {
        for (Iterator<?> i = windowStateListeners.getUserIterator(); i.hasNext();) {
            WindowStateListener listener = (WindowStateListener) i.next();
            switch (e.getID()) {
                case WindowEvent.WINDOW_STATE_CHANGED:
                    listener.windowStateChanged(e);
                    break;
            }
        }
    }
View Full Code Here

Examples of java.awt.event.WindowStateListener

      public void actionPerformed(final ActionEvent e) {
        table.reload();
      }
    });
     
      MainFrame.getInstance().addWindowStateListener(new WindowStateListener() {
      @Override
      public void windowStateChanged(final WindowEvent e) {
        if (e.getNewState() == JFrame.NORMAL) {
          // restore timer dialog if it's not disposed
          if (timerDialog != null) {
View Full Code Here

Examples of java.awt.event.WindowStateListener

        } );

        final Window window = SwingUtils.getWindowAncestor ( rootPane );
        if ( window != null )
        {
            window.addWindowStateListener ( new WindowStateListener ()
            {
                @Override
                public void windowStateChanged ( final WindowEvent e )
                {
                    popupLayer.setBounds ( 0, 0, layeredPane.getWidth (), layeredPane.getHeight () );
View Full Code Here

Examples of java.awt.event.WindowStateListener

        if (confirmIfUnsavedChanges())
          exit();
      }
    });

    addWindowStateListener(new WindowStateListener() {
      @Override
      public void windowStateChanged(WindowEvent e) {
        preferences.putInt("state", getExtendedState());
      }
    });
View Full Code Here

Examples of java.awt.event.WindowStateListener

      @Override
      public void run() {
        try {
          _frame.pack();
          _frame.setVisible(true);
          _frame.addWindowStateListener(new WindowStateListener() {

            @Override
            public void windowStateChanged(WindowEvent e) {
              if (e.getNewState() == WindowEvent.WINDOW_CLOSED) {
                _endQueue.add(null);
View Full Code Here

Examples of java.awt.event.WindowStateListener

      @Override
      public void run() {
        try {
          _frame.pack();
          _frame.setVisible(true);
          _frame.addWindowStateListener(new WindowStateListener() {

            @Override
            public void windowStateChanged(WindowEvent e) {
              if (e.getNewState() == WindowEvent.WINDOW_CLOSED) {
                _endQueue.add(null);
View Full Code Here

Examples of nl.lxtreme.ols.client.osgi.UserSessionManager.WindowStateListener

    Project mockedProject = mock( Project.class );
    ProjectManager mockedProjectManager = mock( ProjectManager.class );
    when( mockedProjectManager.getCurrentProject() ).thenReturn( mockedProject );

    this.windowStateListener = spy( new WindowStateListener() );
    this.windowStateListener.setPreferenceService( mockedPreferenceService );
    this.windowStateListener.setProjectManager( mockedProjectManager );
    this.windowStateListener.setLogger( mock( LogService.class ) );
  }
View Full Code Here

Examples of org.apache.pivot.wtk.WindowStateListener

                prompt.open(frame);
                // alert.open(frame);
            }
        });

        sheet.getWindowStateListeners().add(new WindowStateListener() {
            @Override
            public Vote previewWindowOpen(Window window, Display display) {
                return Vote.APPROVE;
            }
View Full Code Here

Examples of pivot.wtk.WindowStateListener

            public void buttonPressed(Button button) {
                sheet.open(frame);
            }
        });

        sheet.getWindowStateListeners().add(new WindowStateListener() {
            public Vote previewWindowOpen(Window window, Display display) {
                return Vote.APPROVE;
            }

            public void windowOpenVetoed(Window window, Vote reason) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.