@Test public void shouldCallCallbackOnCanceled() throws Exception { presenter.cancelled(); verify(view).closeDialog(); verify(cancelCallback).cancelled(); }
@Override public void cancelled() { this.view.closeDialog(); if (this.cancelCallback != null) { this.cancelCallback.cancelled(); } }
ConfirmDialogPresenter implements ConfirmDialog, ConfirmDialogView.ActionDelegate { @Override public void cancelled() { this.view.closeDialog(); if (this.cancelCallback != null) { this.cancelCallback.cancelled(); } } }
ConfirmDialogPresenter implements ConfirmDialog, ConfirmDialogView.ActionDelegate { @Override public void cancelled() { this.view.closeDialog(); if (this.cancelCallback != null) { this.cancelCallback.cancelled(); } } @AssistedInject  ConfirmDialogPresenter(final @Nonnull ConfirmDialogView view,
                                  final @Nonnull @Assisted("title") String title,
                                  final @Nonnull @Assisted("message") String message,
                                  final @Nullable @Assisted ConfirmCallback confirmCallback,
                                  final @Nullable @Assisted CancelCallback cancelCallback); @AssistedInject  ConfirmDialogPresenter(final @Nonnull ConfirmDialogView view,
                                  final @Nonnull @Assisted String title,
                                  final @Nonnull @Assisted IsWidget content,
                                  final @Nullable @Assisted ConfirmCallback confirmCallback,
                                  final @Nullable @Assisted CancelCallback cancelCallback); }
ConfirmDialogPresenter implements ConfirmDialog, ConfirmDialogView.ActionDelegate { @Override public void cancelled() { this.view.closeDialog(); if (this.cancelCallback != null) { this.cancelCallback.cancelled(); } } @AssistedInject  ConfirmDialogPresenter(final @Nonnull ConfirmDialogView view,
                                  final @Nonnull @Assisted("title") String title,
                                  final @Nonnull @Assisted("message") String message,
                                  final @Nullable @Assisted ConfirmCallback confirmCallback,
                                  final @Nullable @Assisted CancelCallback cancelCallback); @AssistedInject  ConfirmDialogPresenter(final @Nonnull ConfirmDialogView view,
                                  final @Nonnull @Assisted String title,
                                  final @Nonnull @Assisted IsWidget content,
                                  final @Nullable @Assisted ConfirmCallback confirmCallback,
                                  final @Nullable @Assisted CancelCallback cancelCallback); @Override void cancelled(); @Override void accepted(); @Override void show(); }
ConfirmDialogPresenter implements ConfirmDialog, ConfirmDialogView.ActionDelegate { @Override public void cancelled() { this.view.closeDialog(); if (this.cancelCallback != null) { this.cancelCallback.cancelled(); } } @AssistedInject  ConfirmDialogPresenter(final @Nonnull ConfirmDialogView view,
                                  final @Nonnull @Assisted("title") String title,
                                  final @Nonnull @Assisted("message") String message,
                                  final @Nullable @Assisted ConfirmCallback confirmCallback,
                                  final @Nullable @Assisted CancelCallback cancelCallback); @AssistedInject  ConfirmDialogPresenter(final @Nonnull ConfirmDialogView view,
                                  final @Nonnull @Assisted String title,
                                  final @Nonnull @Assisted IsWidget content,
                                  final @Nullable @Assisted ConfirmCallback confirmCallback,
                                  final @Nullable @Assisted CancelCallback cancelCallback); @Override void cancelled(); @Override void accepted(); @Override void show();  }