Vojtech Szocs has posted comments on this change.

Change subject: webadmin: 'remove' confirmation dialog message cleanup
......................................................................


Patch Set 1:

(2 comments)

....................................................
File 
frontend/webadmin/modules/gwt-common/src/main/java/org/ovirt/engine/ui/common/view/popup/AbstractConfirmationPopupView.java
Line 11: public abstract class AbstractConfirmationPopupView extends 
AbstractModelBoundPopupView<ConfirmationModel> {
Line 12: 
Line 13:     @UiField
Line 14:     @Ignore
Line 15:     public HTML messageHTML = new HTML();
Daniel is right, messageHTML is @UiField and therefore managed by GWT UiBinder 
framework; UiBinder will initialize this field only after executing something 
like:

 initWidget(ViewUiBinder.uiBinder.createAndBindUi(this));

Note: if messageHTML was declared as @UiField(provided=true), the application 
code would be responsible for initializing messageHTML widget before calling 
UiBinder's createAndBindUi method.
Line 16: 
Line 17:     public AbstractConfirmationPopupView(EventBus eventBus, 
CommonApplicationResources resources) {
Line 18:         super(eventBus, resources);
Line 19:     }


....................................................
File 
frontend/webadmin/modules/gwt-common/src/main/java/org/ovirt/engine/ui/common/view/popup/RemoveConfirmationPopupView.java
Line 75:         force = new EntityModelCheckBoxEditor(Align.RIGHT);
Line 76:         force.setLabel(constants.forceRemove());
Line 77:         this.constants= constants;
Line 78:         this.messages = messages;
Line 79:         setMessageToDefault();
I agree with Daniel, I'd prefer updating the message widget 
(AbstractConfirmationPopupView.messageHTML) right upon setMessage execution.

As Daniel mentioned, setMessage will always be called, first time as part of 
dialog init, and then whenever dialog model's message property changes (which 
triggers "Message" property change event that delegates to setMessage call).
Line 80:         initWidget(ViewUiBinder.uiBinder.createAndBindUi(this));
Line 81:         ViewIdHandler.idHandler.generateAndSetIds(this);
Line 82:         localize(constants);
Line 83:         driver.initialize(this);


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I7411dec0eaf8d60cefff563988618f7c548eecce
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Greg Sheremeta <[email protected]>
Gerrit-Reviewer: Alexander Wels <[email protected]>
Gerrit-Reviewer: Daniel Erez <[email protected]>
Gerrit-Reviewer: Einav Cohen <[email protected]>
Gerrit-Reviewer: Gilad Chaplik <[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