@Override public void onPreviewNativeEvent(NativePreviewEvent e) { NativeEvent nativeEvent = e.getNativeEvent(); if ("keydown".equals(nativeEvent.getType())) { if (nativeEvent.getKeyCode() == KeyCodes.KEY_ENTER) { doLogin(userBox.getText().trim(), passBox.getText(), rememberBox.getValue()); } } }
@Override public void onViewRevealed() { name.setFocus(true); }
@UiHandler("loginButton") public void submitAction(ClickEvent e) { doLogin(userBox.getText().trim(), passBox.getText(), rememberBox.getValue()); }