Package de.sciss.common

Examples of de.sciss.common.BasicApplication


  {
    super( REGULAR );
   
    this.doc  = doc;

    final BasicApplication  app  = (BasicApplication) AbstractApplication.getApplication();
//    final MenuRoot      mr  = app.getMenuBarRoot();
   
    actionSave    = new ActionSave();
    actionSaveAs  = new ActionSaveAs();
       
    Listener winListener = new AbstractWindow.Adapter() {
// EEE
//      public void windowClosing( AbstractWindow.Event e ) {
//        actionClose.perform();
//      }

      public void windowActivated( AbstractWindow.Event e )
      {
        // need to check 'disposed' to avoid runtime exception in doc handler if document was just closed
// EEE
//        if( !disposed ) {
          app.getDocumentHandler().setActiveDocument( DocumentFrame.this, doc );
          ((BasicWindowHandler) app.getWindowHandler()).setMenuBarBorrower( DocumentFrame.this );
//        }
      }
    };
    this.addListener( winListener );
  }
View Full Code Here


    this.addListener( winListener );
  }
 
  public void init()
  {
    final BasicApplication  app  = (BasicApplication) AbstractApplication.getApplication();
    final MenuRoot      mr  = app.getMenuBarRoot();
   
    mr.putMimic( "file.clearSession", this, new ActionClearSession() );
    mr.putMimic( "file.save", this, actionSave );
    mr.putMimic( "file.saveAs", this, actionSaveAs );
    mr.putMimic( "edit.undo", this, doc.getUndoManager().getUndoAction() );
View Full Code Here

    public void processCancel( ProcessingThread context ) {}

    public void processFinished( ProcessingThread context )
    {
      final BasicApplication  app  = (BasicApplication) AbstractApplication.getApplication();
      final MainFrame     mf  = (MainFrame) app.getComponent( Main.COMP_MAIN );
      final File        f  = (File) context.getClientArg( "file" );

      if( context.getReturnCode() == DONE ) {
        doc.setFile( f );
        app.getMenuFactory().addRecent( f );
        doc.setDirty( false );
      } else {
        File tempDir = new File( f.getParentFile().getAbsolutePath() + ".tmp" );
        if( tempDir.exists() ) {
          JOptionPane.showMessageDialog( mf.getWindow(),
View Full Code Here

    ensure( false, false, false );
  }
 
  public static void ensure( boolean lafDeco, boolean internalFrames, boolean floating )
  {
    BasicApplication app = (BasicApplication) AbstractApplication.getApplication();
    if( app == null ) {
      app = new Application( lafDeco, internalFrames, floating );
    }
    SwingOSC.getInstance().getCurrentClient().locals.put(
      "menuRoot", app.getMenuBarRoot() );
  }
View Full Code Here

TOP

Related Classes of de.sciss.common.BasicApplication

Copyright © 2018 www.massapicom. 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.