773
edits
| m (→Dojo Undo) | |||
| Line 44: | Line 44: | ||
| * ability to transform XML fragments in XML or XHTML fragments and attach to the docuemnt. This would be good if we want to keep some very lightweight encoded markup, then to transform in the dojo markup XHTML Div approach + classnames. | * ability to transform XML fragments in XML or XHTML fragments and attach to the docuemnt. This would be good if we want to keep some very lightweight encoded markup, then to transform in the dojo markup XHTML Div approach + classnames. | ||
| ==== Dojo Events - Publish and Subscribe approach ==== | |||
| {{{ | |||
| var foo = new function() { | |||
|     this.init = function() { | |||
|         dojo.event.topic.subscribe("/mytopic", this, processMessages); | |||
|     } | |||
|     function processMessages(message) { | |||
|         alert("Message: " + message.content); | |||
|    } | |||
| } | |||
| var bar = new function() { | |||
|     this.showMessage = function(message) { | |||
|         dojo.event.topic.publish("/mytopic", {content: message}); | |||
|     } | |||
| } | |||
| foo.init(); | |||
| bar.showMessage("Hello Dojo Master"); | |||
| }}} | |||
| === Considerations for the Joey Web Client === | === Considerations for the Joey Web Client === | ||
edits