Package org.eclipse.ui

Examples of org.eclipse.ui.IEditorInput


      }
    }
    URI uri = EcoreUtil.getURI(diagram);
    String editorName = uri.lastSegment()
        + "#" + diagram.eResource().getContents().indexOf(diagram); //$NON-NLS-1$
    IEditorInput editorInput = new URIEditorInput(uri, editorName);
    return editorInput;
  }
View Full Code Here


      }
    }
    if (navigatorView == null) {
      return;
    }
    IEditorInput editorInput = getEditorInput(navigatorView.getDiagram());
    IEditorPart editor = aPage.findEditor(editorInput);
    if (editor == null) {
      return;
    }
    aPage.bringToTop(editor);
View Full Code Here

  /**
   * @generated
   */
  public boolean matches(IEditorReference editorRef, IEditorInput input) {
    IEditorInput editorInput;
    try {
      editorInput = editorRef.getEditorInput();
    } catch (PartInitException e) {
      return false;
    }

    if (editorInput.equals(input)) {
      return true;
    }
    if (editorInput instanceof URIEditorInput
        && input instanceof URIEditorInput) {
      return ((URIEditorInput) editorInput).getURI().equals(
View Full Code Here

                      OntoUML.diagram.part.Messages.OntoUMLDocumentProvider_IncorrectInputError,
                      new Object[] { element,
                          "org.eclipse.emf.common.ui.URIEditorInput" }), //$NON-NLS-1$
              null));
    }
    IEditorInput editorInput = (IEditorInput) element;
    IDiagramDocument document = (IDiagramDocument) createDocument(editorInput);

    ResourceSetInfo info = new ResourceSetInfo(document, editorInput);
    info.setModificationStamp(computeModificationStamp(info));
    info.fStatus = null;
View Full Code Here

    public void run() {
      if (myDiagram == null || myDiagram.eResource() == null) {
        return;
      }

      IEditorInput editorInput = getEditorInput();
      IWorkbenchPage page = myViewerSite.getPage();
      try {
        page.openEditor(editorInput,
            OntoUML.diagram.part.OntoUMLDiagramEditor.ID);
      } catch (PartInitException e) {
View Full Code Here

        }
      }
      URI uri = EcoreUtil.getURI(myDiagram);
      String editorName = uri.lastSegment()
          + "#" + myDiagram.eResource().getContents().indexOf(myDiagram); //$NON-NLS-1$
      IEditorInput editorInput = new URIEditorInput(uri, editorName);
      return editorInput;
    }
View Full Code Here

  /**
   * @see IActionDelegate#run(IAction)
   */
  public void run(IAction action) {
    IWorkingCopyManager manager = JavaUI.getWorkingCopyManager();
    IEditorInput editorInput = editor.getEditorInput();
    try {
      manager.connect(editorInput);
      ICompilationUnit workingCopy = manager.getWorkingCopy(editorInput);

      CreateDialog dialog = new CreateDialog(new Shell(), new BuilderGenerator());
View Full Code Here

    ITask task = TasksUi.getTaskActivityManager().getActiveTask();
    if (task == null) {
      return null;
    }
    if (part instanceof IEditorPart) {
      IEditorInput input = ((IEditorPart) part).getEditorInput();

      /*
       * Order of this "if" statement is important.
       *
       * The editor input is likely to implement both IFileEditorInput and
View Full Code Here

     *
     * @see org.eclipse.ui.texteditor.AbstractTextEditor#doSave(org.eclipse.core.runtime.IProgressMonitor)
     */
    public void doSave( IProgressMonitor progressMonitor )
    {
        final IEditorInput input = getEditorInput();
        if ( input instanceof NonExistingLdifEditorInput )
        {
            super.doSaveAs();
            return;
        }
View Full Code Here

        }
        else
        {
            // Open FileDialog
            Shell shell = getSite().getShell();
            final IEditorInput input = getEditorInput();

            IDocumentProvider provider = getDocumentProvider();
            final IEditorInput newInput;

            FileDialog dialog = new FileDialog( shell, SWT.SAVE );

            String path = dialog.open();
            if ( path == null )
View Full Code Here

TOP

Related Classes of org.eclipse.ui.IEditorInput

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.