File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
src/main/java/gwt/material/design/incubator/client/google/addresslookup Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 1919 */
2020package gwt .material .design .incubator .client .google .addresslookup ;
2121
22+ import com .google .gwt .core .client .Scheduler ;
2223import com .google .gwt .event .shared .HandlerRegistration ;
2324import gwt .material .design .client .constants .Autocomplete ;
2425import gwt .material .design .client .ui .MaterialTextBox ;
@@ -83,6 +84,7 @@ public class AddressLookup extends MaterialTextBox
8384 public AddressLookup () {
8485 setPlaceholder ("" );
8586 setAutocomplete (Autocomplete .OFF );
87+ addStyleName ("address-lookup" );
8688 }
8789
8890 /**
@@ -102,8 +104,10 @@ protected void onLoad() {
102104 }
103105
104106 public void load () {
105- addressLookup = new JsAddressLookup (valueBoxBase .getElement (), options );
106- addressLookup .addListener (AddressLookupEvents .PLACE_CHANGED , () -> PlaceChangedEvent .fire (AddressLookup .this ));
107+ Scheduler .get ().scheduleDeferred (() -> {
108+ addressLookup = new JsAddressLookup (valueBoxBase .getElement (), options );
109+ addressLookup .addListener (AddressLookupEvents .PLACE_CHANGED , () -> PlaceChangedEvent .fire (AddressLookup .this ));
110+ });
107111 }
108112
109113 /**
You can’t perform that action at this time.
0 commit comments