Package org.eclipse.ui

Examples of org.eclipse.ui.IViewReference


              }  
          }
      }
      else {
        // We're a minimized stack...restore it
            IViewReference viewRef = getReference();
           
            Perspective persp = viewPane.getPane().getPage().getActivePerspective();
            FastViewManager fvm = persp.getFastViewManager();
            String trimId = fvm.getIdForRef(viewRef);
            fvm.restoreToPresentation(trimId);
View Full Code Here


        if (id != null) {
            try {
        IViewDescriptor viewDescriptor = viewFactory.getViewRegistry()
            .find(ViewFactory.extractPrimaryId(id));
        if (!WorkbenchActivityHelper.filterItem(viewDescriptor)) {
          IViewReference ref = viewFactory.createView(ViewFactory
              .extractPrimaryId(id), ViewFactory
              .extractSecondaryId(id));
          fastViews.add(ref);

          // force creation of the view layout rec
View Full Code Here

   *            The part's id.
   * @return true if the partId is a fast view id.
   */
    private boolean isFastViewId(String partId) {
        for (int i = 0; i < fastViews.size(); i++) {
      IViewReference ref = (IViewReference) fastViews.get(i);
      String secondaryId = ref.getSecondaryId();
      String refId = (secondaryId == null ? ref.getId() : ref.getId()
          + ":" + secondaryId); //$NON-NLS-1$
      if (refId.equals(partId)) {
        return true;
      }
        }
View Full Code Here

        IViewPart introView = getViewIntroAdapterPart();
        if (introView != null) {
            //assumption is that there is only ever one intro per workbench
            //if we ever support one per window then this will need revisiting
            IWorkbenchPage page = introView.getSite().getPage();
            IViewReference reference = page
                    .findViewReference(IIntroConstants.INTRO_VIEW_ID);
            page.hideView(introView);
            if (reference == null || reference.getPart(false) == null) {
                introPart = null;               
                return true;
            }
            return false;
        }
View Full Code Here

                continue;
            }
            IPerspectiveDescriptor[] perspDescs = page.getOpenPerspectives();
            for (int j = 0; j < perspDescs.length; j++) {
                IPerspectiveDescriptor descriptor = perspDescs[j];
                IViewReference reference = page.findPerspective(descriptor)
                        .findView(IIntroConstants.INTRO_VIEW_ID);
                if (reference != null) {
                    IViewPart part = reference.getView(false);
                    if (part != null && part instanceof ViewIntroAdapterPart) {
            return (ViewIntroAdapterPart) part;
          }
                }
            }
View Full Code Here

        for(int i=0 ; i<pages.length ; i++) {
          page = pages[i];
          IWorkbenchPartReference activePart =
            page.getActivePartReference();
          if(activePart instanceof IViewReference) {
            IViewReference viewPart =(IViewReference)activePart;
            sourceViewId = viewPart.getId();
          }
        }
      }
    }
    return sourceViewId;
View Full Code Here

        for(int i=0 ; i<pages.length ; i++) {
          page = pages[i];
          IWorkbenchPartReference activePart =
            page.getActivePartReference();
          if(activePart instanceof IViewReference) {
            IViewReference viewPart =(IViewReference)activePart;
            sourceViewId = viewPart.getId();
          }
        }
      }
    }
    serviceBuilder = new ModelServiceBuilder(sourceViewId);
View Full Code Here

    public void run() {
      IProgressMonitor pm = null;
      try {
        IWorkbenchPage page = Activator.getDefault().getWorkbench().getActiveWorkbenchWindow().getActivePage();
        IViewReference[] ref = page.getViewReferences();
        IViewReference view = null;
       
       
        for(int i=0;i<ref.length;i++) {
          if(ref[i].getId().equals("eu.admire.workbench.cv.plugin.views.CVView"));
            view = ref[i];
        }
       
       
        if(view != null) {
          IActionBars bars = view.getView(false).getViewSite().getActionBars();
          IStatusLineManager statusLine = bars.getStatusLineManager();
          pm = statusLine.getProgressMonitor();
          pm.beginTask("Refreshing chart:", IProgressMonitor.UNKNOWN);
          pm.worked(1);
        }
View Full Code Here

  }
 
  private void initProgressMonitor() {
    IWorkbenchPage page = Activator.getDefault().getWorkbench().getActiveWorkbenchWindow().getActivePage();
    IViewReference[] ref = page.getViewReferences();
    IViewReference view = null;
   
   
    for(int i=0;i<ref.length;i++) {
      if(ref[i].getId().equals("eu.admire.workbench.dotvisualiser.views.DotVisualiserView"));
        view = ref[i];
    }
   
   
    if(view != null) {
      IActionBars bars = view.getView(true).getViewSite().getActionBars();
      IStatusLineManager statusLine = bars.getStatusLineManager();
      pm = statusLine.getProgressMonitor();
     

    }
View Full Code Here

    //long startTick = System.currentTimeMillis();
    // Update the model first
    List toMove = getTrueViewOrder(vs);
    for (Iterator viewIter = toMove.iterator(); viewIter.hasNext();) {
      IViewReference ref = (IViewReference) viewIter.next();
      addViewReference(vs.getID(), -1, ref, false);
    }

    vs.deferUpdates(false);
   
View Full Code Here

TOP

Related Classes of org.eclipse.ui.IViewReference

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.