Examples of MenuFinder


Examples of net.sf.swtbot.finder.MenuFinder

  /**
   * Constructs a bot.
   */
  public SWTBot() {
    this(new ControlFinder(), new MenuFinder());
  }
View Full Code Here

Examples of net.sf.swtbot.finder.MenuFinder

  /**
   * @see net.sf.swtbot.eclipse.finder.widgets.SWTBotView#findWidget(int)
   */
  protected Widget findWidget(int index) throws WidgetNotFoundException {
    Widget findWidget = findWidget(view, new Finder(new ChildrenControlFinder(super.findWidget(index)), new MenuFinder()));
    return getEditor((Composite) findWidget);
  }
View Full Code Here

Examples of net.sf.swtbot.finder.MenuFinder

  /**
   * Constructs an eclipse bot.
   */
  public SWTEclipseBot() {
    super(new ControlFinder(new EclipseDefaultChildrenResolver(), new EclipseDefaultParentResolver()), new MenuFinder());
  }
View Full Code Here

Examples of net.sf.swtbot.finder.MenuFinder

   * @deprecated This has been replaced with the <code>SWTBotView(IViewReference reference)</code> constructor. If the
   *             passed in reference can not be cast it will throw a {@link ClassCastException}.
   */
  public SWTBotView(IWorkbenchPartReference reference) throws WidgetNotFoundException, ClassCastException {
    super(findWidget(reference, new Finder(new ControlFinder(new EclipseDefaultChildrenResolver(), new EclipseDefaultParentResolver()),
        new MenuFinder())));

    view = reference;
  }
View Full Code Here

Examples of net.sf.swtbot.finder.MenuFinder

   * @throws WidgetNotFoundException if the widget is <code>null</code> or widget has been disposed.
   * @since 1.2
   */
  public SWTBotView(IViewReference reference) throws WidgetNotFoundException {
    super(findWidget(reference, new Finder(new ControlFinder(new EclipseDefaultChildrenResolver(), new EclipseDefaultParentResolver()),
        new MenuFinder())));

    view = reference;
  }
View Full Code Here

Examples of net.sf.swtbot.finder.MenuFinder

  public AbstractSWTBot(Widget w) throws WidgetNotFoundException {
    if (w == null)
      throw new WidgetNotFoundException("The widget was null.");
    if (w.isDisposed())
      throw new WidgetNotFoundException("The widget was disposed." + SWTUtils.toString(w));
    finder = new Finder(new ControlFinder(), new MenuFinder());
    widget = w;
    display = w.getDisplay();
    log = Logger.getLogger(getClass());
  }
View Full Code Here

Examples of net.sf.swtbot.finder.MenuFinder

  public AbstractSWTBot(Widget w) throws WidgetNotFoundException {
    if (w == null)
      throw new WidgetNotFoundException("The widget was null.");
    if (w.isDisposed())
      throw new WidgetNotFoundException("The widget was disposed." + SWTUtils.toString(w));
    finder = new Finder(new ControlFinder(), new MenuFinder());
    widget = w;
    display = w.getDisplay();
    log = Logger.getLogger(getClass());
  }
View Full Code Here

Examples of net.sf.swtbot.finder.MenuFinder

  /**
   * Constructs a bot.
   */
  public SWTBot() {
    this(new ControlFinder(), new MenuFinder());
  }
View Full Code Here

Examples of net.sf.swtbot.finder.MenuFinder

   */
  public SWTBotMenu menu(final String menuName) throws WidgetNotFoundException {
    MenuItem menuItem = (MenuItem) syncExec(new WidgetResult() {
      public Widget run() {
        Menu bar = ((MenuItem) widget).getMenu();
        List findMenus = new MenuFinder().findMenus(bar, WidgetMatcherFactory.menuMatcher(menuName), true);
        if (!findMenus.isEmpty())
          return (MenuItem) findMenus.get(0);
        return null;
      }
    });
View Full Code Here

Examples of net.sf.swtbot.finder.MenuFinder

  /**
   * @see net.sf.swtbot.eclipse.finder.widgets.SWTBotView#findWidget(int)
   */
  protected Widget findWidget(int index) throws WidgetNotFoundException {
    Widget findWidget = findWidget(view, new Finder(new ChildrenControlFinder(super.findWidget(index)), new MenuFinder()));
    return getEditor((Composite) findWidget);
  }
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.