List of usage examples for com.vaadin.server FontAwesome ADJUST
FontAwesome ADJUST
To view the source code for com.vaadin.server FontAwesome ADJUST.
Click Source Link
From source file:com.mycollab.module.crm.view.activity.CallListDashlet.java
License:Open Source License
public CallListDashlet() { super(UserUIContext.getMessage(CallI18nEnum.MY_ITEMS), new VerticalLayout()); this.setMargin(new MarginInfo(true, false, false, false)); tableItem = new CallTableDisplay(new TableViewField(null, "isClosed", WebUIConstants.TABLE_CONTROL_WIDTH), Arrays.asList(//from ww w .ja va 2s . co m new TableViewField(CallI18nEnum.FORM_SUBJECT, "subject", WebUIConstants.TABLE_X_LABEL_WIDTH), new TableViewField(GenericI18Enum.FORM_START_DATE, "startdate", WebUIConstants.TABLE_DATE_TIME_WIDTH), new TableViewField(GenericI18Enum.FORM_STATUS, "status", WebUIConstants.TABLE_S_LABEL_WIDTH))); tableItem.addTableListener(event -> { final SimpleCall call = (SimpleCall) event.getData(); if ("isClosed".equals(event.getFieldName())) { call.setIsclosed(true); final CallService callService = AppContextUtil.getSpringBean(CallService.class); callService.updateWithSession(call, UserUIContext.getUsername()); display(); } }); bodyContent.addComponent(tableItem); MButton customizeViewBtn = new MButton("", clickEvent -> { }).withIcon(FontAwesome.ADJUST).withStyleName(WebThemes.BUTTON_SMALL_PADDING) .withDescription(UserUIContext.getMessage(GenericI18Enum.OPT_LAYOUT_OPTIONS)); this.addHeaderElement(customizeViewBtn); }
From source file:com.mycollab.module.crm.view.activity.MeetingListDashlet.java
License:Open Source License
public MeetingListDashlet() { super(UserUIContext.getMessage(MeetingI18nEnum.MY_ITEMS), new VerticalLayout()); this.setMargin(new MarginInfo(true, false, false, false)); tableItem = new MeetingTableDisplay(Arrays.asList( new TableViewField(MeetingI18nEnum.FORM_SUBJECT, "subject", WebUIConstants.TABLE_X_LABEL_WIDTH), new TableViewField(GenericI18Enum.FORM_START_DATE, "startdate", WebUIConstants.TABLE_DATE_TIME_WIDTH), new TableViewField(GenericI18Enum.FORM_STATUS, "status", WebUIConstants.TABLE_S_LABEL_WIDTH))); bodyContent.addComponent(tableItem); MButton customizeViewBtn = new MButton("", clickEvent -> { }).withIcon(FontAwesome.ADJUST).withStyleName(WebThemes.BUTTON_SMALL_PADDING) .withDescription(UserUIContext.getMessage(GenericI18Enum.OPT_LAYOUT_OPTIONS)); this.addHeaderElement(customizeViewBtn); }
From source file:com.mycollab.module.crm.view.lead.LeadListDashlet.java
License:Open Source License
public LeadListDashlet() { super(UserUIContext.getMessage(LeadI18nEnum.MY_ITEMS), new VerticalLayout()); this.setMargin(new MarginInfo(true, false, false, false)); tableItem = new LeadTableDisplay(Arrays.asList(LeadTableFieldDef.name(), LeadTableFieldDef.email(), LeadTableFieldDef.phoneoffice())); bodyContent.addComponent(tableItem); MButton customizeViewBtn = new MButton("", clickEvent -> UI.getCurrent().addWindow(new LeadListCustomizeWindow(tableItem))) .withIcon(FontAwesome.ADJUST).withStyleName(WebThemes.BUTTON_SMALL_PADDING); customizeViewBtn.setDescription(UserUIContext.getMessage(GenericI18Enum.OPT_LAYOUT_OPTIONS)); this.addHeaderElement(customizeViewBtn); }
From source file:com.mycollab.module.project.view.ProjectListViewImpl.java
License:Open Source License
private ComponentContainer constructTableActionControls() { MHorizontalLayout layout = new MHorizontalLayout().withFullWidth(); layout.addStyleName(WebThemes.TABLE_ACTION_CONTROLS); selectOptionButton = new SelectionOptionButton(tableItem); selectOptionButton.setWidthUndefined(); layout.addComponent(selectOptionButton); tableActionControls = new DefaultMassItemActionHandlerContainer(); tableActionControls.addDownloadPdfActionItem(); tableActionControls.addDownloadExcelActionItem(); tableActionControls.addDownloadCsvActionItem(); tableActionControls.setVisible(false); tableActionControls.setWidthUndefined(); layout.addComponent(tableActionControls); selectedItemsNumberLabel.setWidth("100%"); layout.with(selectedItemsNumberLabel).withAlign(selectedItemsNumberLabel, Alignment.MIDDLE_CENTER) .expand(selectedItemsNumberLabel); MButton customizeViewBtn = new MButton("", clickEvent -> UI.getCurrent().addWindow(new ProjectListCustomizeWindow(tableItem))) .withStyleName(WebThemes.BUTTON_ACTION).withIcon(FontAwesome.ADJUST); customizeViewBtn.setDescription(UserUIContext.getMessage(GenericI18Enum.OPT_LAYOUT_OPTIONS)); layout.with(customizeViewBtn).withAlign(customizeViewBtn, Alignment.MIDDLE_RIGHT); return layout; }
From source file:org.eclipse.hawkbit.ui.filtermanagement.CreateOrUpdateFilterTable.java
License:Open Source License
private Component getStatusIcon(final Object itemId) { final Item row1 = getItem(itemId); final TargetUpdateStatus targetStatus = (TargetUpdateStatus) row1 .getItemProperty(SPUILabelDefinitions.VAR_TARGET_STATUS).getValue(); final Label label = new LabelBuilder().name("").buildLabel(); label.setContentMode(ContentMode.HTML); if (targetStatus == TargetUpdateStatus.PENDING) { label.setDescription(i18n.getMessage(UIMessageIdProvider.TOOLTIP_STATUS_PENDING)); label.setStyleName(SPUIStyleDefinitions.STATUS_ICON_YELLOW); label.setValue(FontAwesome.ADJUST.getHtml()); } else if (targetStatus == TargetUpdateStatus.REGISTERED) { label.setDescription(i18n.getMessage(UIMessageIdProvider.TOOLTIP_STATUS_REGISTERED)); label.setStyleName(SPUIStyleDefinitions.STATUS_ICON_LIGHT_BLUE); label.setValue(FontAwesome.DOT_CIRCLE_O.getHtml()); } else if (targetStatus == TargetUpdateStatus.ERROR) { label.setDescription(i18n.getMessage(i18n.getMessage(UIMessageIdProvider.TOOLTIP_STATUS_ERROR))); label.setStyleName(SPUIStyleDefinitions.STATUS_ICON_RED); label.setValue(FontAwesome.EXCLAMATION_CIRCLE.getHtml()); } else if (targetStatus == TargetUpdateStatus.IN_SYNC) { label.setStyleName(SPUIStyleDefinitions.STATUS_ICON_GREEN); label.setDescription(i18n.getMessage(UIMessageIdProvider.TOOLTIP_STATUS_INSYNC)); label.setValue(FontAwesome.CHECK_CIRCLE.getHtml()); } else if (targetStatus == TargetUpdateStatus.UNKNOWN) { label.setStyleName(SPUIStyleDefinitions.STATUS_ICON_BLUE); label.setDescription(i18n.getMessage(UIMessageIdProvider.TOOLTIP_TARGET_STATUS_UNKNOWN)); label.setValue(FontAwesome.QUESTION_CIRCLE.getHtml()); }//from w w w . jav a 2 s . co m return label; }
From source file:org.eclipse.hawkbit.ui.management.actionhistory.ActionHistoryTable.java
License:Open Source License
/** * Get status icon.// www . j ava2 s . co m * * @param status * as Status * @return Label as UI */ private Label getStatusIcon(final Action.Status status) { final Label label = new LabelBuilder().name("").buildLabel(); final String statusIconPending = "statusIconPending"; label.setContentMode(ContentMode.HTML); if (Action.Status.FINISHED == status) { label.setDescription(i18n.get("label.finished")); label.setStyleName(STATUS_ICON_GREEN); label.setValue(FontAwesome.CHECK_CIRCLE.getHtml()); } else if (Action.Status.ERROR == status) { label.setDescription(i18n.get("label.error")); label.setStyleName("statusIconRed"); label.setValue(FontAwesome.EXCLAMATION_CIRCLE.getHtml()); } else if (Action.Status.WARNING == status) { label.setStyleName("statusIconOrange"); label.setDescription(i18n.get("label.warning")); label.setValue(FontAwesome.EXCLAMATION_CIRCLE.getHtml()); } else if (Action.Status.RUNNING == status) { // dynamic spinner label.setStyleName(statusIconPending); label.setDescription(i18n.get("label.running")); label.setValue(FontAwesome.ADJUST.getHtml()); } else if (Action.Status.CANCELING == status) { label.setStyleName(statusIconPending); label.setDescription(i18n.get("label.cancelling")); label.setValue(FontAwesome.TIMES_CIRCLE.getHtml()); } else if (Action.Status.CANCELED == status) { label.setStyleName(statusIconPending); label.setDescription(i18n.get("label.cancelled")); label.setStyleName(STATUS_ICON_GREEN); label.setValue(FontAwesome.TIMES_CIRCLE.getHtml()); } else if (Action.Status.RETRIEVED == status) { label.setStyleName(statusIconPending); label.setDescription(i18n.get("label.retrieved")); label.setValue(FontAwesome.CIRCLE_O.getHtml()); } else if (Action.Status.DOWNLOAD == status) { label.setStyleName(statusIconPending); label.setDescription(i18n.get("label.download")); label.setValue(FontAwesome.CLOUD_DOWNLOAD.getHtml()); } else if (Action.Status.SCHEDULED == status) { label.setStyleName(statusIconPending); label.setDescription(i18n.get("label.scheduled")); label.setValue(FontAwesome.HOURGLASS_1.getHtml()); } else { label.setDescription(""); label.setValue(""); } return label; }