Examples of closeAllEditors()


Examples of org.eclipse.ui.IWorkbenchPage.closeAllEditors()

  public static void cleanUpProjects() throws CoreException {
    IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
    if (window != null) {
      IWorkbenchPage page = window.getActivePage();
      if (page != null) {
        page.closeAllEditors(false);
      }
    }
    deleteAllProjects();
  }
View Full Code Here

Examples of org.eclipse.ui.IWorkbenchPage.closeAllEditors()

  public Object execute(ExecutionEvent event) throws ExecutionException {
    IWorkbenchWindow window = HandlerUtil
        .getActiveWorkbenchWindowChecked(event);
    IWorkbenchPage page = window.getActivePage();
    if (page != null) {
      page.closeAllEditors(true);
    }

    return null;
  }
View Full Code Here

Examples of org.eclipse.ui.IWorkbenchPage.closeAllEditors()

                    // open LDAP perspective
                    workbench.showPerspective(
                        "org.apache.directory.studio.ldapbrowser.ui.perspective.BrowserPerspective", window );

                    // reset LDAP perspective
                    page.closeAllEditors( false );
                    page.resetPerspective();

                }
                catch ( Exception e )
                {
View Full Code Here

Examples of org.eclipse.ui.IWorkbenchPage.closeAllEditors()

                    }

                    // reset LDAP perspective
                    if ( page.getActivePart() != null )
                    {
                        page.closeAllEditors( false );
                        page.resetPerspective();
                    }
                }
                catch ( Exception e )
                {
View Full Code Here

Examples of org.eclipse.ui.IWorkbenchPage.closeAllEditors()

                if( mapEditor!=null ) {
                    mapEditor.setTesting(true);
                }
            }
        }
        while ( !activePage.closeAllEditors(false||  activePage.getEditorReferences().length!=0);        
        //super.tearDown();
       
        editors = activePage.getEditorReferences();
        for( IEditorReference reference : editors ) {
          IEditorPart editor = reference.getEditor(false);           
View Full Code Here

Examples of org.eclipse.ui.IWorkbenchPage.closeAllEditors()

          MapEditorPart mapEditor = (MapEditorPart) editor;
            if( mapEditor!=null ){
                mapEditor.setTesting(true);
            }
        }
        while ( !activePage.closeAllEditors(false||  activePage.getEditorReferences().length!=0);        

        editors = activePage.getEditorReferences();
        assertEquals(0,editors.length);
       
    }
View Full Code Here

Examples of org.eclipse.ui.IWorkbenchPage.closeAllEditors()

                    // open LDAP perspective
                    workbench.showPerspective(
                        "org.apache.directory.studio.ldapbrowser.ui.perspective.BrowserPerspective", window );

                    // reset LDAP perspective
                    page.closeAllEditors( false );
                    page.resetPerspective();

                }
                catch ( Exception e )
                {
View Full Code Here

Examples of org.eclipse.ui.IWorkbenchPage.closeAllEditors()

    for (int i = 431; i < 440; i++) {
      assertNull(detector.detectHyperlinks(textViewer, new Region(i, 1), false));
    }

    try {
      activePage.closeAllEditors(false);
      IDE.openEditor(activePage, file);
    } catch (PartInitException e) {
    }
    hyperlink.open();
    final IEditorPart activeEditor = activePage.getActiveEditor();
View Full Code Here

Examples of org.eclipse.ui.IWorkbenchPage.closeAllEditors()

    hyperlink.open();
    final IEditorPart activeEditor = activePage.getActiveEditor();
    assertTrue(activeEditor.getEditorInput() instanceof FileEditorInput);
    FileEditorInput input = (FileEditorInput) activeEditor.getEditorInput();
    assertEquals("/testproject/src/main/java/org/qwickie/test/project/issue54/Issue54Page.html", input.getFile().getFullPath().toPortableString());
    activePage.closeAllEditors(false);

    System.out.println("testQWickieJavaHlDetector:\t" + (System.nanoTime() - start));
  }

  @Test
View Full Code Here

Examples of org.eclipse.ui.IWorkbenchPage.closeAllEditors()

    final IHyperlink hyperlink = hyperlinks[0];
    assertEquals(hyperlink.getHyperlinkText(), "Open java file and jump to wicket:id \"test\"");

    final IWorkbenchPage activePage = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
    try {
      activePage.closeAllEditors(false);
      IDE.openEditor(activePage, file);
    } catch (PartInitException e) {
    }
    hyperlink.open();
    final IEditorPart activeEditor = activePage.getActiveEditor();
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.