Package com.google.gwt.topspin.ui.client

Examples of com.google.gwt.topspin.ui.client.Div


              css.reportHintletIndicator() + " " + className);
        }
      }

      // Rule name
      Div rowNameDiv = new Div(rowContainer);
      rowNameDiv.setText("All Hintlets");
      rowNameDiv.setStyleName(css.reportRowNameDiv());
    }
View Full Code Here


    List<ColorCodedValue> data = new ArrayList<ColorCodedValue>();
    data.add(new ColorCodedValue("A", 20, Color.LIGHT_GREY));
    data.add(new ColorCodedValue("B", 20, Color.LIGHTGREEN));
    data.add(new ColorCodedValue("C", 60, Color.INDIAN_RED));

    Div div = new Div(Root.getContainer());
    div.getElement().getStyle().setProperty("textAlign", "center");
    Container container = new DefaultContainerImpl(div.getElement());
     
    PieChart pieChart = new PieChart(container, data, resources);
    pieChart.showLegend();

    // Now lets test making a horizontal list
View Full Code Here

  public JavaScriptProfileRenderer(Container container, Resources resources,
      ManagesEventListeners listenerManager,
      SymbolServerController ssController, SourcePresenter sourcePresenter,
      JavaScriptProfile profile, SourceSymbolClickListener sourceClickCallback,
      ResizeCallback resizeCallback) {
    this.profileDiv = new Div(container);
    this.resources = resources;
    this.profile = profile;
    this.sourceClickCallback = sourceClickCallback;
    this.resizeCallback = resizeCallback;
    this.ssController = ssController;
View Full Code Here

      String className = indicator.getElement().getClassName();
      indicator.getElement().setClassName(
          css.reportHintletIndicator() + " " + className);

      // Rule name
      Div severityNameDiv = new Div(rowContainer);

      severityNameDiv.setText(HintRecord.severityToString(severity));
      severityNameDiv.setStyleName(css.reportRowNameDiv());
    }
View Full Code Here

              css.reportHintletIndicator() + " " + className);
        }
      }

      // Rule name
      Div ruleNameDiv = new Div(rowContainer);
      ruleNameDiv.setText(ruleName);
      ruleNameDiv.setStyleName(css.reportRowNameDiv());
    }
View Full Code Here

    eventTraceContainerCell.appendChild(treeDiv);

    hintletTree = createHintletTree(treeDiv);
    createEventTrace(eventTraceContainer, pieChartHeight);

    profileDiv = new Div(eventTraceContainer);
    updateProfile();

    // Ensure that window resizes don't mess up our row size due to text
    // reflow. Things may need to grow or shrink.
    manageEventListener(ResizeEvent.addResizeListener(
View Full Code Here

  private PieChart createPieChart(Container parent) {
    ensureData();
    // We put an extra div in there to center our piechart and to apply
    // the rounded corners and backing layer styles underneath the piechart.
    Div centeringDiv = new Div(parent);
    centeringDiv.addStyleName(getCss().pieChartContainer());
    PieChart chart = new PieChart(centeringDiv, data, resources);
    chart.showLegend();

    return chart;
  }
View Full Code Here

    public FilterPanel(Container parent) {
      super(parent);
      setStyleName(css.filterPanel());
      panelContainer = new DefaultContainerImpl(getElement());

      Div closeButton = new Div(panelContainer);
      closeButton.setStyleName(css.filterPanelClose());
      closeButton.addClickListener(new ClickListener() {

        public void onClick(ClickEvent event) {
          toggleFilterPanelVisible();
        }
View Full Code Here

    this.dataDispatcher = controller.getDataDispatcher();

    // Add in the menu items
    List<String> menuItems = MockModelGenerator.getDataSetNames();
    for (int i = 0; i < menuItems.size(); ++i) {
      Div menuItem = new Div(new DefaultContainerImpl(base.getElement()));
      menuItem.setStyleName(css.menuItem());
      menuItem.setText(menuItems.get(i));
      final int dataSetIndex = i;
      menuItem.addClickListener(new ClickListener() {
        public void onClick(ClickEvent event) {
          controller.doReset();
          MockModelGenerator.simulateDataSet(dataDispatcher, dataSetIndex);
        }
      });
View Full Code Here

    minInput.setText(Integer.toString((int) eventFilter.getMinDuration()));
    refreshEventTypeSelect(model);
  }

  private void buildFilterPanel(Container parent, SluggishnessModel model) {
    Div row1 = new Div(parent);
    Container row1Container = new DefaultContainerImpl(row1.getElement());
    Document doc = parent.getDocument();

    // Min Duration: ________
    Element minLabel = doc.createSpanElement();
    row1.getElement().appendChild(minLabel);
    minLabel.setInnerText("Minimum duration: ");
    minInput = new InputText(row1Container);
    minInput.setStyleName(css.filterPanelMinInput());
    minInput.addKeyUpListener(new KeyUpListener() {
      public void onKeyUp(KeyUpEvent event) {
        int minValue = 0;
        boolean exceptionEncountered = false;
        try {
          minValue = Integer.valueOf(minInput.getText());
        } catch (NumberFormatException ex) {
          // leave the filter alone
          exceptionEncountered = true;
          minInput.getElement().getStyle().setBackgroundColor("#ebb");
        }
        if (!exceptionEncountered && minValue >= 0) {
          eventFilter.setMinDuration(minValue);
          minInput.getElement().getStyle().setBackgroundColor("#fff");
          eventTable.renderTable();
        }
      }
    });

    // Event Type ======== %
    Element eventTypeLabel = doc.createSpanElement();
    row1.getElement().appendChild(eventTypeLabel);
    eventTypeLabel.getStyle().setPropertyPx("marginLeft", 10);
    eventTypeLabel.setInnerText("Event Type: ");

    createEventTypeSelect(row1Container, model);
    createEventTypePercentSelect(row1Container);

    // Always show events with: o logs o hintlets
    Element alwaysShowLabel = doc.createSpanElement();
    alwaysShowLabel.setInnerText("Always show: ");
    alwaysShowLabel.getStyle().setPropertyPx("marginLeft", 10);
    row1.getElement().appendChild(alwaysShowLabel);

    final CheckBox logsCheckBox = new CheckBox(row1Container);
    logsCheckBox.setChecked(true);
    Element logsLabel = doc.createSpanElement();
    logsLabel.setInnerText("Logs");
    row1.getElement().appendChild(logsLabel);
    logsCheckBox.addClickListener(new ClickListener() {
      public void onClick(ClickEvent event) {
        eventFilter.setFilterUserLogs(!logsCheckBox.isChecked());
        eventTable.renderTable();
      }
    });

    final CheckBox hintletsCheckBox = new CheckBox(row1Container);
    hintletsCheckBox.setChecked(true);
    Element hintletsLabel = doc.createSpanElement();
    hintletsLabel.setInnerText("Hints");
    row1.getElement().appendChild(hintletsLabel);
    hintletsCheckBox.addClickListener(new ClickListener() {
      public void onClick(ClickEvent event) {
        eventFilter.setFilterHints(!hintletsCheckBox.isChecked());
        eventTable.renderTable();
      }
View Full Code Here

TOP

Related Classes of com.google.gwt.topspin.ui.client.Div

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.