Package org.eclipse.jface.action

Examples of org.eclipse.jface.action.IAction.run()


    }
    // paste
    {
      IAction pasteAction = getPasteAction();
      assertTrue(pasteAction.isEnabled());
      pasteAction.run();
    }
    // move on "panel": feedback appears, command not null
    canvas.moveTo(existingButton, 0, 0);
    canvas.assertFeedbacks(canvas.getLinePredicate(existingButton, IPositionConstants.LEFT));
    canvas.assertCommandNotNull();
View Full Code Here


    assertNotNull(findChildAction(layoutManager, "HorizontalLayout"));
    assertNotNull(findChildAction(layoutManager, "VerticalLayout"));
    // use one of the actions to set new layout
    {
      IAction action = findChildAction(layoutManager, "TableLayout");
      action.run();
      assertEditor(
          "import com.gwtext.client.widgets.Panel;",
          "public class Test extends Panel {",
          "  public Test() {",
          "    setLayout(new TableLayout(1));",
View Full Code Here

        IEditorPart editor = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getActiveEditor();
        if (editor instanceof ITextEditor) {
            ITextEditor textEditor = (ITextEditor) editor;
            IAction action = textEditor.getAction(ITextEditorActionDefinitionIds.TOGGLE_OVERWRITE);
            if (action != null) {
                action.run();
                action.run();
            }
        }
    }
View Full Code Here

        if (editor instanceof ITextEditor) {
            ITextEditor textEditor = (ITextEditor) editor;
            IAction action = textEditor.getAction(ITextEditorActionDefinitionIds.TOGGLE_OVERWRITE);
            if (action != null) {
                action.run();
                action.run();
            }
        }
    }

}
View Full Code Here

                event.doit= false;
                return;
              }
            } else if (action.isEnabled()) {
              event.doit= false;
              action.run();
              return;
            }
          }
        }
      }
View Full Code Here

            }
            ((IOfflineActionWithParameters) action).setParameters(parameters);
        }

        try {
            action.run();
        } catch (Throwable e) {
            target.statusError("Exception raised when executing action:" + requestedStr + " - " + e.getMessage());
            Log.log(e);
            return false;
        }
View Full Code Here

                IIntroSite site = IntroPlugin.getDefault().getIntroModelRoot()
                    .getPresentation().getIntroPart().getIntroSite();
                introAction.run(site, parameters);
            } else if (actionObject instanceof IAction) {
                IAction action = (IAction) actionObject;
                action.run();

            } else if (actionObject instanceof IActionDelegate) {
                final IActionDelegate delegate = (IActionDelegate) actionObject;
                if (delegate instanceof IWorkbenchWindowActionDelegate)
                    ((IWorkbenchWindowActionDelegate) delegate).init(PlatformUI
View Full Code Here

      }
    }
    // use our action to do the open operation
    IAction openAction = fNavigateActionGroup.getOpenAction();
    if (openAction != null && openAction.isEnabled()) {
      openAction.run();
      return;
    }

  }
View Full Code Here

          manager.add(new Action(Messages.ApplicationActionBarAdvisor_CREATE_FILTER) {
            @Override
            public void run() {
              CreateFilterAction action = new CreateFilterAction();
              action.selectionChanged(null, selection);
              action.run(null);
            }

            @Override
            public ImageDescriptor getImageDescriptor() {
              return OwlUI.FILTER;
View Full Code Here

          manager.add(new Action(Messages.ApplicationActionBarAdvisor_UPDATE) {
            @Override
            public void run() {
              IActionDelegate action = new ReloadTypesAction();
              action.selectionChanged(null, selection);
              action.run(null);
            }

            @Override
            public ImageDescriptor getImageDescriptor() {
              return OwlUI.getImageDescriptor("icons/elcl16/reload.gif"); //$NON-NLS-1$
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.