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

Examples of com.google.gdt.eclipse.designer.gwtext.model.widgets.GridPanelInfo


  //
  // Tests
  //
  ////////////////////////////////////////////////////////////////////////////
  public void test_parseEmpty() throws Exception {
    GridPanelInfo panel =
        parseJavaInfo(
            "// filler filler filler",
            "public class Test extends GridPanel {",
            "  public Test() {",
            "  }",
            "}");
    panel.refresh();
    assertFalse(panel.hasLayout());
    assertNoErrors(panel);
    // check hierarchy
    assertHierarchy("{this: com.gwtext.client.widgets.grid.GridPanel} {this} {}");
  }
View Full Code Here


  /**
   * We have <code>setStore()</code> invocation, however it was not executed (because of instance
   * method), so we need to set <code>Store</code>.
   */
  public void test_parseWithInvalid_setStore() throws Exception {
    GridPanelInfo panel =
        parseJavaInfo(
            "import com.gwtext.client.data.Store;",
            "public class Test extends GridPanel {",
            "  public Test() {",
            "    setStore(createStore());",
            "  }",
            "  private Store createStore() {",
            "    return null;",
            "  }",
            "}");
    panel.refresh();
    // check hierarchy
    assertHierarchy("{this: com.gwtext.client.widgets.grid.GridPanel} {this} {/setStore(createStore())/}");
  }
View Full Code Here

            "    RootPanel rootPanel = RootPanel.get();",
            "  }",
            "}");
    frame.refresh();
    //
    GridPanelInfo gridPanel = createJavaInfo("com.gwtext.client.widgets.grid.GridPanel");
    gridPanel.putArbitraryValue(JavaInfo.FLAG_MANUAL_COMPONENT, Boolean.TRUE);
    {
      Image image = gridPanel.getImage();
      org.eclipse.swt.graphics.Rectangle bounds = image.getBounds();
      assertThat(bounds.width).isEqualTo(320);
      assertThat(bounds.height).isEqualTo(100);
    }
  }
View Full Code Here

            "    }",
            "  }",
            "}");
    frame.refresh();
    //
    GridPanelInfo grid = (GridPanelInfo) frame.getChildrenJava().get(0);
    assertNoErrors(frame);
    assertHierarchy( // filler
    "{RootPanel.get()} {local-unique: rootPanel} {/RootPanel.get()/ /rootPanel.add(grid, 100, 100)/}\n"
        + "  {new: com.gwtext.client.widgets.grid.GridPanel} {local-unique: grid} {/new GridPanel()/ /grid.setColumnModel(new ColumnModel(columns))/ /rootPanel.add(grid, 100, 100)/}\n"
        + "    {new: com.gwtext.client.widgets.grid.ColumnConfig} {empty} {/new ColumnConfig(\"AAA\", \"f1\", 50)/}\n"
        + "    {new: com.gwtext.client.widgets.grid.ColumnConfig} {empty} {/new ColumnConfig(\"BBB\", \"f3\")/}");
    List<ColumnConfigInfo> columns = grid.getColumns();
    assertThat(columns.size()).isEqualTo(2);
    assertThat(columns.get(0).getBounds()).isEqualTo(new Rectangle(2, 2, 50, 23));
    assertThat(columns.get(1).getBounds()).isEqualTo(new Rectangle(52, 2, 100, 23));
  }
View Full Code Here

            "      rootPanel.add(grid, 100, 100);",
            "    }",
            "  }",
            "}");
    frame.refresh();
    GridPanelInfo grid = (GridPanelInfo) frame.getChildrenJava().get(0);
    // create column
    {
      ColumnConfigInfo newColumn = createJavaInfo("com.gwtext.client.widgets.grid.ColumnConfig");
      flowContainer_CREATE(grid, newColumn, null);
    }
View Full Code Here

            "      rootPanel.add(grid, 100, 100);",
            "    }",
            "  }",
            "}");
    frame.refresh();
    GridPanelInfo grid = (GridPanelInfo) frame.getChildrenJava().get(0);
    // create column
    List<ColumnConfigInfo> columns = grid.getColumns();
    ColumnConfigInfo columnA = columns.get(0);
    ColumnConfigInfo columnB = columns.get(1);
    flowContainer_MOVE(grid, columnB, columnA);
    assertEditor(// filler;
        "public class Test implements EntryPoint {",
View Full Code Here

TOP

Related Classes of com.google.gdt.eclipse.designer.gwtext.model.widgets.GridPanelInfo

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.