List of usage examples for com.google.gwt.user.client.ui DecoratedStackPanel DecoratedStackPanel
public DecoratedStackPanel()
From source file:com.calclab.emite.hablar.client.PagesContainer.java
License:Open Source License
public PagesContainer(final RosterView rosterView) { stack = new DecoratedStackPanel(); stack.add(rosterView, "roster"); add(stack, DockPanel.CENTER); }
From source file:com.google.gwt.sample.showcase.client.content.lists.CwStackPanel.java
License:Apache License
/** * Initialize this example./*from w ww . j a v a2 s. c o m*/ */ @ShowcaseSource @Override public Widget onInitialize() { // Get the images Images images = (Images) GWT.create(Images.class); // Create a new stack panel DecoratedStackPanel stackPanel = new DecoratedStackPanel(); stackPanel.setWidth("200px"); // Add the Mail folders String mailHeader = getHeaderString(constants.cwStackPanelMailHeader(), images.mailgroup()); stackPanel.add(createMailItem(images), mailHeader, true); // Add a list of filters String filtersHeader = getHeaderString(constants.cwStackPanelFiltersHeader(), images.filtersgroup()); stackPanel.add(createFiltersItem(), filtersHeader, true); // Add a list of contacts String contactsHeader = getHeaderString(constants.cwStackPanelContactsHeader(), images.contactsgroup()); stackPanel.add(createContactsItem(images), contactsHeader, true); // Return the stack panel stackPanel.ensureDebugId("cwStackPanel"); return stackPanel; }
From source file:com.hazelcast.monitor.client.HazelcastMonitor.java
License:Open Source License
/** * This is the entry point method.//from w w w . j a v a 2s .co m */ public void onModuleLoad() { mainPanel = new HorizontalSplitPanel(); mainPanel.setSplitPosition(LEFT_PANEL_SIZE); VerticalPanel leftPanel = new VerticalPanel(); Image image = new Image("images/logo_3.png"); leftPanel.add(image); clusterAddPanel = createClusterAddPanel(); leftPanel.add(clusterAddPanel); dsPanel = new DecoratedStackPanel(); dsPanel.setWidth(LEFT_PANEL_SIZE); leftPanel.add(dsPanel); mainPanel.setLeftWidget(leftPanel); VerticalPanel rightPanel = new VerticalPanel(); mainPanel.setRightWidget(rightPanel); VerticalSplitPanel topPanel = new VerticalSplitPanel(); topPanel.setSize("100%", "100%"); topPanel.setSplitPosition("100%"); topPanel.setTopWidget(mainPanel); topPanel.setBottomWidget(logBox); logBox.setWidth("100%"); logBox.setHeight("100%"); RootPanel.get().add(topPanel); // RootPanel.get().add(mainPanel); History.addValueChangeHandler(this); loadActiveClusterViews(); ServicesFactory servicesFactory = new ServicesFactory(); onValueChangeHandler = new OnValueChangeHandler(servicesFactory, this); }
From source file:com.unilorraine.projetdevie.client.ui.viewmodules.preparationmodule.PreparationModuleViewImpl.java
License:Open Source License
public PreparationModuleViewImpl() { DockPanel dockPanel = new DockPanel(); add(dockPanel);/*w w w .j av a 2s. co m*/ dockPanel.setSize("566px", "484px"); VerticalPanel titlePanel = new VerticalPanel(); dockPanel.add(titlePanel, DockPanel.NORTH); Label title = new Label("Pr\u00E9paration du projet de vie"); title.setStyleName("title"); titlePanel.add(title); title.setHeight("61px"); VerticalPanel verticalPanelProject = new VerticalPanel(); dockPanel.add(verticalPanelProject, DockPanel.WEST); HorizontalPanel horizontalPanel = new HorizontalPanel(); verticalPanelProject.add(horizontalPanel); //categoryChoice = new DetailViewerField("choice"); Label preparationLabel = new Label("Editez la cat\u00E9gorie : "); horizontalPanel.add(preparationLabel); preparationLabel.setWidth("177px"); preparationLabel.setStyleName("subtitle"); categoryLabel = new Label(""); categoryLabel.setStyleName("subtitle"); horizontalPanel.add(categoryLabel); categoryPicture = new DetailViewerField("picture"); categoryPicture.setType("image"); categoryPicture.setImageWidth(50); categoryPicture.setImageHeight(50); categoryName = new DetailViewerField("name"); DecoratedStackPanel decoratedStackPanel = new DecoratedStackPanel(); verticalPanelProject.add(decoratedStackPanel); decoratedStackPanel.setSize("303px", "381px"); tileGridActivities = new TileGrid(); tileGridActivities.setSize("292px", "432px"); tileGridActivities.setEdgeSize(0); tileGridActivities.setShowEdges(false); tileGridActivities.setTileWidth(80); tileGridActivities.setTileHeight(80); tileGridActivities.setCanAcceptDrop(true); tileGridActivities.setCanDrag(true); tileGridActivities.setFields(categoryPicture, categoryName); tileGridActivities.setData(new ActivityRecord[10]); decoratedStackPanel.add(tileGridActivities, "Activit\u00E9s du Projet de Vie", false); ScrollPanel scrollPanel = new ScrollPanel(); decoratedStackPanel.add(scrollPanel, "Unit\u00E9s de Choix", false); scrollPanel.setSize("300px", "443px"); unitPanel = new VerticalPanel(); scrollPanel.setWidget(unitPanel); unitPanel.setSize("292px", "443px"); VerticalPanel verticalPanel = new VerticalPanel(); dockPanel.add(verticalPanel, DockPanel.WEST); Label schemaLabel = new Label("Activit\u00E9s restantes"); schemaLabel.setStyleName("subtitle"); verticalPanel.add(schemaLabel); listGrid = new ListGrid(); listGrid.setSize("240px", "504px"); listGrid.setCanDragRecordsOut(true); listGrid.setCanAcceptDroppedRecords(true); listGrid.setCanReorderRecords(true); ListGridField nameField = new ListGridField("name"); ListGridField descriptionField = new ListGridField("description"); //lifeSpanField.setWidth(50); listGrid.setFields(nameField, descriptionField); verticalPanel.add(listGrid); listGrid.setData(new ActivityRecord[10]); Button btnSauverLeProjet = new Button("Sauver le projet"); btnSauverLeProjet.addClickHandler(new ClickHandler() { public void onClick(ClickEvent event) { listener.saveProject(); } }); verticalPanel.add(btnSauverLeProjet); savedWindow = new Window(); savedWindow.setAutoCenter(true); savedWindow.setShowModalMask(true); savedWindow.setSize("200px", "150px"); savedWindow.setShowTitle(true); savedWindow.setShowMinimizeButton(false); savedWindow.setTitle("Projet sauvegard\u00E9"); Label label = new Label("Le projet a \u00E9t\u00E9 sauv\u00E9"); label.setStyleName("bigText"); savedWindow.addItem(label); }
From source file:gwtquery.plugins.enhance.client.gwt.StackPanelWidgetFactory.java
License:Apache License
public StackPanel create(Element e) { StackPanel stackPanel = options.isDecorated() ? new DecoratedStackPanel() : new StackPanel(); WidgetsUtils.replaceOrAppend(e, stackPanel); GQuery contents = $(options.getContentSelector(), e); GQuery headers = $(options.getHeaderSelector(), e); for (int i = 0; i < contents.length(); i++) { Element content = contents.get(i); Element header = headers.get(i); Widget contentWidget = $(content).widget(); if (contentWidget == null) { contentWidget = new WidgetsHtmlPanel(content); }/*from w w w . java 2 s . c o m*/ stackPanel.add(contentWidget, header != null ? header.getInnerText() : "Undefined"); } return stackPanel; }
From source file:net.s17fabu.vip.gwt.showcase.client.content.lists.CwStackPanel.java
License:Apache License
/** * Initialize this example.// w w w. j a v a2s . c o m */ @Override public Widget onInitialize() { // Get the images Images images = (Images) GWT.create(Images.class); // Create a new stack panel DecoratedStackPanel stackPanel = new DecoratedStackPanel(); stackPanel.setWidth("200px"); // Add the Mail folders String mailHeader = getHeaderString(constants.cwStackPanelMailHeader(), images.mailgroup()); stackPanel.add(createMailItem(images), mailHeader, true); // Add a list of filters String filtersHeader = getHeaderString(constants.cwStackPanelFiltersHeader(), images.filtersgroup()); stackPanel.add(createFiltersItem(), filtersHeader, true); // Add a list of contacts String contactsHeader = getHeaderString(constants.cwStackPanelContactsHeader(), images.contactsgroup()); stackPanel.add(createContactsItem(images), contactsHeader, true); // Return the stack panel stackPanel.ensureDebugId("cwStackPanel"); return stackPanel; }
From source file:org.dataconservancy.dcs.access.client.upload.MetadataSetEditor.java
License:Apache License
public MetadataSetEditor() { this.stack = new DecoratedStackPanel(); VerticalPanel panel = new VerticalPanel(); panel.add(stack);//from www .j a v a2s. co m final TextBox schema = new TextBox(); Button add = new Button("Add"); Button remove = new Button("Remove"); HorizontalPanel hp = new HorizontalPanel(); hp.add(new Label("Schema:")); hp.add(schema); hp.add(add); hp.add(remove); hp.setVerticalAlignment(HasVerticalAlignment.ALIGN_BOTTOM); hp.setSpacing(5); panel.add(hp); add.addClickHandler(new ClickHandler() { public void onClick(ClickEvent arg0) { String s = schema.getText().trim(); if (s.length() > 0) { stack.add(new MetadataEditor(s), s); stack.showStack(stack.getWidgetCount() - 1); } } }); remove.addClickHandler(new ClickHandler() { public void onClick(ClickEvent arg0) { int i = stack.getSelectedIndex(); if (i != -1) { stack.remove(i); if (stack.getWidgetCount() > 0) { stack.showStack(0); } } } }); initWidget(panel); }
From source file:org.jbpm.form.builder.ng.client.fb.view.palette.AnimatedPaletteViewImpl.java
License:Apache License
public AnimatedPaletteViewImpl() { // LayoutPanel layoutPanel = new LayoutPanel(new BoxLayout(BoxLayout.Orientation.VERTICAL)); // layoutPanel.setLayoutData(new BoxLayoutData(BoxLayoutData.FillStyle.BOTH)); // layoutPanel.setAnimationEnabled(true); DecoratedStackPanel stackPanel = new DecoratedStackPanel(); stackPanel.setWidth("200px"); panel.setStylePrimaryName("fbStackPanel"); // layoutPanel.add(panel); // add(layoutPanel); stackPanel.add(panel);//www . ja v a 2 s . c o m add(stackPanel); this.dragController = CommonGlobals.getInstance().getDragController(); startDropController(this.dragController); }