Package org.eclipse.ui

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


      /* Activate */
      if (tab != null) {
        IWorkbenchPage page = tab.getSite().getPage();
        page.activate(tab.getSite().getPart());
        page.activate(tab);
      }
    }

    private boolean navigateOnActiveFeedView() {

View Full Code Here


        if (!success && fType.isNewsScoped() && fType.isUnread() && fType.isNext())
          success = activeFeedView.navigate(false, false, fType.isNext(), fType.isUnread());

        if (success) {
          IWorkbenchPage page = activeFeedView.getSite().getPage();
          page.activate(activeFeedView.getSite().getPart());
          page.activate(activeFeedView);

          return true;
        }
      }
View Full Code Here

          success = activeFeedView.navigate(false, false, fType.isNext(), fType.isUnread());

        if (success) {
          IWorkbenchPage page = activeFeedView.getSite().getPage();
          page.activate(activeFeedView.getSite().getPart());
          page.activate(activeFeedView);

          return true;
        }
      }
View Full Code Here

                IDE.openEditor(page, input, MessageEditor.ID, true);
            }
            else
            {
                // ((AbstractMessageEditor) messageEditor).setInput(input);
                page.activate(messageEditor);
            }
        }
        catch( PartInitException ex)
        {
            // TODO Auto-generated catch block
View Full Code Here

    view = (CheatSheetView) page.findView(ICheatSheetResource.CHEAT_SHEET_VIEW_ID);
    if (view == null) {
      try {
        view = (CheatSheetView)page.showView(ICheatSheetResource.CHEAT_SHEET_VIEW_ID);
        page.activate(view);
      } catch (PartInitException pie) {
        String message = Messages.LAUNCH_SHEET_ERROR;
        IStatus status = new Status(IStatus.ERROR, ICheatSheetResource.CHEAT_SHEET_PLUGIN_ID, IStatus.OK, message, pie);
        CheatSheetPlugin.getPlugin().getLog().log(status);
        org.eclipse.jface.dialogs.ErrorDialog.openError(window.getShell(), Messages.CHEAT_SHEET_ERROR_OPENING, null, pie.getStatus());
View Full Code Here

                      }
                      shell.forceActive();
                      shell.setActive();
                      shell.forceFocus();

                      page.activate(editor);
                    } catch (Throwable T) {
                      T.printStackTrace();
                    }
                  }
                });
View Full Code Here

                    }
                  }
                });
              }
              else {
                page.activate(editor);
              }
            } catch (PartInitException e) {
              String msg = NLS.bind(IDEWorkbenchMessages.OpenLocalFileAction_message_errorOnOpen, fileStore.getName());
              IDEWorkbenchPlugin.log(msg, e.getStatus());
              MessageDialog.openError(null /* window */, IDEWorkbenchMessages.OpenLocalFileAction_title, msg);
View Full Code Here

          // Select the line number
          ITextEditor textEditor = (ITextEditor)editor;
          lineNumber--; // document is 0 based
          IDocument document = textEditor.getDocumentProvider().getDocument(textEditor.getEditorInput());
          textEditor.selectAndReveal( document.getLineOffset(lineNumber), document.getLineLength(lineNumber));
          page.activate(textEditor);
         
        } catch (Exception ex) {
                ex.printStackTrace();
            }
       
View Full Code Here

          IWorkbenchPart activePart = page.getActivePart();
          testRunner = (TestRunnerViewPart) page.showView(TestRunnerViewPart.NAME);

          //restore focus
          page.activate(activePart);
        }
        else {
          page.bringToTop(testRunner);
        }
      }
View Full Code Here

    }
    finally {

      //restore focus stolen by the creation of the result view
      if((page != null) && (activePart != null)) {
        page.activate(activePart);
      }
    }
  }

  private TestRunnerViewPart findTestRunnerViewPartInActivePage() {
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.