Tomas Jelinek has posted comments on this change. Change subject: userportal,webadmin: type ahead list box ......................................................................
Patch Set 9: (1 inline comment) .................................................... File frontend/webadmin/modules/gwt-common/src/main/java/org/ovirt/engine/ui/common/widget/editor/BaseListModelSuggestBox.java Line 137: public HandlerRegistration addValueChangeHandler(final ValueChangeHandler<T> handler) { Line 138: return asSuggestBox().addValueChangeHandler(new ValueChangeHandler<String>() { Line 139: @Override Line 140: public void onValueChange(ValueChangeEvent<String> event) { Line 141: T value = wrap(event.getValue()); The difference is just how you wrap the String to entity and how you render that entity (even for suggest box the entity is just a String). So this are abstract and the rest is generic in the parent. I like it more than to implement two setValue, one getValue and the addValueChangeHandler if it can be generalized. But no big difference between our approaches - just where to put the line for "this is generic" and "this is specific". Line 142: if (value != null) { Line 143: handler.onValueChange(new ValueChangeEvent<T>(wrap(event.getValue())) { Line 144: }); Line 145: } -- To view, visit http://gerrit.ovirt.org/14936 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I956af3c675894c850a1a104a81cec49f4bd62011 Gerrit-PatchSet: 9 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Tomas Jelinek <tjeli...@redhat.com> Gerrit-Reviewer: Daniel Erez <de...@redhat.com> Gerrit-Reviewer: Einav Cohen <eco...@redhat.com> Gerrit-Reviewer: Frank Kobzik <fkob...@redhat.com> Gerrit-Reviewer: Gilad Chaplik <gchap...@redhat.com> Gerrit-Reviewer: Lior Vernia <lver...@redhat.com> Gerrit-Reviewer: Michal Skrivanek <michal.skriva...@redhat.com> Gerrit-Reviewer: Tomas Jelinek <tjeli...@redhat.com> Gerrit-Reviewer: Vojtech Szocs <vsz...@redhat.com> Gerrit-Reviewer: oVirt Jenkins CI Server _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches