/** * Fires a {@link ResetPresentersEvent} * into a source that has access to an {@link com.google.web.bindery.event.shared.EventBus}. * * @param source The source that fires this event ({@link HasHandlers}). */ public static void fire(final HasHandlers source) { source.fireEvent(new ResetPresentersEvent()); }
@Override public Type<ResetPresentersHandler> getAssociatedType() { return getType(); }
@Override public void manualReveal(Presenter<?, ?> presenter) { // Reveal only if there are no pending navigation requests if (!placeManager.hasPendingNavigation()) { if (!presenter.isVisible()) { // This will trigger a reset in due time presenter.forceReveal(); } else { // We have to do the reset ourselves ResetPresentersEvent.fire(this); } } placeManager.unlock(); }
/** * This method sets some content in a specific slot of the {@link Presenter}. The attached {@link View} should * manage this slot when its {@link View#setInSlot(Object, IsWidget)} is called. It should also clear the slot when * called with {@code null} as a parameter. * <p/> * For more details on slots, see {@link HasSlots}. * * @param slot The slot for which the content is being set. * @param child The content, a {@link PresenterWidget}. Passing {@code null} will clear the slot. * @param performReset Pass {@code true} if you want a {@link ResetPresentersEvent} to be fired after the content * has been added and this presenter is visible, pass {@code false} otherwise. */ @Override public <T extends PresenterWidget<?>> void setInSlot(IsSlot<T> slot, T child, boolean performReset) { if (child == null) { clearSlot((RemovableSlot<?>) slot); return; } adoptChild(slot, child); internalClearSlot(slot, child); if (!child.isPopup()) { getView().setInSlot(slot.getRawSlot(), child); } if (isVisible()) { child.internalReveal(); if (performReset) { ResetPresentersEvent.fire(this); } } }
@Override public void onSuccess(Void dummy) { getEventBus().fireEvent(new ResetPresentersEvent()); }
@Override protected void onBind() { super.onBind(); addRegisteredHandler(ResetPresentersEvent.getType(), this); addRegisteredHandler(RevealRootContentEvent.getType(), this); addRegisteredHandler(RevealRootLayoutContentEvent.getType(), this); addRegisteredHandler(RevealRootPopupContentEvent.getType(), this); addRegisteredHandler(LockInteractionEvent.getType(), this); } }
@Override public void onSuccess(Void unused) { getEventBus().fireEvent(new ResetPresentersEvent()); }
@Override public void onSuccess(Void dummy) { getEventBus().fireEvent(new ResetPresentersEvent()); }
@Override public void onSuccess(Void dummy) { getEventBus().fireEvent(new ResetPresentersEvent()); }
@Override public void onSuccess(Void dummy) { getEventBus().fireEvent(new ResetPresentersEvent()); }
@Override public void onSuccess(Void dummy) { getEventBus().fireEvent(new ResetPresentersEvent()); }
@Override public void onSuccess(Void unused) { getEventBus().fireEvent(new ResetPresentersEvent()); }