Package org.eclipse.swtbot.swt.finder.widgets

Examples of org.eclipse.swtbot.swt.finder.widgets.SWTBotShell.activate()


    private final static SWTWorkbenchBot bot = new SWTWorkbenchBot();

    public static void newFile(String filename) {
        bot.menu("File").menu("New").menu("File").click();
        SWTBotShell shell = bot.shell("New File");
        shell.activate();
        bot.textWithLabel("File name:").setText(filename);
        bot.button("Finish").click();
    }

}
View Full Code Here


    public static ProjectBot createSimpleProject() {
        String projectName = "Project_" + System.currentTimeMillis();
        bot.menu("File").menu("New").menu("Project...").click();
        SWTBotShell shell = bot.shell("New Project");
        shell.activate();
        bot.tree().expandNode("General").select("Project");
        bot.button("Next >").click();
        bot.textWithLabel("Project name:").setText(projectName);
        bot.button("Finish").click();
        SWTUtils.sleep(2000);
View Full Code Here

   
    public ProjectFileBot newFile(String fileName) {
        projectTree.setFocus();
        projectTree.contextMenu("New").menu("File").click();
        SWTBotShell shell = bot.shell("New File");
        shell.activate();
        bot.textWithLabel("File name:").setText(fileName);
        bot.button("Finish").click();
        SWTUtils.sleep(2000);
        SWTBotTreeItem treeItem = projectTree.getNode(fileName);
        return new ProjectFileBot(treeItem);
View Full Code Here

    public void delete() {
        projectTree.contextMenu("Refresh").click();
        SWTUtils.sleep(2000);
        projectTree.contextMenu("Delete").click();
        SWTBotShell shell = bot.shell("Delete Resources");
        shell.activate();
        shell.pressShortcut(SWT.ALT, 'D');
        bot.button("OK").click();
        projectTree = null;
    }
   
View Full Code Here

    }
   
    public static MarkdownViewBot open() {
        bot.menu("Window").menu("Show View").menu("Other...").click();
        SWTBotShell shell = bot.shell("Show View");
        shell.activate();
        bot.tree().expandNode("GFM Support").select("GFM View");
        bot.button("OK").click();
        return findById();
    }
View Full Code Here

    return ret;
  }
 
  public static SWTBotShell activateShell(SWTWorkbenchBot bot, String shell) {
    SWTBotShell s = bot.shell(shell);
    s.activate();
    return s;
  }
 
  public static void waitForWorkspace() throws Exception {
    // ensure that all queued workspace operations and locks are released
View Full Code Here

    SWTBotTree tree = getOrOpenView().bot().tree();
    tree.getAllItems()[0].select();
    ContextMenuHelper.clickContextMenu(tree, myUtil
        .getPluginLocalizedValue(DELETE_REPOSITORY_CONTEXT_MENU_LABEL));
    SWTBotShell shell = bot.shell(UIText.DeleteRepositoryConfirmDialog_DeleteRepositoryWindowTitle);
    shell.activate();
    shell.bot()
        .checkBox(
            UIText.DeleteRepositoryConfirmDialog_DeleteGitDirCheckbox)
        .select();
    shell.bot()
View Full Code Here

        .getItems()[0].select();
    ContextMenuHelper.clickContextMenu(tree, myUtil
        .getPluginLocalizedValue(DELETE_REPOSITORY_CONTEXT_MENU_LABEL));
    SWTBotShell shell = bot
        .shell(UIText.DeleteRepositoryConfirmDialog_DeleteRepositoryWindowTitle);
    shell.activate();
    shell.bot()
        .checkBox(
            UIText.DeleteRepositoryConfirmDialog_DeleteGitDirCheckbox)
        .select();
    shell.bot()
View Full Code Here

    ContextMenuHelper.clickContextMenu(view.bot().tree(), myUtil
        .getPluginLocalizedValue("CreateBranchCommand"));

    SWTBotShell createPage = bot
        .shell(UIText.CreateBranchWizard_NewBranchTitle);
    createPage.activate();
    // getting text with label doesn't work
    createPage.bot().textWithId("BranchName").setText("newLocal");
    createPage.bot().checkBox(UIText.CreateBranchPage_CheckoutButton)
        .select();
    createPage.bot().button(IDialogConstants.FINISH_LABEL).click();
View Full Code Here

    refreshAndWait();
    ContextMenuHelper.clickContextMenu(view.bot().tree(), myUtil
        .getPluginLocalizedValue("RepoViewDeleteBranch.label"));
    SWTBotShell confirmPopup = bot
        .shell(UIText.UnmergedBranchDialog_Title);
    confirmPopup.activate();
    confirmPopup.bot().button(IDialogConstants.OK_LABEL).click();
    refreshAndWait();
    localItem = myRepoViewUtil.getLocalBranchesItem(view.bot().tree(),
        repositoryFile);
    localItem.expand();
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.