List of usage examples for com.vaadin.ui Button setDescription
public void setDescription(String description)
From source file:org.escidoc.browser.ui.useraccount.UserAccountView.java
License:Open Source License
private Button buildAddAttributeButton(final UserAccountAttributes attributeTable) { final Button addAttributeButton = new Button(); addAttributeButton.setDescription("Add new Attribute"); addAttributeButton.setIcon(new ThemeResource("images/assets/plus.png")); addAttributeButton.addListener(new OnAddAttribute(addAttributeButton, attributeTable)); return addAttributeButton; }
From source file:org.escidoc.browser.ui.useraccount.UserAccountView.java
License:Open Source License
private Button buildAddPreferenceButton(final Panel preferencePanel, final UserAccountPreferences userPrefTable) { final Button addPreferenceButton = new Button(); addPreferenceButton.setDescription("Add new Preference"); addPreferenceButton.setIcon(new ThemeResource("images/assets/plus.png")); addPreferenceButton/*from w w w . ja v a 2 s. c o m*/ .addListener(new OnAddPreference(this, preferencePanel, userPrefTable, addPreferenceButton)); return addPreferenceButton; }
From source file:org.escidoc.browser.ui.view.helpers.CloseTabsViewHelper.java
License:Open Source License
private void buildButton() { Button btnRemoveTabs = new Button(); ThemeResource icon = new ThemeResource("images/assets/close.gif"); btnRemoveTabs.setStyleName(BaseTheme.BUTTON_LINK); btnRemoveTabs.addStyleName("closeallTabs"); btnRemoveTabs.setDescription(ViewConstants.CLOSE_ALL_OPEN_TABS); btnRemoveTabs.setIcon(icon);/*from www.j ava 2 s . c o m*/ btnRemoveTabs.addStyleName(ViewConstants.FLOAT_RIGHT); btnRemoveTabs.addListener(this); layout.addComponent(btnRemoveTabs); }
From source file:org.escidoc.browser.ui.view.helpers.CreateResourceLinksVH.java
License:Open Source License
public CreateResourceLinksVH(String url, ResourceProxy resourceProxy, AbstractComponentContainer componentContainer, Router router) { HorizontalLayout vl = buildInitialElements(); if (resourceProxy.getType().equals(ResourceType.ITEM)) { vl.setStyleName("permanentLinkItem"); } else {/*ww w. j av a 2 s . c o m*/ vl.setStyleName("permanentLink"); } if (!resourceProxy.getType().equals(ResourceType.CONTEXT)) { final Button btnVersionHistory = new Button(" ", new VersionHistoryClickListener(resourceProxy, router.getMainWindow(), router.getRepositories())); btnVersionHistory.setStyleName(BaseTheme.BUTTON_LINK); btnVersionHistory.setDescription("Show Version history in a Pop-up"); btnVersionHistory.addStyleName("paddingright10"); btnVersionHistory.setIcon(ICON_HISTORY); vl.addComponent(btnVersionHistory); } try { l = new Link("", new ExternalResource( url + "?id=" + resourceProxy.getId() + "&type=" + resourceProxy.getType().toString() + "&escidocurl=" + router.getServiceLocation().getEscidocUrl())); l.setDescription(ViewConstants.PERMANENT_LINK); l.setIcon(new ThemeResource("images/wpzoom/globe-1.png")); vl.addComponent(l); } catch (MalformedURLException e) { componentContainer.getWindow().showNotification(ViewConstants.COULD_NOT_RETRIEVE_APPLICATION_URL); LOG.error(ViewConstants.COULD_NOT_RETRIEVE_APPLICATION_URL + e.getLocalizedMessage()); } componentContainer.addComponent(hl); }
From source file:org.escidoc.browser.ui.view.helpers.CreateResourceLinksVH.java
License:Open Source License
public CreateResourceLinksVH(String url, UserProxy userProxy, AbstractComponentContainer componentContainer, Router router, UserAccountController controller) { buildInitialElements();//from ww w. ja v a2s. c o m // Checking if has access on changing password here as well HorizontalLayout hl = buildInitialElements(); hl.setStyleName("permanentLink"); final Button btnVersionHistory = new Button(" ", new ChangeUserPassword(userProxy, router, controller)); btnVersionHistory.setStyleName(BaseTheme.BUTTON_LINK); btnVersionHistory.setDescription("Change user password"); btnVersionHistory.addStyleName("paddingright10"); btnVersionHistory.setIcon(ICON_KEY); hl.addComponent(btnVersionHistory); componentContainer.addComponent(hl); }
From source file:org.escidoc.browser.ui.view.helpers.FolderChildrenVH.java
License:Open Source License
private Button showIcon(final ResourceModel child) { Button icon = new Button(); icon.setStyleName(BaseTheme.BUTTON_LINK); LOG.debug(child.getType().toString()); if (child.getType().toString().equals(ResourceType.CONTAINER.toString())) { icon.setDescription("Container"); icon.setIcon(new ThemeResource("images/Container.png")); } else {/*from www . ja v a 2s .c o m*/ icon.setDescription("Item"); icon.setIcon(new ThemeResource("images/Item.png")); } return icon; }
From source file:org.escidoc.browser.ui.view.helpers.FolderChildrenVH.java
License:Open Source License
private Button showEdit(final ResourceModel child) { Button edit = new Button(); edit.setStyleName(BaseTheme.BUTTON_LINK); edit.setDescription("Edit"); edit.setIcon(new ThemeResource("images/wpzoom/pencil.png")); edit.addListener(new Button.ClickListener() { @Override/*from w w w . j a v a2 s. c o m*/ public void buttonClick(ClickEvent event) { folderController.getRouter().getMainWindow().showNotification( "Not yet Implemented " + child.getId(), Notification.TYPE_HUMANIZED_MESSAGE); } }); return edit; }
From source file:org.escidoc.browser.ui.view.helpers.FolderChildrenVH.java
License:Open Source License
private Button showDelete(final ResourceModel child) { Button edit = new Button(); edit.setStyleName(BaseTheme.BUTTON_LINK); edit.setDescription(ViewConstants.PROPERTY_DELETE); edit.setIcon(new ThemeResource("images/wpzoom/trash.png")); edit.addListener(new Button.ClickListener() { @Override//from w w w. ja v a 2 s. c o m public void buttonClick(ClickEvent event) { folderController.getRouter().getMainWindow().showNotification( "Not yet Implemented " + child.getId(), Notification.TYPE_HUMANIZED_MESSAGE); } }); return edit; }
From source file:org.escidoc.browser.ui.view.helpers.FolderChildrenVH.java
License:Open Source License
private Button showShare(final ResourceModel child) { Button edit = new Button(); edit.setStyleName(BaseTheme.BUTTON_LINK); edit.setDescription(ViewConstants.PROPERTY_SHARE); edit.setIcon(new ThemeResource("images/wpzoom/share.png")); edit.addListener(new Button.ClickListener() { @Override//from ww w .j av a 2 s. com public void buttonClick(ClickEvent event) { folderController.getRouter().getMainWindow().showNotification( "Not yet Implemented " + child.getId(), Notification.TYPE_HUMANIZED_MESSAGE); } }); return edit; }
From source file:org.escidoc.browser.ui.view.helpers.FolderChildrenVH.java
License:Open Source License
private Button downloadShow(final ResourceModel child) { Button edit = new Button(); edit.setStyleName(BaseTheme.BUTTON_LINK); edit.setDescription(ViewConstants.PROPERTY_DOWNLOAD); edit.setIcon(new ThemeResource("images/wpzoom/eye.png")); edit.addListener(new Button.ClickListener() { @Override/* www . jav a2 s . c o m*/ public void buttonClick(ClickEvent event) { folderController.getRouter().getMainWindow().showNotification( "Not yet Implemented " + child.getId(), Notification.TYPE_HUMANIZED_MESSAGE); } }); return edit; }