Skip to content

Instantly share code, notes, and snippets.

@jinmingjian
Last active April 8, 2018 02:09
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save jinmingjian/4358238 to your computer and use it in GitHub Desktop.
Save jinmingjian/4358238 to your computer and use it in GitHub Desktop.
eventBroker.subscribe(IThemeEngine.Events.THEME_CHANGED,
new EventHandler() {
public void handleEvent(Event event) {
ITheme currentTheme = (ITheme) event.getProperty(IThemeEngine.Events.THEME);
if (currentTheme.getId().equals(THEME_DARKER_ID)) {
setupPreferences();
} else {
setToDefaultPreferences();
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment