Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
book-of-vaadin.pdf
Скачиваний:
88
Добавлен:
24.03.2015
Размер:
13.43 Mб
Скачать

Mobile Applications with TouchKit

Figure 22.6. Popover in a Tablet Device

Alternatively, you can call the showRelativeTo(), which displays the sub-window relative to an existing component in the user interface.

Popover popover = new Popover(); popover.setContent(mailboxHierarchyView); popover.setClosable(true); popover.showRelativeTo(showMailboxHierarchyButton); popover.setHeight(getParent().getHeight() - 100, UNITS_PIXELS);

In this case, you should not call addWindow() explicitly.

Styling with CSS

.v-touchkit-popover .v-touchkit-fullscreen { }

.v-touchkit-popover .v-touchkit-relative { }

.v-touchkit-popover .v-touchkit-plain { }

The component has an overall v-touchkit-popover style. If full-screen, it also has the v-touchkit-fullscreen style, if positioned relatively it has v-touchkit-relative, and if not, the v-touchkit-plain style.

22.5.6. Switch

The Switch component is a CheckBox that looks like the switch button in Apple iOS.

Switch switch = new Switch(); switch.setCaption("Do I look like iOS?"); layout.addComponent(switch);

Styling with CSS

.v-touchkit-switch { }

.v-touchkit-switch-slider { }

The component has an overall v-touchkit-switch style. The slider element has v-touchkit-switch-slider style.

490

Switch

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]