Skip to content

Instantly share code, notes, and snippets.

@christiangoudreau
Created November 15, 2011 00:57
Show Gist options
  • Save christiangoudreau/1365756 to your computer and use it in GitHub Desktop.
Save christiangoudreau/1365756 to your computer and use it in GitHub Desktop.
ApplicationView
@Inject
public AppView(final Binder uiBinder, final EventBus eventBus, final ContentActivityMapper contentActivityMapper) {
initWidget(uiBinder.createAndBindUi(this));
ActivityManager contentActivityManager = new ActivityManager(contentActivityMapper, eventBus);
contentActivityManager.setDisplay(content);
}
@Provides
@Singleton
public PlaceController getPlaceController(EventBus eventBus) {
return new PlaceController(eventBus);
}
@Provides
@Singleton
public PlaceHistoryHandler getAdminHistoryHandler(PlaceController placeController,
PlaceHistoryMapper historyMapper,
EventBus eventBus) {
PlaceHistoryHandler historyHandler = new PlaceHistoryHandler(historyMapper);
historyHandler.register(placeController, eventBus, new WelcomePlace());
return historyHandler;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment