当前位置: 首页>>代码示例>>Java>>正文


Java RunsInEDT类代码示例

本文整理汇总了Java中org.fest.swing.annotation.RunsInEDT的典型用法代码示例。如果您正苦于以下问题:Java RunsInEDT类的具体用法?Java RunsInEDT怎么用?Java RunsInEDT使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


RunsInEDT类属于org.fest.swing.annotation包,在下文中一共展示了RunsInEDT类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: indexOfText

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
private static int indexOfText(final VNumber vNumber, final String text)
{
	return GuiActionRunner.execute(new GuiQuery<Integer>()
	{
		@Override
		protected Integer executeInEDT()
		{
			ComponentStateValidator.validateIsEnabledAndShowing(vNumber);
			final String actualText = vNumber.getValue().toString();
			if (Strings.isEmpty(actualText))
			{
				return -1;
			}
			return actualText.indexOf(text);
		}
	});
}
 
开发者ID:metasfresh,项目名称:metasfresh,代码行数:19,代码来源:VNumberDriver.java

示例2: createNewApp

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
private static App createNewApp() {
    return execute(new GuiQuery<App>() {
        protected App executeInEDT() throws Throwable {
            return new App();
        }
    });
}
 
开发者ID:biblelamp,项目名称:QAExercises,代码行数:9,代码来源:TestGUI.java

示例3: textOf

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@Override
@RunsInEDT
@Nullable
public String textOf(final @Nonnull SearchTextField component) {
  return execute(new GuiQuery<String>() {
    @Override
    protected
    @Nullable
    String executeInEDT() {
      return component.getText();
    }
  });
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:14,代码来源:SearchTextFieldDriver.java

示例4: replaceText

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
public void replaceText(final VNumber vNumber, final String text)
{
	if (Strings.isEmpty(text))
	{
		throw new IllegalArgumentException("The text to enter should not be empty");
	}
	selectAll(vNumber);
	enterText(vNumber, text);
}
 
开发者ID:metasfresh,项目名称:metasfresh,代码行数:11,代码来源:VNumberDriver.java

示例5: setText

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
public void setText(final VNumber vNumber, final String text)
{
	focusAndWaitForFocusGain(vNumber);
	VNumberDriver.setTextIn(vNumber, text);
	robot.waitForIdle();
}
 
开发者ID:metasfresh,项目名称:metasfresh,代码行数:8,代码来源:VNumberDriver.java

示例6: selectAllText

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
public static void selectAllText(final VNumber vNumber)
{
	GuiActionRunner.execute(new GuiTask()
	{
		@Override
		protected void executeInEDT()
		{
			vNumber.selectAll();
		}
	});
}
 
开发者ID:metasfresh,项目名称:metasfresh,代码行数:13,代码来源:VNumberDriver.java

示例7: setTextIn

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
private static void setTextIn(final VNumber vNumber, final String text)
{
	GuiActionRunner.execute(new GuiTask()
	{
		@Override
		protected void executeInEDT()
		{
			// wrap the String in a BigDecimal
			final Number textNumber = new BigDecimal(text);
			vNumber.setValue(textNumber);
		}
	});
}
 
开发者ID:metasfresh,项目名称:metasfresh,代码行数:15,代码来源:VNumberDriver.java

示例8: isEditable

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
private static boolean isEditable(final VNumber vNumber)
{
	return GuiActionRunner.execute(new GuiQuery<Boolean>()
	{
		@Override
		protected Boolean executeInEDT()
		{
			return vNumber.isEnabled();
		}
	});
}
 
开发者ID:metasfresh,项目名称:metasfresh,代码行数:13,代码来源:VNumberDriver.java

示例9: textOf

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
public String textOf(final VNumber vNumber)
{
	return GuiActionRunner.execute(new GuiQuery<String>()
	{
		@Override
		protected String executeInEDT()
		{
			return vNumber.getValue().toString();
		}
	});
}
 
开发者ID:metasfresh,项目名称:metasfresh,代码行数:13,代码来源:VNumberDriver.java

示例10: enterValue

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@Override
@RunsInEDT
public void enterValue(final JTable table, final int row, final int column, final String value)
{
	final VNumber editor = doStartCellEditing(table, row, column);
	// this.driver.replaceText(editor, value);
	// don't use replace text, but set value directly in the VNumber
	driver.setText(editor, value);
	stopCellEditing(table, row, column);
}
 
开发者ID:metasfresh,项目名称:metasfresh,代码行数:11,代码来源:VNumberCellWriter.java

示例11: doStartCellEditing

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
private VNumber doStartCellEditing(final JTable table, final int row, final int column)
{
	final Point cellLocation = AbstractJTableCellWriter.cellLocation(table, row, column, location);
	VNumber vNumber = null;

	vNumber = activateEditorWithClick(table, row, column, cellLocation);

	cellEditor(AbstractJTableCellWriter.cellEditor(table, row, column));
	return vNumber;
}
 
开发者ID:metasfresh,项目名称:metasfresh,代码行数:12,代码来源:VNumberCellWriter.java

示例12: createNewEditor

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
private static JFrame createNewEditor() {
	return execute(new GuiQuery<JFrame>() {
		@Override
		protected JFrame executeInEDT() throws Throwable {
			Beauti beauti = Beauti.main2(new String[] {});
			return beauti.frame;
		}
	});
}
 
开发者ID:CompEvol,项目名称:beast2,代码行数:11,代码来源:BeautiBase.java

示例13: findButton

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
private JButton findButton(VFSJFileChooser<?> fileChooser, String logicalName, String text) {
    JButton button = robot.finder().find(fileChooser, withText(text).andShowing());
    if (button == null)
        throw cannotFindButton(logicalName, text);
    return button;
}
 
开发者ID:shevek,项目名称:vfsjfilechooser,代码行数:8,代码来源:VFSJFileChooserDriver.java

示例14: executeInEDT

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
static <FileObject> void validateAndSelectFile(final VFSJFileChooser<FileObject> fileChooser, final FileObject file) {
    execute(new GuiTask() {
        protected void executeInEDT() {
            validateIsEnabledAndShowing(fileChooser);
            validateFileToChoose(fileChooser, file);
            fileChooser.setSelectedFile(file);
        }
    });
}
 
开发者ID:shevek,项目名称:vfsjfilechooser,代码行数:11,代码来源:VFSJFileChooserSelectFileTask.java

示例15: createNewBrowser

import org.fest.swing.annotation.RunsInEDT; //导入依赖的package包/类
@RunsInEDT
private static Browser createNewBrowser() {
  return GuiActionRunner.execute(new GuiQuery<Browser>() {
    protected Browser executeInEDT() {
      return new Browser();
    }
  });
}
 
开发者ID:nezda,项目名称:yawni,代码行数:9,代码来源:BrowserFESTTest.java


注:本文中的org.fest.swing.annotation.RunsInEDT类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。