@Test public void testSetupWidget() throws Exception { widget.setupWidget(); verify(widget).setText(GuidedDecisionTableConstants.INSTANCE.Delete()); verify(widget).setTitle(GuidedDecisionTableConstants.INSTANCE.DeleteThisColumn()); verify(widget).addClickHandler(clickCaptor.capture()); clickCaptor.getValue().onClick(null); verify(deletePopUpPresenter).setPrompt(GuidedDecisionTableConstants.INSTANCE.DeleteColumnWarning(COLUMN_HEADER)); verify(deletePopUpPresenter).setCommentIsHidden(true); verify(deletePopUpPresenter).show(commandCaptor.capture()); commandCaptor.getValue().execute(null); verify(deleteCommand).execute(); }
@PostConstruct public void setupWidget() { setText(GuidedDecisionTableConstants.INSTANCE.Delete()); setTitle(GuidedDecisionTableConstants.INSTANCE.DeleteThisColumn()); addClickHandler((clickEvent) -> { deletePopUpPresenter.setPrompt(GuidedDecisionTableConstants.INSTANCE.DeleteColumnWarning(columnHeader)); deletePopUpPresenter.setCommentIsHidden(true); deletePopUpPresenter.show((comment) -> afterDeleteConfirmedCommand.execute()); }); }
DeleteColumnManagementAnchorWidget extends Anchor { @PostConstruct public void setupWidget() { setText(GuidedDecisionTableConstants.INSTANCE.Delete()); setTitle(GuidedDecisionTableConstants.INSTANCE.DeleteThisColumn()); addClickHandler((clickEvent) -> { deletePopUpPresenter.setPrompt(GuidedDecisionTableConstants.INSTANCE.DeleteColumnWarning(columnHeader)); deletePopUpPresenter.setCommentIsHidden(true); deletePopUpPresenter.show((comment) -> afterDeleteConfirmedCommand.execute()); }); } }
DeleteColumnManagementAnchorWidget extends Anchor { @PostConstruct public void setupWidget() { setText(GuidedDecisionTableConstants.INSTANCE.Delete()); setTitle(GuidedDecisionTableConstants.INSTANCE.DeleteThisColumn()); addClickHandler((clickEvent) -> { deletePopUpPresenter.setPrompt(GuidedDecisionTableConstants.INSTANCE.DeleteColumnWarning(columnHeader)); deletePopUpPresenter.setCommentIsHidden(true); deletePopUpPresenter.show((comment) -> afterDeleteConfirmedCommand.execute()); }); } DeleteColumnManagementAnchorWidget(); @Inject  DeleteColumnManagementAnchorWidget(final DeletePopUpPresenter deletePopUpPresenter); }
DeleteColumnManagementAnchorWidget extends Anchor { @PostConstruct public void setupWidget() { setText(GuidedDecisionTableConstants.INSTANCE.Delete()); setTitle(GuidedDecisionTableConstants.INSTANCE.DeleteThisColumn()); addClickHandler((clickEvent) -> { deletePopUpPresenter.setPrompt(GuidedDecisionTableConstants.INSTANCE.DeleteColumnWarning(columnHeader)); deletePopUpPresenter.setCommentIsHidden(true); deletePopUpPresenter.show((comment) -> afterDeleteConfirmedCommand.execute()); }); } DeleteColumnManagementAnchorWidget(); @Inject  DeleteColumnManagementAnchorWidget(final DeletePopUpPresenter deletePopUpPresenter); @PostConstruct void setupWidget(); void init(final String columnHeader,
                     final Command afterDeleteConfirmedCommand); }
DeleteColumnManagementAnchorWidget extends Anchor { @PostConstruct public void setupWidget() { setText(GuidedDecisionTableConstants.INSTANCE.Delete()); setTitle(GuidedDecisionTableConstants.INSTANCE.DeleteThisColumn()); addClickHandler((clickEvent) -> { deletePopUpPresenter.setPrompt(GuidedDecisionTableConstants.INSTANCE.DeleteColumnWarning(columnHeader)); deletePopUpPresenter.setCommentIsHidden(true); deletePopUpPresenter.show((comment) -> afterDeleteConfirmedCommand.execute()); }); } DeleteColumnManagementAnchorWidget(); @Inject  DeleteColumnManagementAnchorWidget(final DeletePopUpPresenter deletePopUpPresenter); @PostConstruct void setupWidget(); void init(final String columnHeader,
                     final Command afterDeleteConfirmedCommand);  }