public void openDrawer() { if (tableScreen.getValue()) { drawerOpened = true; drawerAnimation(); if (drawerListener != null) { drawerListener.onDrawerOpened(nav); } } }
public void closeDrawer() { if (tableScreen.getValue()) { drawerOpened = false; drawerAnimation(); if (drawerListener != null) { drawerListener.onDrawerClosed(nav); } } }
private void handleAlert(WebEvent<String> event) { numberOfAlerts.setValue(Integer.toString(Integer.valueOf(numberOfAlerts.getValue()) + 1)); String message = event.getData(); /* * Handle all the external onAlert event handlers first. */ for (EventHandler<WebEvent<String>> handler : alertListeners) handler.handle(event); /* * Finally display an alert box if the operator demands it. */ if (showAlerts.getValue()) { dialog.title("JavaScript Alert").message(message).showInformation(); resetParents(); } }