LGTM with mostly nits.

A general concern is inconsistency about naming -- most places, the
SafeHtml version is just an overload, and that makes the most sense to
me.  Some places rename the method to be setSafeHtml instead of setHtml,
for example, and I don't think that difference is relevant to the name
-- in either case, you are setting the HTML, you are just conveying it
to the method differently.


http://gwt-code-reviews.appspot.com/847801/diff/1/2
File tools/api-checker/config/gwt20_21userApi.conf (right):

http://gwt-code-reviews.appspot.com/847801/diff/1/2#newcode115
tools/api-checker/config/gwt20_21userApi.conf:115: # there needs to be:
method(SafeHtml html), etc.
Should probably add a statement that null is not acceptable to any of
these methods, so adding the overload is unlikely to break any code
besides possibly test mocks.

http://gwt-code-reviews.appspot.com/847801/diff/1/4
File user/src/com/google/gwt/user/client/ui/Anchor.java (right):

http://gwt-code-reviews.appspot.com/847801/diff/1/4#newcode166
user/src/com/google/gwt/user/client/ui/Anchor.java:166:
Spaces.

http://gwt-code-reviews.appspot.com/847801/diff/1/5
File user/src/com/google/gwt/user/client/ui/Button.java (right):

http://gwt-code-reviews.appspot.com/847801/diff/1/5#newcode92
user/src/com/google/gwt/user/client/ui/Button.java:92:
Spaces.

http://gwt-code-reviews.appspot.com/847801/diff/1/9
File user/src/com/google/gwt/user/client/ui/CustomButton.java (right):

http://gwt-code-reviews.appspot.com/847801/diff/1/9#newcode449
user/src/com/google/gwt/user/client/ui/CustomButton.java:449:
Spaces.

http://gwt-code-reviews.appspot.com/847801/diff/1/24
File user/src/com/google/gwt/user/client/ui/StackLayoutPanel.java
(right):

http://gwt-code-reviews.appspot.com/847801/diff/1/24#newcode436
user/src/com/google/gwt/user/client/ui/StackLayoutPanel.java:436: public
void setHeaderSafeHtml(int index, SafeHtml html) {
Why not just setHeaderHtml(int, SafeHtml)?  It is still just setting the
HTML, and the others all just overloaded the same method.

http://gwt-code-reviews.appspot.com/847801/diff/1/27
File user/src/com/google/gwt/user/client/ui/TabBar.java (right):

http://gwt-code-reviews.appspot.com/847801/diff/1/27#newcode544
user/src/com/google/gwt/user/client/ui/TabBar.java:544: public void
setTabSafeHtml(int index, SafeHtml html) {
Here also -- why not just overload setTabHTML?

http://gwt-code-reviews.appspot.com/847801/diff/1/28
File user/src/com/google/gwt/user/client/ui/TabLayoutPanel.java (right):

http://gwt-code-reviews.appspot.com/847801/diff/1/28#newcode482
user/src/com/google/gwt/user/client/ui/TabLayoutPanel.java:482: public
void setTabSafeHtml(int index, SafeHtml html) {
And here.

http://gwt-code-reviews.appspot.com/847801/diff/1/29
File user/src/com/google/gwt/user/client/ui/TreeItem.java (right):

http://gwt-code-reviews.appspot.com/847801/diff/1/29#newcode613
user/src/com/google/gwt/user/client/ui/TreeItem.java:613: public void
setSafeHtml(SafeHtml html) {
And here.

http://gwt-code-reviews.appspot.com/847801/show

--
http://groups.google.com/group/Google-Web-Toolkit-Contributors

Reply via email to