Sync Panel Element

Home | Getting Started | API | Elements | Actions | Validators | Handlers | Configuration Options | Advanced Guides | Troubleshooting | About

Table of Contents

1 Sync Panel Element - #sync_panel {}

The sync_panel element produces an HTML div which is hooked directly into a comet pool and immediately updates itself with the latest data when certain trigger messages are sent to that comet pool.

Usage

#sync_panel {
  pool=some_pool,
  triggers=[{my, trigger}],
  body_fun=fun my_body/0
}.

Attributes

pool - (Erlang Term)
The name of a global Nitrogen comet pool.
triggers - (List of Erlang Terms)
A list containing trigger messages which when broadcast to the comet pool will trigger an update and redraw via the body_fun attribute.
bodyfun - (Function with arity 0)
A function which returns Nitrogen elements.

Assisting Function

element_sync_panel:refresh(CometPool, Trigger)
Trigger a refresh on all #sync_panel elements connected to the specified CometPool and which also has the specified Trigger listed in its triggers attribute.

Date: 2014-11-12 19:50:48 CST

Author: Jesse Gumm (@jessegumm)

Org version 7.8.02 with Emacs version 23

Validate XHTML 1.0

Comments

Note:To specify code blocks, just use the generic code block syntax:
<pre><code>your code here</code></pre>


comments powered by Disqus