com.vaadin.ui.renderers.HtmlRenderer Java Examples
The following examples show how to use
com.vaadin.ui.renderers.HtmlRenderer.
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 File: RolloutListGrid.java From hawkbit with Eclipse Public License 1.0 | 5 votes |
@Override protected void addColumnRenderers() { getColumn(SPUILabelDefinitions.VAR_NUMBER_OF_GROUPS).setRenderer(new HtmlRenderer(), new TotalTargetGroupsConverter()); getColumn(SPUILabelDefinitions.VAR_TOTAL_TARGETS_COUNT_STATUS).setRenderer(new HtmlRenderer(), new TotalTargetCountStatusConverter()); getColumn(SPUILabelDefinitions.VAR_STATUS).setRenderer(new HtmlLabelRenderer(), new RolloutStatusConverter()); getColumn(PROP_TYPE).setRenderer(new HtmlLabelRenderer(), new RolloutTypeConverter(this::createTypeLabelAdapter)); final RolloutRenderer customObjectRenderer = new RolloutRenderer(RolloutRendererData.class); customObjectRenderer.addClickListener(this::onClickOfRolloutName); getColumn(ROLLOUT_RENDERER_DATA).setRenderer(customObjectRenderer); getColumn(VIRT_PROP_RUN).setRenderer( new GridButtonRenderer(clickEvent -> startOrResumeRollout((Long) clickEvent.getItemId())), new RolloutGridButtonConverter(this::createRunButtonMetadata)); getColumn(VIRT_PROP_APPROVE).setRenderer( new GridButtonRenderer(clickEvent -> approveRollout((Long) clickEvent.getItemId())), new RolloutGridButtonConverter(this::createApprovalButtonMetadata)); getColumn(VIRT_PROP_PAUSE).setRenderer( new GridButtonRenderer(clickEvent -> pauseRollout((Long) clickEvent.getItemId())), new RolloutGridButtonConverter(this::createPauseButtonMetadata)); getColumn(VIRT_PROP_UPDATE).setRenderer( new GridButtonRenderer(clickEvent -> updateRollout((Long) clickEvent.getItemId())), new RolloutGridButtonConverter(this::createUpdateButtonMetadata)); getColumn(VIRT_PROP_COPY).setRenderer( new GridButtonRenderer(clickEvent -> copyRollout((Long) clickEvent.getItemId())), new RolloutGridButtonConverter(this::createCopyButtonMetadata)); getColumn(VIRT_PROP_DELETE).setRenderer( new GridButtonRenderer(clickEvent -> deleteRollout((Long) clickEvent.getItemId())), new RolloutGridButtonConverter(this::createDeleteButtonMetadata)); }
Example #2
Source File: RolloutGroupListGrid.java From hawkbit with Eclipse Public License 1.0 | 5 votes |
@Override protected void addColumnRenderers() { getColumn(SPUILabelDefinitions.VAR_STATUS).setRenderer(new HtmlLabelRenderer(), new RolloutGroupStatusConverter()); getColumn(SPUILabelDefinitions.VAR_TOTAL_TARGETS_COUNT_STATUS).setRenderer(new HtmlRenderer(), new TotalTargetCountStatusConverter()); if (permissionChecker.hasRolloutTargetsReadPermission()) { getColumn(ROLLOUT_RENDERER_DATA).setRenderer(new RolloutRenderer(new RolloutGroupClickListener())); } }
Example #3
Source File: SidebarMenuExtensionLayout.java From GridExtensionPack with Apache License 2.0 | 5 votes |
private void addGrid() { final Grid<TestFile> grid = new Grid<>("Attachment grid"); grid.addColumn(TestFile::getFileName).setCaption("File Name"); grid.addColumn(TestFile::isOpen).setHidable(true).setCaption("Is Open"); grid.addColumn(TestFile::createOpenLink, new HtmlRenderer()).setHidable(true).setCaption("Download"); grid.setColumnReorderingAllowed(true); addComponent(grid); extension = SidebarMenuExtension.create(grid); grid.setItems(Stream.of("Test file 1", "Test file 2").map(TestFile::new)); }
Example #4
Source File: WebHtmlRenderer.java From cuba with Apache License 2.0 | 4 votes |
@Override public HtmlRenderer getImplementation() { return (HtmlRenderer) super.getImplementation(); }
Example #5
Source File: WebHtmlRenderer.java From cuba with Apache License 2.0 | 4 votes |
@Override protected HtmlRenderer createImplementation() { return new HtmlRenderer(getNullRepresentation()); }