@@ -33,6 +33,7 @@ In this section, we'll learn how to add logic to our UI. We'll touch on very bas
33
33
@UiField PaperDrawerPanelElement drawerPanel;
34
34
@UiField HTMLElement content;
35
35
36
+ @UiField PaperFabElement addButton;
36
37
@UiField PaperDialogElement addItemDialog;
37
38
@UiField PaperInputElement titleInput;
38
39
@UiField PaperTextareaElement descriptionInput;
@@ -327,7 +328,50 @@ In this section, we'll learn how to add logic to our UI. We'll touch on very bas
327
328
}
328
329
}
329
330
330
- 11 . Reload the application
331
+ 11 . Your ` TodoList.java ` should look like this:
332
+
333
+ package org.gwtproject.tutorial.client;
334
+
335
+ import com.google.gwt.core.client.EntryPoint;
336
+ import com.google.gwt.user.client.ui.RootPanel;
337
+ import com.vaadin.polymer.Polymer;
338
+ import com.vaadin.polymer.elemental.Function;
339
+ import com.vaadin.polymer.iron.element.IronIconElement;
340
+ import com.vaadin.polymer.paper.element.*;
341
+
342
+ import java.util.Arrays;
343
+
344
+ public class TodoList implements EntryPoint {
345
+
346
+ public void onModuleLoad() {
347
+ Polymer.importHref(Arrays.asList(
348
+ "iron-icons/iron-icons.html",
349
+ PaperIconItemElement.SRC,
350
+ PaperRippleElement.SRC,
351
+ IronIconElement.SRC,
352
+ PaperDrawerPanelElement.SRC,
353
+ PaperHeaderPanelElement.SRC,
354
+ PaperToolbarElement.SRC,
355
+ PaperFabElement.SRC,
356
+ PaperDialogElement.SRC,
357
+ PaperTextareaElement.SRC,
358
+ PaperInputElement.SRC,
359
+ PaperButtonElement.SRC,
360
+ PaperCheckboxElement.SRC
361
+ ), new Function() {
362
+ public Object call(Object arg) {
363
+ startApplication();
364
+ return null;
365
+ }
366
+ });
367
+
368
+ }
369
+
370
+ private void startApplication() {
371
+ RootPanel.get().add(new Main());
372
+ }
373
+
374
+ 12 . Reload the application
331
375
332
376
* Add several items
333
377
* Mark some of them as done
0 commit comments