Examples of openEditor()


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

            if (buildFile == null)
                return null;

            FileEditorInput input = new FileEditorInput(buildFile);
            IWorkbenchPage page = HandlerUtil.getActiveWorkbenchWindowChecked(event).getActivePage();
            page.openEditor(input, "bndtools.bndWorkspaceConfigEditor", true);
        } catch (PartInitException e) {
            ErrorDialog.openError(HandlerUtil.getActiveWorkbenchWindowChecked(event).getShell(), "Error", "Unable to open editor", e.getStatus());
        } catch (Exception e) {
            logger.logError("Error retrieving bnd configuration file", e);
        }
View Full Code Here

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

                // Let's open the editor
                if ( input != null )
                {
                    try
                    {
                        page.openEditor( input, editorId );
                    }
                    catch ( PartInitException e )
                    {
                        PluginUtils.logError( Messages.getString( "ProblemsViewController.ErrorOpeningEditor" ), e ); //$NON-NLS-1$
                        ViewUtils.displayErrorMessageBox( Messages.getString( "ProblemsViewController.Error" ), //$NON-NLS-1$
View Full Code Here

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

                // Let's open the editor
                if ( input != null )
                {
                    try
                    {
                        page.openEditor( input, editorId );
                    }
                    catch ( PartInitException e )
                    {
                        PluginUtils.logError( Messages.getString( "SchemaViewController.ErrorOpeningEditor" ), e ); //$NON-NLS-1$
                        ViewUtils.displayErrorMessageBox( Messages.getString( "SchemaViewController.error" ), Messages //$NON-NLS-1$
View Full Code Here

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

                IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
                PathEditorInput input = new PathEditorInput( ApacheDsPluginUtils.getApacheDsServersFolder().append(
                    server.getId() ).append( "conf" ).append( "server.xml" ) ); //$NON-NLS-1$ //$NON-NLS-2$
                try
                {
                    page.openEditor( input, ServerConfigurationEditor.ID );
                }
                catch ( PartInitException e )
                {
                    ApacheDsPluginUtils.reportError( Messages.getString( "OpenConfigurationAction.ErrorWhenOpening" ) //$NON-NLS-1$
                        + e.getMessage() );
View Full Code Here

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

  static IStatus openEditor(final IDiagram workingModel) {
    try {
      IWorkbench workbench = PlatformUI.getWorkbench();
      IWorkbenchWindow activeWorkbenchWindow = workbench.getActiveWorkbenchWindow();
      final IWorkbenchPage activePage = activeWorkbenchWindow.getActivePage();
      activePage.openEditor(new OnMemoryEditorInput(workingModel), Editor.ID, true);
    } catch (PartInitException e) {
      Status status = new Status(IStatus.ERROR, Activator.PLUGIN_ID, "Oops ! Stupid thing happends when opening editor : "
          + e.getLocalizedMessage(), e);
      LOGGER.log(status);
      return status;
View Full Code Here

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

    monitor.setTaskName("Starting editor for new descriptor...");
    getShell().getDisplay().asyncExec(new Runnable() {
      public void run() {
        IWorkbenchPage page1 = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
        try {
          page1.openEditor(new FileEditorInput(file), "taeconfigurator.editors.MultiPageEditor");
        } catch (PartInitException e) {
        }
      }
    });
    monitor.worked(2);
View Full Code Here

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

    Shell shell = new Shell();
    shell.getDisplay().asyncExec(new Runnable() {
      public void run() {
        IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
        try {
          page.openEditor(new FileEditorInput(ffile), "taeconfigurator.editors.MultiPageEditor"); //$NON-NLS-1$
        } catch (PartInitException e) {
          throw new InternalErrorCDE("unexpected exception");
        }
      }
    });
View Full Code Here

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

    Shell shell = new Shell();
    shell.getDisplay().asyncExec(new Runnable() {
      public void run() {
        IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
        try {
          page.openEditor(new FileEditorInput(ffile), "org.eclipse.ui.DefaultTextEditor"); //$NON-NLS-1$
        } catch (PartInitException e) {
          throw new InternalErrorCDE("unexpected exception");
        }
      }
    });
View Full Code Here

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

        IWorkbenchPage page = getEditorSite().getWorkbenchWindow()
            .getActivePage();
        if (page != null) {
          page.closeEditor(AbstractDesignerEditor.this, false);
          try {
            page.openEditor(input, JAVA_EDITOR_ID);
            IFileEditorInput file_editor_input = (IFileEditorInput) input;
            IFile file = file_editor_input.getFile();
            IDE.setDefaultEditor(file, JAVA_EDITOR_ID);
          } catch (PartInitException e) {
            VisualSwingPlugin.getLogger().error(e);
View Full Code Here

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

      IFile file = project.getFile(BundlePath.DUB_MANIFEST_FILENAME);
     
      IWorkbenchPage activePage = WorkbenchUtils.getActivePage();
      if(activePage != null) {
        try {
          activePage.openEditor(new FileEditorInput(file), EditorsUI.DEFAULT_TEXT_EDITOR_ID);
        } catch (PartInitException e) {
          DeeCore.logInternalError(e);
        }
      }
      fBuildSettingsPage.performOk();
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.