@Override public void start(AcceptsOneWidget panel, EventBus eventBus) { view = clientFactory.getSeattleExpressLanesView(); this.eventBus = eventBus; this.phoneGap = this.clientFactory.getPhoneGap(); accessibility = clientFactory.getAccessibility(); view.setPresenter(this); view.getPullHeader().setHTML("pull down"); inAppBrowser = this.phoneGap.getInAppBrowser(); PullArrowStandardHandler headerHandler = new PullArrowStandardHandler(view.getPullHeader(), view.getPullPanel()); headerHandler.setErrorText("Error"); headerHandler.setLoadingText("Loading"); headerHandler.setNormalText("pull down"); headerHandler.setPulledText("release to load"); headerHandler.setPullActionHandler( new PullActionHandler() { @Override public void onPullAction(final AsyncCallback<Void> callback) { new Timer() { @Override public void run() { createPostList(); view.refresh(); callback.onSuccess(null); } }.schedule(1); } }); view.setHeaderPullHandler(headerHandler); createPostList(); createSchedulesLink(); panel.setWidget(view); accessibility.postScreenChangeNotification(); }
@Override public void onStop() { view.setPresenter(null); }