<!-- saved from url=(0026)http://www.naturaldocs.org -->
<divid=Content><divclass="CClass"><divclass=CTopicid=MainTopic><h1class=CTitle><aname="mxDefaultPopupMenuCodec"></a>mxDefaultPopupMenuCodec</h1><divclass=CBody><p>Custom codec for configuring <ahref="../editor/mxDefaultPopupMenu-js.html#mxDefaultPopupMenu"class=LClassid=link5onMouseOver="ShowTip(event, 'tt1', 'link5')"onMouseOut="HideTip('tt1')">mxDefaultPopupMenu</a>s. This class is created and registered dynamically at load time and used implicitely via <ahref="mxCodec-js.html#mxCodec"class=LClassid=link6onMouseOver="ShowTip(event, 'tt4', 'link6')"onMouseOut="HideTip('tt4')">mxCodec</a> and the <ahref="mxCodecRegistry-js.html#mxCodecRegistry"class=LClassid=link7onMouseOver="ShowTip(event, 'tt5', 'link7')"onMouseOut="HideTip('tt5')">mxCodecRegistry</a>. This codec only reads configuration data for existing popup menus, it does not encode or create menus. Note that this codec only passes the configuration node to the popup menu, which uses the config to dynamically create menus. See <ahref="../editor/mxDefaultPopupMenu-js.html#mxDefaultPopupMenu.createMenu"class=LFunctionid=link8onMouseOver="ShowTip(event, 'tt6', 'link8')"onMouseOut="HideTip('tt6')">mxDefaultPopupMenu.createMenu</a>.</p><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SMain"><tdclass=SEntry><ahref="#mxDefaultPopupMenuCodec">mxDefaultPopupMenuCodec</a></td><tdclass=SDescription>Custom codec for configuring <ahref="../editor/mxDefaultPopupMenu-js.html#mxDefaultPopupMenu"class=LClassid=link1onMouseOver="ShowTip(event, 'tt1', 'link1')"onMouseOut="HideTip('tt1')">mxDefaultPopupMenu</a>s. </td></tr><trclass="SGroup SIndent1"><tdclass=SEntry><ahref="#mxDefaultPopupMenuCodec.Functions">Functions</a></td><tdclass=SDescription></td></tr><trclass="SFunction SIndent2 SMarked"><tdclass=SEntry><ahref="#mxDefaultPopupMenuCodec.encode"id=link2onMouseOver="ShowTip(event, 'tt2', 'link2')"onMouseOut="HideTip('tt2')">encode</a></td><tdclass=SDescription>Returns null.</td></tr><trclass="SFunction SIndent2"><tdclass=SEntry><ahref="#mxDefaultPopupMenuCodec.decode"id=link3onMouseOver="ShowTip(event, 'tt3', 'link3')"onMouseOut="HideTip('tt3')">decode</a></td><tdclass=SDescription>Uses the given node as the config for <ahref="../editor/mxDefaultPopupMenu-js.html#mxDefaultPopupMenu"class=LClassid=link4onMouseOver="ShowTip(event, 'tt1', 'link4')"onMouseOut="HideTip('tt1')">mxDefaultPopupMenu</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxDefaultPopupMenuCodec.decode"></a>decode</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass=PBeforeParametersnowrap>codec.decode = function(</td><tdclass=PParameternowrap>dec,</td></tr><tr><td></td><tdclass=PParameternowrap>node,</td></tr><tr><td></td><tdclass=PParameternowrap>into</td><tdclass=PAfterParametersnowrap>)</td></tr></table></td></tr></table></blockquote><p>Uses the given node as the config for <ahref="../editor/mxDefaultPopupMenu-js.html#mxDefaultPopupMenu"class=LClassid=link9onMouseOver="ShowTip(event, 'tt1', 'link9')"onMouseOut="HideTip('tt1')">mxDefaultPopupMenu</a>.</p></div></div></div>
</div><!--Content-->
<divid=Footer><ahref="http://www.naturaldocs.org">Generated by Natural Docs</a></div><!--Footer-->
<divclass=CToolTipid="tt1"><divclass=CClass>Creates popupmenus for mouse events. </div></div><divclass=CToolTipid="tt2"><divclass=CFunction><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass=PBeforeParametersnowrap>codec.encode = function(</td><tdclass=PParameternowrap>enc,</td></tr><tr><td></td><tdclass=PParameternowrap>obj</td><tdclass=PAfterParametersnowrap>)</td></tr></table></td></tr></table></blockquote>Returns null.</div></div><divclass=CToolTipid="tt3"><divclass=CFunction><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass=PBeforeParametersnowrap>codec.decode = function(</td><tdclass=PParameternowrap>dec,</td></tr><tr><td></td><tdclass=PParameternowrap>node,</td></tr><tr><td></td><tdclass=PParameternowrap>into</td><tdclass=PAfterParametersnowrap>)</td></tr></table></td></tr></table></blockquote>Uses the given node as the config for mxDefaultPopupMenu.</div></div><divclass=CToolTipid="tt4"><divclass=CClass>XML codec for JavaScript object graphs. </div></div><divclass=CToolTipid="tt5"><divclass=CClass>Singleton class that acts as a global registry for codecs.</div></div><divclass=CToolTipid="tt6"><divclass=CFunction><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass=PBeforeParametersnowrap>mxDefaultPopupMenu.prototype.createMenu = function(</td><tdclass=PParameternowrap>editor,</td></tr><tr><td></td><tdclass=PParameternowrap>menu,</td></tr><tr><td></td><tdclass=PParameternowrap>cell,</td></tr><tr><td></td><tdclass=PParameternowrap>evt</td><tdclass=PAfterParametersnowrap>)</td></tr></table></td></tr></table></blockquote>This function is called from mxEditor to add items to the given menu based on config. </div></div><!--END_ND_TOOLTIPS-->