Package com.google.gdt.eclipse.designer.model.widgets

Examples of com.google.gdt.eclipse.designer.model.widgets.TreeInfo


        "      Tree tree = new Tree();",
        "      rootPanel.add(tree);",
        "    }",
        "  }",
        "}");
    TreeInfo treeWidget = getJavaInfoByName("tree");
    //
    loadCreationTool("com.google.gwt.user.client.ui.TreeItem");
    tree.moveOn(treeWidget).click();
    assertEditor(
        "public class Test implements EntryPoint {",
View Full Code Here


        "      Tree tree = new Tree();",
        "      rootPanel.add(tree);",
        "    }",
        "  }",
        "}");
    TreeInfo treeWidget = getJavaInfoByName("tree");
    //
    loadCreationTool("com.google.gwt.user.client.ui.Button");
    tree.moveOn(treeWidget).click();
    assertEditor(
        "public class Test implements EntryPoint {",
View Full Code Here

            "      rootPanel.add(tree);",
            "    }",
            "  }",
            "}");
    frame.refresh();
    TreeInfo tree = (TreeInfo) frame.getChildrenWidgets().get(0);
    Rectangle bounds = tree.getBounds();
    assertThat(bounds.width).isGreaterThan(50);
    assertThat(bounds.height).isGreaterThan(20);
  }
View Full Code Here

    assertHierarchy(
        "{RootPanel.get()} {local-unique: rootPanel} {/RootPanel.get()/ /rootPanel.add(tree)/}",
        "  {new: com.google.gwt.user.client.ui.Tree} {local-unique: tree} {/new Tree()/ /rootPanel.add(tree)/ /tree.addItem(button)/}",
        "    {implicit-factory} {local-unique: item} {/tree.addItem(button)/ /item.setState(true)/}",
        "      {new: com.google.gwt.user.client.ui.Button} {local-unique: button} {/new Button('Button text')/ /tree.addItem(button)/}");
    TreeInfo tree = (TreeInfo) frame.getChildrenWidgets().get(0);
    TreeItemInfo treeItem = tree.getItems().get(0);
    WidgetInfo button = treeItem.getWidget();
    // check association type, but not operations (see test for this association)
    assertInstanceOf(ImplicitFactoryArgumentAssociation.class, button.getAssociation());
    assertTrue(button.canDelete());
    assertFalse(JavaInfoUtils.canMove(button));
View Full Code Here

            "      rootPanel.add(tree);",
            "    }",
            "  }",
            "}");
    frame.refresh();
    TreeInfo tree = (TreeInfo) frame.getChildrenWidgets().get(0);
    // do CREATE
    TreeItemInfo newItem = createJavaInfo("com.google.gwt.user.client.ui.TreeItem");
    flowContainer_CREATE(tree, newItem, null);
    assertEditor(
        "public class Test implements EntryPoint {",
View Full Code Here

            "      rootPanel.add(tree);",
            "    }",
            "  }",
            "}");
    frame.refresh();
    TreeInfo tree = (TreeInfo) frame.getChildrenWidgets().get(0);
    // do CREATE
    WidgetInfo newButton = createJavaInfo("com.google.gwt.user.client.ui.Button");
    flowContainer_CREATE(tree, newButton, null);
    assertEditor(
        "public class Test implements EntryPoint {",
View Full Code Here

            "      rootPanel.add(tree_2);",
            "    }",
            "  }",
            "}");
    frame.refresh();
    TreeInfo tree_1 = (TreeInfo) frame.getChildrenWidgets().get(0);
    TreeInfo tree_2 = (TreeInfo) frame.getChildrenWidgets().get(1);
    // do MOVE
    TreeItemInfo item = tree_1.getItems().get(0);
    flowContainer_MOVE(tree_2, item, null);
    assertEditor(
        "public class Test implements EntryPoint {",
View Full Code Here

            "      }",
            "    }",
            "  }",
            "}");
    frame.refresh();
    TreeInfo tree = (TreeInfo) frame.getChildrenWidgets().get(0);
    TreeItemInfo item_0 = tree.getItems().get(0);
    // change "state" manually
    item_0.getPropertyByTitle("state").setValue(true);
    assertEditor(
        "public class Test implements EntryPoint {",
        "  public void onModuleLoad() {",
View Full Code Here

            "      }",
            "    }",
            "  }",
            "}");
    frame.refresh();
    TreeInfo tree = (TreeInfo) frame.getChildrenWidgets().get(0);
    TreeItemInfo existingItem = tree.getItems().get(0);
    // do CREATE
    TreeItemInfo item = createJavaInfo("com.google.gwt.user.client.ui.TreeItem");
    flowContainer_CREATE(existingItem, item, null);
    assertEditor(
        "public class Test implements EntryPoint {",
View Full Code Here

            "      }",
            "    }",
            "  }",
            "}");
    frame.refresh();
    TreeInfo tree = (TreeInfo) frame.getChildrenWidgets().get(0);
    TreeItemInfo existingItem = tree.getItems().get(0);
    // do CREATE
    WidgetInfo newButton = createJavaInfo("com.google.gwt.user.client.ui.Button");
    flowContainer_CREATE(existingItem, newButton, null);
    assertEditor(
        "public class Test implements EntryPoint {",
View Full Code Here

TOP

Related Classes of com.google.gdt.eclipse.designer.model.widgets.TreeInfo

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.