Here are the examples of the java api com.vaadin.icons.VaadinIcons.LINK taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
1 Examples
7
Source : DemoUI.java
with Apache License 2.0
from blackbluegl
with Apache License 2.0
from blackbluegl
@Override
protected void init(VaadinRequest request) {
UI.getCurrent().setLocale(Locale.ENGLISH);
// Initialize our new UI component
MeetingCalendar meetings = new MeetingCalendar();
meetings.setSizeFull();
ComboBox<Locale> localeBox = new ComboBox<>();
localeBox.sereplacedems(Locale.getAvailableLocales());
localeBox.setEmptySelectionAllowed(false);
localeBox.setValue(UI.getCurrent().getLocale());
localeBox.addValueChangeListener(e -> meetings.getCalendar().setLocale(e.getValue()));
ComboBox<String> zoneBox = new ComboBox<>();
zoneBox.sereplacedems(ZoneId.getAvailableZoneIds());
zoneBox.setEmptySelectionAllowed(false);
zoneBox.setValue(meetings.getCalendar().getZoneId().getId());
zoneBox.addValueChangeListener(e -> meetings.getCalendar().setZoneId(ZoneId.of(e.getValue())));
CalStyle initial = new CalStyle("Day 1 - 7", () -> meetings.getCalendar().withVisibleDays(1, 7));
ComboBox<CalStyle> calActionComboBox = new ComboBox<>();
calActionComboBox.sereplacedems(initial, new CalStyle("Day 1 - 5", () -> meetings.getCalendar().withVisibleDays(1, 5)), new CalStyle("Day 2 - 5", () -> meetings.getCalendar().withVisibleDays(2, 5)), new CalStyle("Day 6 - 7", () -> meetings.getCalendar().withVisibleDays(6, 7)));
calActionComboBox.addValueChangeListener(e -> e.getValue().act());
calActionComboBox.setEmptySelectionAllowed(false);
Button fixedSize = new Button("fixed Size", (Button.ClickEvent clickEvent) -> meetings.panel.setHeightUndefined());
fixedSize.setIcon(VaadinIcons.LINK);
Button fullSize = new Button("full Size", (Button.ClickEvent clickEvent) -> meetings.panel.setHeight(100, Unit.PERCENTAGE));
fullSize.setIcon(VaadinIcons.UNLINK);
ComboBox<Month> months = new ComboBox<>();
months.sereplacedems(Month.values());
months.sereplacedemCaptionGenerator(month -> month.getDisplayName(TextStyle.FULL, meetings.getCalendar().getLocale()));
months.setEmptySelectionAllowed(false);
months.addValueChangeListener(me -> meetings.switchToMonth(me.getValue()));
Button today = new Button("today", (Button.ClickEvent clickEvent) -> meetings.getCalendar().withDay(LocalDate.now()));
Button week = new Button("week", (Button.ClickEvent clickEvent) -> meetings.getCalendar().withWeek(LocalDate.now()));
HorizontalLayout nav = new HorizontalLayout(localeBox, zoneBox, fixedSize, fullSize, months, today, week, calActionComboBox);
// nav.setWidth("100%");
// Show it in the middle of the screen
final VerticalLayout layout = new VerticalLayout();
layout.setStyleName("demoContentLayout");
layout.setSizeFull();
layout.setMargin(true);
layout.setSpacing(true);
layout.addComponent(nav);
layout.addComponentsAndExpand(meetings);
setContent(layout);
calActionComboBox.setSelectedItem(initial);
}