Package net.sf.swtbot.finder.UIThreadRunnable

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


    }


    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


   * Gets the row count.
   *
   * @return the number of rows in the table
   */
  public int rowCount() {
    return syncExec(new IntResult() {
      public int run() {
        return getControl().getItemCount();
      }
    });
  }
View Full Code Here

   * Gets the column count.
   *
   * @return the number of columns in the table
   */
  public int columnCount() {
    return syncExec(new IntResult() {
      public int run() {
        return getControl().getColumnCount();
      }
    });
  }
View Full Code Here

   * 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

   * Returns the alignment. The alignment style (LEFT, CENTER or RIGHT) is returned.
   *
   * @return SWT.LEFT, SWT.RIGHT or SWT.CENTER
   */
  public int alignment() {
    return syncExec(new IntResult() {
      public int run() {
        return getLabel().getAlignment();
      }
    });
  }
View Full Code Here

   * Returns the alignment. The alignment style (LEFT, CENTER or RIGHT) is returned.
   *
   * @return SWT.LEFT, SWT.RIGHT or SWT.CENTER
   */
  public int alignment() {
    return syncExec(new IntResult(){
      public int run() {
        return getCLabel().getAlignment();
      }
    });
  }
View Full Code Here

   * Sets the selection to the given text.
   *
   * @param text The text to select.
   */
  private void _setSelection(final String text) {
    final int indexOf = syncExec(new IntResult() {
      public int run() {
        String[] items = getCombo().getItems();
        return Arrays.asList(items).indexOf(text);
      }
    });
View Full Code Here

   * Sets the selection to the given index.
   *
   * @return the zero based index of the current selection.
   */
  public int selectionIndex() {
    return syncExec(new IntResult() {
      public int run() {
        return getCombo().getSelectionIndex();
      }
    });
  }
View Full Code Here

   * Gets the item count in the combo box.
   *
   * @return the number of items in the combo box.
   */
  public int itemCount() {
    return syncExec(new IntResult() {
      public int run() {
        return getCombo().getItemCount();
      }
    });
  }
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.