Package net.sf.swtbot.finder.UIThreadRunnable

Examples of net.sf.swtbot.finder.UIThreadRunnable.IntResult


   * Gets the selected item count.
   *
   * @return the number of selected items.
   */
  public int selectionCount() {
    return syncExec(new IntResult() {
      public int run() {
        return getControl().getSelectionCount();
      }
    });
  }
View Full Code Here


   * @param item the index of the item in the table, or -1 if the item does not exist in the table.
   * @return the index of the specified item in the table.
   * @since 1.0
   */
  public int indexOf(final String item) {
    return syncExec(new IntResult() {
      public int run() {
        TableItem[] items = getControl().getItems();
        for (int i = 0; i < items.length; i++) {
          TableItem tableItem = items[i];
          if (tableItem.getText().equals(item))
View Full Code Here

   *
   * @param item the search item.
   * @return the index of the item, or -1 if the item does not exist.
   */
  public int indexOf(final String item) {
    return syncExec(new IntResult() {
      public int run() {
        return getList().indexOf(item);
      }
    });
  }
View Full Code Here

  /**
   * @return the number of items in the ExpandBar
   */
  public int itemCount() {
    return syncExec(new IntResult() {
      public int run() {
        return getControl().getItemCount();
      }
    });
  }
View Full Code Here

  /**
   * @return the number of items that are currently in an expanded state.
   * @see ExpandItem#getExpanded()
   */
  public int expandedItemCount() {
    return syncExec(new IntResult() {
      public int run() {
        int expandeditemscount = 0;
        ExpandItem[] items = getControl().getItems();
        for (int i = 0; i < items.length; i++) {
          if (items[i].getExpanded()) {
View Full Code Here

   * Gets the item count in the list
   *
   * @return the number of items in the list.
   */
  public int itemCount() {
    return syncExec(new IntResult() {
      public int run() {
        return getList().getItemCount();
      }
    });
  }
View Full Code Here

   * Gets the selection count.
   *
   * @return the number of selected items in the list.
   */
  public int selectionCount() {
    return syncExec(new IntResult() {
      public int run() {
        return getList().getSelectionCount();
      }
    });
  }
View Full Code Here

    }


    private int getSwtObjectCount()
    {
        return UIThreadRunnable.syncExec( bot.getDisplay(), new IntResult()
        {
            public int run()
            {
                DeviceData info = bot.getDisplay().getDeviceData();
                if ( !info.tracking )
View Full Code Here

TOP

Related Classes of net.sf.swtbot.finder.UIThreadRunnable.IntResult

Copyright © 2018 www.massapicom. 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.