Author: [EMAIL PROTECTED] Date: Wed Nov 12 12:35:32 2008 New Revision: 4028
Modified: branches/1_6_clean_events/user/src/com/google/gwt/user/client/ui/Widget.java Log: addDomHandler can't accept a null type or handler, so added param checks Modified: branches/1_6_clean_events/user/src/com/google/gwt/user/client/ui/Widget.java ============================================================================== --- branches/1_6_clean_events/user/src/com/google/gwt/user/client/ui/Widget.java (original) +++ branches/1_6_clean_events/user/src/com/google/gwt/user/client/ui/Widget.java Wed Nov 12 12:35:32 2008 @@ -145,9 +145,9 @@ */ protected final <H extends EventHandler> HandlerRegistration addDomHandler( final H handler, DomEvent.Type<H> type) { - if (type != null) { - sinkEvents(type.getEventToSink()); - } + assert handler != null : "handler must not be null"; + assert type != null : "type must not be null"; + sinkEvents(type.getEventToSink()); return ensureHandlers().addHandler(type, handler); } --~--~---------~--~----~------------~-------~--~----~ http://groups.google.com/group/Google-Web-Toolkit-Contributors -~----------~----~----~----~------~----~------~--~---