Java Code Examples for com.google.gwt.user.client.ui.VerticalPanel

The following examples show how to use com.google.gwt.user.client.ui.VerticalPanel. These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source Project: geowe-core   Source File: StatusPanelWidget.java    License: GNU General Public License v3.0 6 votes vote down vote up
private void initializeStatusPanel() {
	String comboWidth = "125px";
	statusPanel = new VerticalPanel();
	StyleInjector.inject(".statusPanelStyle { " + "background: #E0ECF8;"
			+ "border-radius: 5px 10px;" + "opacity: 0.8}");
	statusPanel.setStyleName("statusPanelStyle");

	statusPanel.setSpacing(5);
	statusPanel.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_CENTER);

	initializeLayerCombo(comboWidth);
	initializeEpsgCombo(comboWidth);
	initializeStatusGrid();

	statusPanel.add(new FieldLabel(layerCombo, UIMessages.INSTANCE
			.sbSelectLayerLabel()));
	statusPanel.add(new FieldLabel(epsgCombo, UIMessages.INSTANCE
			.sbEpsgLabel()));
	statusPanel.add(statusGrid);

	statusPanel.setVisible(false);
}
 
Example 2
Source Project: core   Source File: FormEditor.java    License: GNU Lesser General Public License v2.1 6 votes vote down vote up
public Widget asWidget() {
    VerticalPanel panel = new VerticalPanel();
    panel.setStyleName("fill-layout-width");

    form.setNumColumns(2);
    form.setEnabled(false);

    tools = new FormToolStrip<T>(form, callback);

    tools.providesDeleteOp(false);

    final FormHelpPanel helpPanel = new FormHelpPanel(
            new FormHelpPanel.AddressCallback() {
                @Override
                public ModelNode getAddress() {
                    return helpAddress;
                }
            }, form
    );

    panel.add(tools.asWidget());
    panel.add(helpPanel.asWidget());
    panel.add(form.asWidget());

    return panel;
}
 
Example 3
@SuppressWarnings("unchecked")
public Widget asWidget() {
    VerticalPanel panel = new VerticalPanel();
    panel.addStyleName("fill-layout-width");

    setupTable();
    dataProvider = new ListDataProvider<>();
    dataProvider.addDataDisplay(table);

    panel.add(setupTableButtons());

    panel.add(table);
    DefaultPager pager = new DefaultPager();
    pager.setDisplay(table);
    panel.add(pager);
    return panel;
}
 
Example 4
Source Project: core   Source File: UploadStep.java    License: GNU Lesser General Public License v2.1 6 votes vote down vote up
@Override
protected Widget asWidget(final Context context) {
    final FlowPanel panel = new FlowPanel();

    HTML description = new HTML(Console.CONSTANTS.common_label_chooseFile());
    description.getElement().setAttribute("style", "padding-bottom:15px;");
    panel.add(description);

    form = new FormPanel();

    // create a panel to hold all of the form widgets.
    VerticalPanel formPanel = new VerticalPanel();
    form.setWidget(formPanel);

    // create a FileUpload widgets.
    fileUpload = new FileUpload();
    fileUpload.setName("uploadFormElement");
    IdHelper.setId(fileUpload, id(), "file");
    formPanel.add(fileUpload);

    panel.add(form);
    return panel;
}
 
Example 5
Source Project: appinventor-extensions   Source File: OdeLog.java    License: Apache License 2.0 6 votes vote down vote up
/**
 * Creates a new output panel for displaying internal messages.
 */
private OdeLog() {
  // Initialize UI
  Button clearButton = new Button(MESSAGES.clearButton());
  clearButton.addClickHandler(new ClickHandler() {
    @Override
    public void onClick(ClickEvent event) {
      clear();
    }
  });

  text = new HTML();
  text.setWidth("100%");

  VerticalPanel panel = new VerticalPanel();
  panel.add(clearButton);
  panel.add(text);
  panel.setSize("100%", "100%");
  panel.setCellHeight(text, "100%");
  panel.setCellWidth(text, "100%");

  initWidget(panel);
}
 
Example 6
public GitHubExportDialog() {
	super();
	this.setHeadingText(UIMessages.INSTANCE.gitHubExportDialogTitle());
	this.getHeader().setIcon(ImageProvider.INSTANCE.github24());
	this.setPredefinedButtons(PredefinedButton.CANCEL);
	this.setPixelSize(350, 350);		
	this.setModal(true);
	this.setHideOnButtonClick(true);
	final VerticalPanel panel = new VerticalPanel();
	panel.add(createAuthenticationPanel());
	panel.add(createRepositoryPanel());
	panel.add(createCommitPanel());	
	add(panel);
	createButton = new TextButton(UIMessages.INSTANCE.gitHubCreateButton());
	updateButton = new TextButton(UIMessages.INSTANCE.gitHubUpdateButton());
			
	getButtonBar().add(createButton);
	getButtonBar().add(updateButton);		
}
 
Example 7
public VerticalPanel getEmptyPanel() {
	VerticalPanel geoDataContainer = new VerticalPanel();
	geoDataContainer.setSpacing(5);
	geoDataContainer.setWidth("280px");
	geoDataContainer.setSpacing(5);
	geoDataContainer.add(new Label(UIMessages.INSTANCE
			.createEmptyLayerToolText()));

	createAttributes = new CheckBox();
	createAttributes.setBoxLabel(UIMessages.INSTANCE
			.celtAddAttributesLabel());
	createAttributes.setValue(false);

	geoDataContainer.add(createAttributes);
	return geoDataContainer;
}
 
Example 8
@Override
public Widget asWidget() {
    VerticalPanel layout = new VerticalPanel();
    layout.setStyleName("window-content");
    SafeHtmlBuilder builder = new SafeHtmlBuilder();
    builder.append(Console.MESSAGES.access_control_provider());
    layout.add(new HTML(builder.toSafeHtml()));

    DialogueOptions options = new DialogueOptions(
            Console.CONSTANTS.common_label_done(),
            event -> presenter.closeWindow(),
            Console.CONSTANTS.common_label_cancel(),
            event -> presenter.closeWindow()
    );
    options.showCancel(false);
    return new WindowContentBuilder(new ScrollPanel(layout), options).build();
}
 
Example 9
private VerticalPanel getFoot() {
	slider.setWidth("290px");
	slider.disable();
	slider.setIncrement(1);

	slider.addValueChangeHandler(new ValueChangeHandler<Integer>() {

		@Override
		public void onValueChange(final ValueChangeEvent<Integer> event) {
			final Layer layer = getSelectedLayer(getSelectedTabName());
			layer.setOpacity((float) (event.getValue().intValue() / 100.0));
		}

	});

	final VerticalPanel panel = new VerticalPanel();
	panel.setWidth("300px");
	panel.addStyleName(ThemeStyles.get().style().borderTop());
	panel.add(new HTML(UIMessages.INSTANCE.lmOpacityHtmlLabel()));
	panel.add(slider);

	panel.add(statusBar);
	return panel;
}
 
Example 10
private VerticalPanel addComponentCategory(ComponentCategory category) {
  VerticalPanel panel = new VerticalPanel();
  panel.setWidth("100%");
  categoryPanels.put(category, panel);
  // The production version will not include a mapping for Extension because
  // only compile-time categories are included. This allows us to i18n the
  // Extension title for the palette.
  int insert_index = Collections.binarySearch(categoryOrder, category.ordinal());
  insert_index = - insert_index - 1;
  stackPalette.insert(panel, insert_index);
  String title = "";
  if (ComponentCategory.EXTENSION.equals(category)) {
    title = MESSAGES.extensionComponentPallette();
    initExtensionPanel();
  } else {
    title = ComponentsTranslation.getCategoryName(category.getName());
  }
  stackPalette.setStackText(insert_index, title);
  categoryOrder.add(insert_index, category.ordinal());
  // When the categories are loaded, we want the first one open, which will almost always be User Interface
  stackPalette.showStack(0);
  return panel;
}
 
Example 11
Source Project: swellrt   Source File: ComplexColorPicker.java    License: Apache License 2.0 6 votes vote down vote up
public ComplexColorPicker() {
  style.ensureInjected();

  // The background color can be set to "none"
  noneBtn = new PushButton(messages.none());
  noneBtn.addStyleName(ComplexColorPicker.style.buttonsMargins());
  noneBtn.setStylePrimaryName(ComplexColorPicker.style.customColorPushbutton());
  noneBtn.addClickHandler(new ClickHandler() {
    @Override
    public void onClick(ClickEvent event) {
      listener.onNoneColorChoose();
    }
  });

  vp = new VerticalPanel();

  // We use a simple color picker by default
  simplePicker = new SimpleColorPicker(this);
  vp.add(simplePicker);
  vp.add(noneBtn);
  super.add(vp);
}
 
Example 12
/**
 * Creates new component design panel for non-visible components.
 */
public SimpleNonVisibleComponentsPanel() {
  // Initialize UI
  VerticalPanel panel = new VerticalPanel();
  panel.setHorizontalAlignment(VerticalPanel.ALIGN_CENTER);

  heading = new Label("");
  heading.setStyleName("ya-NonVisibleComponentsHeader");
  panel.add(heading);

  componentsPanel = new FlowPanel();
  componentsPanel.setStyleName("ode-SimpleUiDesignerNonVisibleComponents");
  panel.add(componentsPanel);

  initWidget(panel);
}
 
Example 13
Source Project: geowe-core   Source File: OpenProjectDialog.java    License: GNU General Public License v3.0 6 votes vote down vote up
private SelectHandler createUrlToShare(final VerticalPanel geoDataContainer) {
	return new SelectHandler() {
		@Override
		public void onSelect(SelectEvent event) {
			urlToShareAnchor.setHref(getHref());
			urlToShareAnchor.setText(
					UIMessages.INSTANCE.seeOtherWindow("GeoWE Project"),
					Direction.LTR);

			urlShared.setText(getHref());
			urlPanel.setVisible(true);
			urlShared.setVisible(true);
		}

		private String getHref() {
			String baseUrl = GWT.getHostPageBaseURL();

			baseUrl += "?projectUrl="
					+ URL.encodeQueryString(urlTextField.getValue());

			return baseUrl;
		}
	};
}
 
Example 14
Source Project: appinventor-extensions   Source File: ProjectEditor.java    License: Apache License 2.0 6 votes vote down vote up
/**
 * Creates a {@code ProjectEditor} instance.
 *
 * @param projectRootNode  the project root node
 */
public ProjectEditor(ProjectRootNode projectRootNode) {
  this.projectRootNode = projectRootNode;
  projectId = projectRootNode.getProjectId();
  project = Ode.getInstance().getProjectManager().getProject(projectId);

  openFileEditors = Maps.newHashMap();
  fileIds = new ArrayList<String>();

  deckPanel = new DeckPanel();

  VerticalPanel panel = new VerticalPanel();
  panel.add(deckPanel);
  deckPanel.setSize("100%", "100%");
  panel.setSize("100%", "100%");
  initWidget(panel);
  // Note: I'm not sure that the setSize call below does anything useful.
  setSize("100%", "100%");
}
 
Example 15
Source Project: incubator-retired-wave   Source File: DialogBox.java    License: Apache License 2.0 6 votes vote down vote up
/**
 * Creates dialog box.
 *
 * @param popup - UniversalPopup on which the dialog is based
 * @param title - title placed in the title bar
 * @param innerWidget - the inner widget of the dialog
 * @param dialogButtons - buttons
 */
static public void create(UniversalPopup popup, String title, Widget innerWidget, DialogButton[] dialogButtons) {
  // Title
  popup.getTitleBar().setTitleText(title);

  VerticalPanel contents = new VerticalPanel();
  popup.add(contents);

  // Message
  contents.add(innerWidget);

  // Buttons
  HorizontalPanel buttonPanel = new HorizontalPanel();
  for(DialogButton dialogButton : dialogButtons) {
    Button button = new Button(dialogButton.getTitle());
    button.setStyleName(Dialog.getCss().dialogButton());
    buttonPanel.add(button);
    dialogButton.link(button);
  }
  contents.add(buttonPanel);
  buttonPanel.setStyleName(Dialog.getCss().dialogButtonPanel());
  contents.setCellHorizontalAlignment(buttonPanel, HasHorizontalAlignment.ALIGN_RIGHT);
}
 
Example 16
Source Project: appinventor-extensions   Source File: Ode.java    License: Apache License 2.0 6 votes vote down vote up
/**
 * This dialog is showned if an account is disabled. It is
 * completely modal with no escape. The provided URL is displayed in
 * an iframe, so it can be tailored to each person whose account is
 * disabled.
 *
 * @param Url the Url to display in the dialog box.
 */

public void disabledAccountDialog(String Url) {
  // Create the UI elements of the DialogBox
  final DialogBox dialogBox = new DialogBox(false, true); // DialogBox(autohide, modal)
  dialogBox.setStylePrimaryName("ode-DialogBox");
  dialogBox.setText(MESSAGES.accountDisabledMessage());
  dialogBox.setHeight("700px");
  dialogBox.setWidth("700px");
  dialogBox.setGlassEnabled(true);
  dialogBox.setAnimationEnabled(true);
  dialogBox.center();
  VerticalPanel DialogBoxContents = new VerticalPanel();
  HTML message = new HTML("<iframe src=\"" + Url + "\" style=\"border: 0; width: 680px; height: 660px;\"></iframe>");
  message.setStyleName("DialogBox-message");
  DialogBoxContents.add(message);
  dialogBox.setWidget(DialogBoxContents);
  dialogBox.show();
}
 
Example 17
Source Project: core   Source File: PIDTable.java    License: GNU Lesser General Public License v2.1 6 votes vote down vote up
Widget asWidget() {
    VerticalPanel layout = new VerticalPanel();
    layout.setStyleName("fill-layout-width");

    table = new DefaultCellTable<ConfigAdminData>(10);
    dataProvider = new ListDataProvider<ConfigAdminData>();
    dataProvider.addDataDisplay(table);

    TextColumn<ConfigAdminData> pidColumn = new TextColumn<ConfigAdminData>() {
        @Override
        public String getValue(ConfigAdminData pidEntry) {
            return pidEntry.getPid();
        }
    };
    table.addColumn(pidColumn, Console.CONSTANTS.subsys_configadmin_PIDShort());
    layout.add(table);

    DefaultPager pager = new DefaultPager();
    pager.setDisplay(table);
    layout.add(pager);

    return layout;
}
 
Example 18
private Widget createAuthenticationPanel() {
	final VerticalPanel panel = new VerticalPanel();
	panel.getElement().getStyle().setBackgroundColor("#E0ECF8");
	panel.setWidth("350px");		
	panel.setSpacing(10);

	userNameField = new TextField();
	userNameField.setTitle(UIMessages.INSTANCE.gitHubUserNameField());
	userNameField.setEmptyText(UIMessages.INSTANCE.gitHubUserNameField());
	userNameField.setWidth(FIELD_WIDTH);
	panel.add(userNameField);

	passwordField = new PasswordField();		
	passwordField.setTitle(UIMessages.INSTANCE.gitHubPasswordField());
	passwordField.setEmptyText(UIMessages.INSTANCE.gitHubPasswordField());
	passwordField.setWidth(FIELD_WIDTH);
	panel.add(passwordField);
	
	return panel;
}
 
Example 19
Source Project: gwteventbinder   Source File: SampleEntryPoint.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public void onModuleLoad() {
  // Create the object graph - a real application would use Gin
  SimpleEventBus eventBus = new SimpleEventBus();

  SidebarPresenter sidebarPresenter = new SidebarPresenter(eventBus);
  Button sidebarView = new Button("Contacts");
  sidebarView.getElement().getStyle().setFloat(Style.Float.LEFT);
  sidebarView.getElement().getStyle().setMarginRight(20, Unit.PX);
  sidebarPresenter.setView(sidebarView);
  RootPanel.get().add(sidebarView);

  ContactsPresenter contactsPresenter = new ContactsPresenter(eventBus);
  VerticalPanel contactsView = new VerticalPanel();
  contactsPresenter.setView(contactsView);
  RootPanel.get().add(contactsView);

  // Start listening for events in the presenter
  contactsPresenter.start();

  // Eagerly bind the server proxy
  ServerProxy server = new ServerProxy(eventBus);
}
 
Example 20
Source Project: core   Source File: ServerPicker.java    License: GNU Lesser General Public License v2.1 6 votes vote down vote up
public Widget asWidget() {

        VerticalPanel layout = new VerticalPanel();
        layout.getElement().setAttribute("title", "Select Server Instance");
        layout.setStyleName("fill-layout-width");
        //layout.addStyleName("lhs-selector");

        hostServerTable = new HostServerTable();

        hostServerTable.setPopupWidth(400);
        hostServerTable.setDescription(Console.CONSTANTS.server_instance_pleaseSelect());

        Widget widget = hostServerTable.asWidget();
        layout.add(widget);

        return layout;
    }
 
Example 21
Widget asWidget() {
    VerticalPanel layout = new VerticalPanel();
    layout.addStyleName("window-content");
    Form<ActivemqCoreQueue> form = new Form<>(ActivemqCoreQueue.class);

    TextBoxItem name = new TextBoxItem("name", "Name");
    TextBoxItem queueAddress = new TextBoxItem("queueAddress", "Address");
    TextBoxItem filter = new TextBoxItem("filter", "Filter", false);

    CheckBoxItem durable = new CheckBoxItem("durable", "Durable?");
    durable.setValue(true); // new queues are durable by default (AS7-4955)
    durable.setRequired(false);
    form.setFields(name, queueAddress, filter, durable);
    

    FormHelpPanel helpPanel = new FormHelpPanel(() -> {
        ModelNode address = Baseadress.get();
        address.add("subsystem", "messaging-activemq");
        address.add("server", presenter.getCurrentServer());
        address.add("queue", "*");
        return address;
    }, form);

    layout.add(helpPanel.asWidget());
    layout.add(form.asWidget());

    DialogueOptions options = new DialogueOptions(
            event -> {
                FormValidation validation = form.validate();
                if (!validation.hasErrors()) {
                    presenter.onCreateCoreQueue(form.getUpdatedEntity()); }
            },
            event -> presenter.closeDialogue()
    );

    return new WindowContentBuilder(layout, options).build();
}
 
Example 22
private VerticalPanel getAttrCombo() {
	VerticalPanel vPanel = new VerticalPanel();
	vPanel.setSpacing(5);
	vPanel.add(new Label(UIMessages.INSTANCE.asdAttributeLabel()));
	initializeAttributeLabelCombo(FIELD_WIDTH);
	vPanel.add(attributeCombo);

	return vPanel;
}
 
Example 23
Source Project: geowe-core   Source File: ExportDataDialog.java    License: GNU General Public License v3.0 5 votes vote down vote up
private Widget createPanel() {
	String comboWidth = "150px";

	vectorFormatCombo = new VectorFormatComboBox(comboWidth,
			VectorFormat.getSupportedExportVectorFormat());
	vectorFormatCombo.addSelectionHandler(getVectorComboSelectionHandler());
	vectorFormatCombo.setValue(VectorFormat.GEO_JSON_FORMAT);
	epsgCombo = new ProjectionComboBox(comboWidth);
	
	
	downloadFileButton = new TextButton(
			UIMessages.INSTANCE.downloadfileText());
	downloadFileButton.setIcon(ImageProvider.INSTANCE.download32());
	downloadFileButton.setIconAlign(IconAlign.TOP);
	
	gitHubButton = new TextButton(
			"GitHub");
	gitHubButton.setIcon(ImageProvider.INSTANCE.github32());
	gitHubButton.setIconAlign(IconAlign.TOP);

	HorizontalPanel horizontalGroup = new HorizontalPanel();
	horizontalGroup.getElement().getStyle().setBackgroundColor("#E0ECF8");
	horizontalGroup.setSpacing(10);

	VerticalPanel vPanel = new VerticalPanel();
	vPanel.setSpacing(5);
	vPanel.add(vectorFormatCombo);
	vPanel.add(epsgCombo);

	horizontalGroup.add(vPanel);
					
	horizontalGroup.add(downloadFileButton);
	horizontalGroup.add(gitHubButton);
	
	return horizontalGroup;
}
 
Example 24
Source Project: EasyML   Source File: StdPanel.java    License: Apache License 2.0 5 votes vote down vote up
protected void init(String msg, String title) {
	this.setTitle("stdErr");
	this.setGlassEnabled(true);

	HTML closeButton = new HTML("X");
	closeButton.setSize("10px", "10px");
	closeButton.setStyleName("closebtn");
	closeButton.addClickHandler(new ClickHandler() {
		@Override
		public void onClick(ClickEvent event) {
			StdPanel.this.hide();
		}
	});

	ScrollPanel scvp = new ScrollPanel();
	VerticalPanel verticalPanel = new VerticalPanel();

	verticalPanel.add(closeButton);
	verticalPanel.setCellHeight(closeButton, "30px");
	verticalPanel.setStyleName("vpanel");
	HTML desc = new HTML(title);
	desc.setStyleName("popupTitle");
	verticalPanel.add(desc);
	verticalPanel.setCellHeight(desc, "30px");

	TextArea label = new TextArea();
	label.setText(msg);
	label.setReadOnly(true);
	label.setSize("650px", "400px");
	verticalPanel.add(label);
	scvp.add(verticalPanel);
	this.add(scvp);
	this.setStyleName("loading_container");
	this.center();
	this.show();
}
 
Example 25
Source Project: core   Source File: StandalonePanel.java    License: GNU Lesser General Public License v2.1 5 votes vote down vote up
@Override
public Widget asWidget() {
    VerticalPanel panel = new VerticalPanel();
    panel.setStyleName("rhs-content-panel");
    panel.add(patchInfoPanel);

    DefaultTabLayoutPanel tabLayoutPanel = new DefaultTabLayoutPanel(40, Style.Unit.PX);
    tabLayoutPanel.addStyleName("default-tabpanel");
    tabLayoutPanel.add(new ScrollPanel(panel), "Patch Management");
    return tabLayoutPanel;
}
 
Example 26
Source Project: appinventor-extensions   Source File: GalleryPage.java    License: Apache License 2.0 5 votes vote down vote up
/**
   * Helper method called by constructor to initialize ui components
   */
  private void initComponents() {
    // Initialize UI
    panel = new VerticalPanel();
    panel.setWidth("100%");
    galleryGUI = new FlowPanel();
    appSingle = new FlowPanel();
    appDetails = new FlowPanel();
    appHeader = new FlowPanel();
    appInfo = new FlowPanel();
    appAction = new FlowPanel();
    appAuthor = new FlowPanel();
    appMeta = new FlowPanel();
    appDates = new FlowPanel();
    appPrimaryWrapper = new FlowPanel();
    appSecondaryWrapper = new FlowPanel();
    appDescPanel = new FlowPanel();
    appReportPanel = new FlowPanel();
    appSharePanel = new FlowPanel();
    appActionTabs = new TabPanel();
    sidebarTabs = new TabPanel();
    appComments = new FlowPanel();
    appCommentsList = new FlowPanel();
    appsByAuthor = new FlowPanel();
    appsByTags = new FlowPanel();
    appsRemixes = new FlowPanel();
    returnToGallery = new FlowPanel();
//    tagSelected = "";

    appCreated = new Label();
    appChanged = new Label();
    descBox = new FlowPanel();
    titleBox = new FlowPanel();
    desc = new TextArea();
    titleText = new TextArea();
    moreInfoText = new TextArea();
    creditText = new TextArea();
    ccLicenseRef = new HTML(MESSAGES.galleryCcLicenseRef());
    ccLicenseRef.addStyleName("app-action-html");
  }
 
Example 27
private Widget createPanel() {

		VerticalPanel vPanel = new VerticalPanel();
		vPanel.setPixelSize(490, 420);
		vPanel.setSpacing(5);
		vPanel.add(createTopPanel());
		vPanel.add(createBottomPanel());

		return vPanel;
	}
 
Example 28
Source Project: core   Source File: JndiView.java    License: GNU Lesser General Public License v2.1 5 votes vote down vote up
@Override
public Widget createWidget() {

    SimpleLayout layout = new SimpleLayout()
                           .setTitle(Console.CONSTANTS.subsys_naming_jndiView())
                           .setHeadline(Console.CONSTANTS.subsys_naming_jndiBindings());

    HTML refreshButton = new HTML("<i class='icon-refresh'></i> Refresh Results");
    refreshButton.setStyleName("html-link");
    refreshButton.getElement().getStyle().setPosition(Style.Position.RELATIVE);
    refreshButton.getElement().getStyle().setTop(-10, Style.Unit.PX);
    refreshButton.getElement().getStyle().setFloat(Style.Float.RIGHT);
    refreshButton.getElement().getStyle().setLeft(88, Style.Unit.PCT);

    layout.addContent("", refreshButton);

    refreshButton.ensureDebugId(Console.DEBUG_CONSTANTS.debug_label_refresh_jndiView());

    refreshButton.addClickHandler(new ClickHandler() {
        @Override
        public void onClick(ClickEvent event) {
            presenter.refresh();
        }
    });

    container = new VerticalPanel();
    container.setStyleName("fill-layout");

    layout.addContent("", container);

    return layout.build();
}
 
Example 29
Source Project: geowe-core   Source File: LayerInfoToolBar.java    License: GNU General Public License v3.0 5 votes vote down vote up
public LayerInfoToolBar() {
	super();
	setHeight("200px");
	setHeaderVisible(false);		
	
	tools = new ArrayList<FeatureTool>();
	verticalGroup = new VerticalPanel();		
	verticalGroup.setSpacing(3);
	verticalGroup.setVerticalAlignment(HasVerticalAlignment.ALIGN_TOP);
}
 
Example 30
Source Project: appinventor-extensions   Source File: MessagesOutput.java    License: Apache License 2.0 5 votes vote down vote up
/**
 * Creates a new output panel for messages.
 */
private MessagesOutput() {
  // Initialize UI
  text = new HTML();
  text.setSize("100%", "100%");
  text.setStylePrimaryName("ode-MessagesOutput");

  panel = new VerticalPanel();
  panel.add(text);
  panel.setSize("100%", "100%");
  panel.setCellHeight(text, "100%");
  panel.setCellWidth(text, "100%");

  initWidget(panel);
}