@Test public void enterKeySkipsNonPrimaryButton() { final Button button = new Button(); form.add(button); final DummyUiCommand ui = new DummyUiCommand(); b.bind(ui).to(button); final TextLine line1 = new TextLine(); form.add(line1); ((StubTextBox) line1.getTextBox()).press((char) KeyCodes.KEY_ENTER); assertThat(ui.executes, is(0)); }
public void add(final Button button) { button.setForm(this); buttons.add(button); if ("left".equals(button.getSide())) { view.leftActions().add(button); } else { view.rightActions().add(button); } }
Form extends CompositeHasIsWidgets { public void add(final Button button) { button.setForm(this); buttons.add(button); if ("left".equals(button.getSide())) { view.leftActions().add(button); } else { view.rightActions().add(button); } } }
Form extends CompositeHasIsWidgets { public void add(final Button button) { button.setForm(this); buttons.add(button); if ("left".equals(button.getSide())) { view.leftActions().add(button); } else { view.rightActions().add(button); } } Form(); }
Form extends CompositeHasIsWidgets { public void add(final Button button) { button.setForm(this); buttons.add(button); if ("left".equals(button.getSide())) { view.leftActions().add(button); } else { view.rightActions().add(button); } } Form(); void setTitle(final String title); void setAutoFocus(final boolean autoFocus); void add(final Button button); void add(final AbstractLine line); void watch(final Property<?> property); void watch(final Model model); void watch(final UiCommand command); Property<Boolean> valid(); BooleanProperty loading(); Property<Boolean> active(); @VisibleForTesting IsFormView getView(); }
Form extends CompositeHasIsWidgets { public void add(final Button button) { button.setForm(this); buttons.add(button); if ("left".equals(button.getSide())) { view.leftActions().add(button); } else { view.rightActions().add(button); } } Form(); void setTitle(final String title); void setAutoFocus(final boolean autoFocus); void add(final Button button); void add(final AbstractLine line); void watch(final Property<?> property); void watch(final Model model); void watch(final UiCommand command); Property<Boolean> valid(); BooleanProperty loading(); Property<Boolean> active(); @VisibleForTesting IsFormView getView();  }