use of com.google.gwt.place.shared.PlaceHistoryHandler in project openremote by openremote.
the class ManagerModule method getHistoryHandler.
@Provides
@Singleton
public PlaceHistoryHandler getHistoryHandler(PlaceController placeController, PlaceHistoryMapper historyMapper, com.google.web.bindery.event.shared.EventBus legacyEventBus) {
PlaceHistoryHandler historyHandler = new PlaceHistoryHandler(historyMapper);
// TODO See AppPlaceController for default start page
historyHandler.register(placeController, legacyEventBus, Place.NOWHERE);
return historyHandler;
}
use of com.google.gwt.place.shared.PlaceHistoryHandler in project activityinfo by bedatadriven.
the class AppEntryPoint method onModuleLoad.
@Override
public void onModuleLoad() {
LOGGER.info("user.agent = " + System.getProperty("user.agent"));
LOGGER.info("gxt.user.agent = " + System.getProperty("gxt.user.agent"));
LOGGER.info("gxt.device = " + System.getProperty("gxt.device"));
Icons.INSTANCE.ensureInjected();
AppCache appCache = new AppCache();
AppCacheMonitor3 monitor = new AppCacheMonitor3(appCache);
monitor.start();
EventBus eventBus = new SimpleEventBus();
PlaceController placeController = new PlaceController(eventBus);
ConnectionListener connectionListener = new ConnectionListener();
connectionListener.start();
ActivityInfoClientAsync client = new ActivityInfoClientAsyncImpl(findServerUrl());
HttpStore httpStore = new HttpStore(connectionListener.getOnline(), client, Scheduler.get());
OfflineStore offlineStore = new OfflineStore(httpStore, IDBFactoryImpl.create());
FormStore formStore = new FormStoreImpl(httpStore, offlineStore, Scheduler.get());
LocalStorage storage = LocalStorage.create();
Viewport viewport = new Viewport();
AppFrame appFrame = new AppFrame(appCache, httpStore, offlineStore);
ActivityMapper activityMapper = new AppActivityMapper(formStore, storage);
ActivityManager activityManager = new ActivityManager(activityMapper, eventBus);
activityManager.setDisplay(appFrame.getDisplayWidget());
AppPlaceHistoryMapper historyMapper = new AppPlaceHistoryMapper();
PlaceHistoryHandler historyHandler = new PlaceHistoryHandler(historyMapper);
historyHandler.register(placeController, eventBus, DEFAULT_PLACE);
// Start synchronizer...
RecordSynchronizer synchronizer = new RecordSynchronizer(httpStore, offlineStore);
viewport.add(appFrame);
RootLayoutPanel.get().add(viewport);
historyHandler.handleCurrentHistory();
}
use of com.google.gwt.place.shared.PlaceHistoryHandler in project webprotege by protegeproject.
the class WebProtege method buildUI.
private void buildUI() {
BUNDLE.laf().ensureInjected();
BUNDLE.toolbar().ensureInjected();
BUNDLE.login().ensureInjected();
BUNDLE.style().ensureInjected();
BUNDLE.buttons().ensureInjected();
BUNDLE.discussion().ensureInjected();
BUNDLE.menu().ensureInjected();
BUNDLE.settings().ensureInjected();
BUNDLE.valueList().ensureInjected();
BUNDLE.tags().ensureInjected();
WidgetMapClientBundle.BUNDLE.style().ensureInjected();
ApplicationPresenter applicationPresenter = WebProtegeClientInjector.get().getApplicationPresenter();
applicationPresenter.start();
ApplicationView applicationView = applicationPresenter.getApplicationView();
RootLayoutPanel.get().add(applicationView);
WebProtegeActivityManager activityManager = WebProtegeClientInjector.get().getActivityManager();
activityManager.setDisplay(applicationView);
PlaceHistoryHandler placeHistoryHandler = WebProtegeClientInjector.get().getPlaceHistoryHandler();
placeHistoryHandler.handleCurrentHistory();
}
use of com.google.gwt.place.shared.PlaceHistoryHandler in project webprotege by protegeproject.
the class PlaceHistoryHandlerProvider method get.
@Override
public PlaceHistoryHandler get() {
PlaceHistoryHandler handler = new PlaceHistoryHandler(placeHistoryMapper, new PlaceHistoryHandler.DefaultHistorian() {
@Override
public String getToken() {
GWT.log("[Historian] Token: " + super.getToken());
return super.getToken();
}
});
handler.register(placeController, eventBus, defaultPlace);
return handler;
}
Aggregations