Vojtech Szocs has posted comments on this change.

Change subject: webadmin: Host interface manual refresh
......................................................................


Patch Set 2:

(1 comment)

....................................................
File 
frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/section/main/presenter/tab/host/SubTabHostInterfacePresenter.java
Line 62:     }
Line 63: 
Line 64:     @ProxyEvent
Line 65:     @Override
Line 66:     public void onManualRefresh(ManualRefreshEvent event) {
> Won't the other @ProxyEvent already have the same effect?

Yes, after the Presenter has been instantiated & bound (either due to GWTP 
reveal mechanism or due to previous @ProxyEvent method being handled), 
subsequent handlers implemented via @ProxyEvent will have same effect as 
compared to onBind approach.

However, the conceptual difference here is @ProxyEvent registers handler 
directly on Presenter's Proxy (and can therefore trigger instantiate & bind of 
Presenter), whereas handler registered via onBind gets executed only after 
someone triggers Presenter instantiate & bind lifecycle.

Simply put, in most cases, handler logic makes sense only when the presenter is 
already loaded, such as onManualRefresh, so we can just use onBind approach 
here.
Line 67:         getView().removeContent();
Line 68:     }


-- 
To view, visit http://gerrit.ovirt.org/19143
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I3e38c077a6eeef335fe1f8e8f468c70a5ca8ad92
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Alexander Wels <[email protected]>
Gerrit-Reviewer: Alexander Wels <[email protected]>
Gerrit-Reviewer: Einav Cohen <[email protected]>
Gerrit-Reviewer: Greg Sheremeta <[email protected]>
Gerrit-Reviewer: Vojtech Szocs <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to