-
Notifications
You must be signed in to change notification settings - Fork 18
Messages
damylen edited this page Nov 19, 2014
·
18 revisions
csWeb has a simple publish/subscribe messaging bus, which is available as an Angular service. Besides providing functionality to publish a message to a topic, including optional title and data object, it also offers access to the (pnotify) publication service.
- project: is used to indicate when a project is loaded. (TODO implement unloaded event)
$messageBusService.publish('project', 'loaded');
- layer: is used to indicate when a feature is (de-)activated.
$messageBusService.publish('layer', 'activated|deactivating|deactivate');
- feature: is used to indicate when a feature is (de-)selected.
$messageBusService.publish('feature', 'onFeatureSelect|onFeatureDeselect');
- sidebar: is used to indicate whether the right sidebar needs to be shown or not.
$messageBusService.publish('sidebar', 'show|hide|toggle');
- FeatureTab: is used to indicate which FeatureProps tab is opened, e.g.
$messageBusService.publish('FeatureTab', 'activated', { sectionTitle: sectionTitle, section: section });
- timeline: is used to signal timeline events (currently only the timeline publishes these events)
this.$messageBusService.publish("timeline", "focusChange", this.focusDate);