Package org.eclipse.jface.action

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


      IAction action = findChildAction(contextMenu, "onClick -> onButtonClick");
      assertNotNull(action);
      assertSame(EventsPropertyUtils.LISTENER_METHOD_IMAGE_DESCRIPTOR, action.getImageDescriptor());
      // run, no change expected
      String expectedSource = getJavaSourceToAssert();
      action.run();
      assertEquals(expectedSource, getJavaSourceToAssert());
    }
    // add new method using action
    {
      IMenuManager manager2 = findChildMenuManager(contextMenu, "Add event handler");
View Full Code Here


    {
      IMenuManager manager2 = findChildMenuManager(contextMenu, "Add event handler");
      IAction action = findChildAction(manager2, "onFocus");
      assertNotNull(action);
      // run, new method should be added
      action.run();
      waitEventLoop(0);
      DesignerPlugin.getActiveEditor().doSave(null);
      assertJava(decorateTestClassLines(
          "// filler filler filler filler filler",
          "// filler filler filler filler filler",
View Full Code Here

    assertNotNull(findChildAction(menu, "right + width"));
    assertNotNull(findChildAction(menu, "left + right"));
    {
      IAction action = findChildAction(menu, "right + width");
      action.setChecked(true);
      action.run();
      assertXML(
          "// filler filler filler filler filler",
          "// filler filler filler filler filler",
          "<ui:UiBinder>",
          "  <g:LayoutPanel>",
View Full Code Here

    assertNotNull(findChildAction(menu, "bottom + height"));
    assertNotNull(findChildAction(menu, "top + bottom"));
    {
      IAction action = findChildAction(menu, "top + bottom");
      action.setChecked(true);
      action.run();
      assertXML(
          "// filler filler filler filler filler",
          "// filler filler filler filler filler",
          "<ui:UiBinder>",
          "  <g:LayoutPanel>",
View Full Code Here

    assertNotNull(findChildAction(layoutManager, "HBoxLayout"));
    assertNotNull(findChildAction(layoutManager, "VBoxLayout"));
    // use one of the actions to set new layout
    {
      IAction action = findChildAction(layoutManager, "RowLayout, horizontal");
      action.run();
      assertEditor(
          "public class Test extends LayoutContainer {",
          "  public Test() {",
          "    setLayout(new RowLayout(Orientation.HORIZONTAL));",
          "  }",
View Full Code Here

      ComponentInfo boxA = getJavaInfoByName("boxA");
      canvas.select(boxA);
      // do copy
      IAction copyAction = getCopyAction();
      assertTrue(copyAction.isEnabled());
      copyAction.run();
    }
    // paste
    {
      IAction pasteAction = getPasteAction();
      assertTrue(pasteAction.isEnabled());
View Full Code Here

    }
    // paste
    {
      IAction pasteAction = getPasteAction();
      assertTrue(pasteAction.isEnabled());
      pasteAction.run();
    }
    // move
    canvas.sideMode().create(100, 50);
    canvas.target(container).inX(50).inY(100).move();
    canvas.click();
View Full Code Here

      ComponentInfo boxA = getJavaInfoByName("boxA");
      canvas.select(boxA);
      // do copy
      IAction copyAction = getCopyAction();
      assertTrue(copyAction.isEnabled());
      copyAction.run();
    }
    // paste
    {
      IAction pasteAction = getPasteAction();
      assertTrue(pasteAction.isEnabled());
View Full Code Here

    }
    // paste
    {
      IAction pasteAction = getPasteAction();
      assertTrue(pasteAction.isEnabled());
      pasteAction.run();
    }
    // use tree
    tree.moveOn(container);
    tree.assertFeedback_on(container);
    tree.click();
View Full Code Here

    // prepare action
    final IAction action = getExposeAction(button, "text");
    // animate
    new UiContext().executeAndCheck(new UIRunnable() {
      public void run(UiContext context) throws Exception {
        action.run();
      }
    }, new UIRunnable() {
      public void run(UiContext context) throws Exception {
        context.useShell("Expose property");
        // prepare widgets
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.