Package com.google.gwt.user.client.ui

Examples of com.google.gwt.user.client.ui.DockLayoutPanel$LayoutData


    public void onModuleLoad() {
        Images images = GWT.create(Images.class);
        Cookies.removeCookie("broker_ip");
        brokerIp = Cookies.getCookie("broker_ip");

        DockLayoutPanel myDockLayoutPanel = new DockLayoutPanel(Unit.EM);
        // draw the environment
        FloorPlanWidget floorPlan = new FloorPlanWidget(myDockLayoutPanel, null);
        RootLayoutPanel rootPanel = RootLayoutPanel.get();

        SimplePanel greenLateralPanel = new SimplePanel();
        greenLateralPanel.setStyleName("lateral_panel");
        SimplePanel borderpanel = new SimplePanel();
        borderpanel.setStyleName("header_panel");
        myDockLayoutPanel.addWest(greenLateralPanel, 10);
        myDockLayoutPanel.addWest(borderpanel, 2);

        final OMSVGSVGElement svg = images.logo_svg().getSvg();
        SVGImage myImage = new SVGImage(svg) {
            protected void onAttach() {
                OMSVGRect viewBox = svg.getViewBox().getBaseVal();
                if (viewBox.getWidth() == 0 || viewBox.getHeight() == 0) {
                    OMSVGRect bbox = svg.getBBox();
                    bbox.assignTo(viewBox);
                }
                svg.getStyle().setWidth(300, Unit.PX);
                svg.getStyle().setHeight(130, Unit.PX);
                super.onAttach();
            }
        };

        myImage.setStyleName("logo");
        SimplePanel logoPanel = new SimplePanel();
        logoPanel.add(myImage);
        logoPanel.setStyleName("header_panel");
        myDockLayoutPanel.addNorth(logoPanel, 10.7);
        myDockLayoutPanel.addNorth(new EnvListBox(floorPlan), 2);
        SimplePanel footerPanel = new SimplePanel();
        footerPanel.setStyleName("header_panel");
        myDockLayoutPanel.addSouth(footerPanel, 4);
        rootPanel.add(myDockLayoutPanel);
        myDockLayoutPanel.add(floorPlan.getCanvas());

        //Temporal hack to the configuration until we decide about it 
        brokerIp = com.google.gwt.user.client.Window.Location.getHostName();
        init();
//    String brokerIp = Cookies.getCookie("broker_ip");
View Full Code Here


  public void onModuleLoad() {
    Images images = GWT.create(Images.class);
    Cookies.removeCookie("broker_ip");
    brokerIp = Cookies.getCookie("broker_ip");
   
    DockLayoutPanel myDockLayoutPanel = new DockLayoutPanel(Unit.EM);
    // draw the environment
    FloorPlanWidget floorPlan = new FloorPlanWidget(myDockLayoutPanel);
    RootLayoutPanel rootPanel = RootLayoutPanel.get();

    SimplePanel greenLateralPanel = new SimplePanel();
    greenLateralPanel.setStyleName("lateral_panel");
    SimplePanel borderpanel = new SimplePanel();
    borderpanel.setStyleName("header_panel");
    myDockLayoutPanel.addWest(greenLateralPanel, 10);
    myDockLayoutPanel.addWest(borderpanel, 2);

    final OMSVGSVGElement svg = images.logo_svg().getSvg();
    SVGImage myImage = new SVGImage(svg)
    {
      protected void onAttach() {
          OMSVGRect viewBox = svg.getViewBox().getBaseVal();
        if (viewBox.getWidth() == 0 || viewBox.getHeight() == 0) {
          OMSVGRect bbox = svg.getBBox();
          bbox.assignTo(viewBox);
        }       
        svg.getStyle().setWidth(300, Unit.PX);
        svg.getStyle().setHeight(130, Unit.PX);
        super.onAttach();
        }
    }
                       
    myImage.setStyleName("logo");
    SimplePanel logoPanel = new SimplePanel();
    logoPanel.add(myImage);
    logoPanel.setStyleName("header_panel");     
    myDockLayoutPanel.addNorth(logoPanel, 10.7);   
   
    SimplePanel footerPanel = new SimplePanel();
    footerPanel.setStyleName("header_panel");
    myDockLayoutPanel.addSouth(footerPanel, 4);
    rootPanel.add(myDockLayoutPanel);
    myDockLayoutPanel.add(floorPlan.getCanvas());
           
  //Temporal hack to the configuration until we decide about it 
    brokerIp = com.google.gwt.user.client.Window.Location.getHostName();
    init();
//    String brokerIp = Cookies.getCookie("broker_ip");
View Full Code Here

  // 85.88801
  public void onModuleLoad() {
    lastCircle.add(0);
    max[0] = max[1] = 0;
    dlp = new DockLayoutPanel(Unit.PCT);
    VerticalPanel vp = createSidePanel();
    HorizontalPanel ap = createCanvas(WIDTH, HEIGHT, circleRadius,
        ballRadius, side);

    dlp.addWest(new ScrollPanel(vp), 20);
View Full Code Here

    loginPresenter.go(root);
  }

  private void goAfterLogin() {

    DockLayoutPanel outer = (DockLayoutPanel) binder.createAndBindUi(this);
    root = RootLayoutPanel.get();
    root.clear();
    root.add(outer);

    // final MessagesServiceAsync messagesService =
View Full Code Here

    map.setSize("100%", "100%");
    map.setCenter(zero, 0);
    MapUIOptions options = MapUIOptions.newInstance(Size.newInstance(200, 200));
    options.setDoubleClick(doubleClickToZoom);
    map.setUI(options);
    DockLayoutPanel panel = new DockLayoutPanel(Unit.PCT);
    panel.add(map);
    initWidget(panel);
  }
View Full Code Here

   */
  public PersonBrowser(PeopleService people, int height, String noPhotoUrl) {
    this.people = people;
    this.cellSize = height;
    this.noPhotoUrl = noPhotoUrl;
    DockLayoutPanel panel = new DockLayoutPanel(Unit.PX);

    friendsGrid = new Grid(1, pageSize);
    friendsGrid.setWidth("100%");
    friendsGrid.setCellPadding(0);
    friendsGrid.setCellSpacing(0);

    Button prevButton = new Button("<");
    Button nextButton = new Button(">");

    prevButton.addClickHandler(new ClickHandler() {
      public void onClick(ClickEvent event) {
        start = Math.max(start - 1, 0);
        showItems();
      }
    });

    nextButton.addClickHandler(new ClickHandler() {
      public void onClick(ClickEvent event) {
        start = Math.min(start + 1, Math.max(total - pageSize, 0));
        showItems();
      }
    });

    panel.addWest(prevButton, BUTTON_WIDTH);
    panel.addEast(nextButton, BUTTON_WIDTH);
    panel.add(friendsGrid);

    showItems();

    initWidget(panel);
  }
View Full Code Here

              }
            });
      }
    });

    DockLayoutPanel friendsTab = new DockLayoutPanel(Unit.PX);
    friendsTab.addNorth(browser, FRIENDS_DOCK_HEIGHT);
    friendsTab.add(friendsMap);

    // Building top level panel

    final TabLayoutPanel tabs = new TabLayoutPanel(1.5, Unit.EM);
    tabs.add(personalMap, "My Map");
View Full Code Here

  protected void init(MealPreferences preferences) {
    initDishes(preferences);

    // Create a table with a checklist of all available dishes based on the
    // user's dietary preferences.
    Panel p = new DockLayoutPanel(Unit.PX);
    p.setWidth("100%");

    FlexTable ft = new FlexTable();

    int index = 0;
    for (String dish : dishes) {
      CheckBox cb = new CheckBox();
      final String dishCopy = dish;
      cb.addClickHandler(new ClickHandler() {
        public void onClick(ClickEvent event) {
          Window.alert("Your order of " + dishCopy + " will be right up.");
        }
      });
      ft.setWidget(index, 0, cb);
      ft.setHTML(index, 1, dish);
      index++;
    }
    p.add(ft);
    RootLayoutPanel.get().add(p);
  }
View Full Code Here

  private TopicListDataProvider provider;
 
  public TopicListWidget()
  {
   
    DockLayoutPanel dockLayoutPanel = new DockLayoutPanel(Unit.EM);
    initWidget(dockLayoutPanel);
   
    cellTable = new CellTable<TopicGWT>();
    cellTable.setWidth("100%");
   
   
    TextColumn<TopicGWT> textColumn = new TextColumn<TopicGWT>() {
      @Override
      public String getValue(TopicGWT object) {
        return object.getTopicGuid();
      }
    };
    cellTable.addColumn(textColumn, "Topic");
   
    simplePager = new SimplePager();
    simplePager.setWidth("100%");
    simplePager.setDisplay(cellTable);
   
    dockLayoutPanel.addSouth(simplePager, 7.7);
    dockLayoutPanel.add(cellTable);
   
   
   
    // Associate an async data provider to the table
    provider = new TopicListDataProvider();
View Full Code Here

  private MessageListDataProvider provider;

  public MessageListWidget()
  {
   
    DockLayoutPanel dockLayoutPanel = new DockLayoutPanel(Unit.EM);
    initWidget(dockLayoutPanel);
   
    FlowPanel toolbarPanel = new FlowPanel();
    dockLayoutPanel.addNorth(toolbarPanel, 7.7);
   
    messageTable = new CellTable<MessageGWT>();
    dockLayoutPanel.add(messageTable);
   
    Column<MessageGWT, Date> column = new Column<MessageGWT, Date>(new DateCell()) {
      @Override
      public Date getValue(MessageGWT object) {
        return new Date(object.getPublishedTimestamp());
View Full Code Here

TOP

Related Classes of com.google.gwt.user.client.ui.DockLayoutPanel$LayoutData

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.