Examples of ILogViewEditor


Examples of net.sf.logsaw.ui.editors.ILogViewEditor

    IEditorReference[] editorRefs = page.findEditors(
        (IEditorInput) getElement().getAdapter(IEditorInput.class),
        null, IWorkbenchPage.MATCH_INPUT);
    for (int i = 0; i < editorRefs.length; i++) {
      IEditorPart editorPart = editorRefs[i].getEditor(false);
      ILogViewEditor editor = editorPart != null ?
          (ILogViewEditor) editorPart.getAdapter(ILogViewEditor.class) : null;
      if (editor != null) {
        editor.setColumnConfig(config);
      }
    }
  }
View Full Code Here

Examples of net.sf.logsaw.ui.editors.ILogViewEditor

    return root;
  }

  private void updateState(boolean enabled) {
    if (enabled) {
      ILogViewEditor editor =
        (ILogViewEditor) getWorkbenchWindow().getActivePage().getActiveEditor().getAdapter(ILogViewEditor.class);
      if (editor != null) {
        Integer selectedPage = (Integer) editor.getSelectedPage();
        updateWidgets(true, selectedPage.intValue(), editor.getPageCount());
      } else {
        // Fallback to disabled
        enabled = false;
      }
    }
View Full Code Here

Examples of net.sf.logsaw.ui.editors.ILogViewEditor

                  (IEditorInput) log.getAdapter(IEditorInput.class),
                  null, IWorkbenchPage.MATCH_INPUT);
              for (IEditorReference editorRef : editorRefs) {
                // Refresh editor
                IEditorPart editorPart = editorRef.getEditor(false);
                ILogViewEditor editor = editorPart != null ?
                    (ILogViewEditor) editorPart.getAdapter(ILogViewEditor.class) : null;
                if (editor != null) {
                  editor.clearQueryContext();
                  editor.refresh();
                }
              }
              NumberFormat fmt = DecimalFormat.getInstance();
              String title = payload.isCanceled() ?
                  Messages.SynchronizeLogResourceAction_canceled_title :
View Full Code Here

Examples of net.sf.logsaw.ui.editors.ILogViewEditor

  @Override
  public Object execute(ExecutionEvent event) throws ExecutionException {
    // Get the editor
    IWorkbenchWindow window = HandlerUtil.getActiveWorkbenchWindow(event);
    IWorkbenchPage page = window.getActivePage();
    ILogViewEditor editor =
      (ILogViewEditor) page.getActiveEditor().getAdapter(ILogViewEditor.class);
    if (editor != null) {
      String text = editor.getFocusCellText();
      if (text.length() > 0) {
        // Copy to clipboard
        Clipboard cb = new Clipboard(Display.getDefault());
        TextTransfer textTransfer = TextTransfer.getInstance();
        cb.setContents(new Object[] {text}, new Transfer[] {textTransfer});
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.