Dojo中右键弹出式菜单

 <div dojoType="dijit.Menu" jsId="rightClick" style="display: none;">
  <script type="dojo/method">
   this.bindDomNode(csvGrid.domNode);//将改菜单绑定到某个节点。
  </script>
  <div dojoType="dijit.MenuItem" onClick="alert('Hello world');">Enabled Item</div>
  <div dojoType="dijit.MenuItem" disabled="true">Disabled Item</div>
  <div dojoType="dijit.MenuSeparator"></div>
  <div dojoType="dijit.PopupMenuItem">
   <span>Enabled Submenu</span>
   <div dojoType="dijit.Menu" id="submenu2">
    <div dojoType="dijit.MenuItem" onClick="alert('Submenu 1!')">Submenu Item One</div>
    <div dojoType="dijit.MenuItem" onClick="alert('Submenu 2!')">Submenu Item Two</div>
    <div dojoType="dijit.PopupMenuItem">
     <span>Deeper Submenu</span>
     <div dojoType="dijit.Menu" id="submenu4">
      <div dojoType="dijit.MenuItem" onClick="alert('Sub-submenu 1!')">Sub-sub-menu Item One</div>
      <div dojoType="dijit.MenuItem" onClick="alert('Sub-submenu 2!')">Sub-sub-menu Item Two</div>
     </div>
    </div>
   </div>
  </div>
  <div dojoType="dijit.PopupMenuItem" disabled="true">
   <span>Disabled Submenu</span>
   <div dojoType="dijit.Menu" id="submenu3" style="display: none;">
    <div dojoType="dijit.MenuItem" onClick="alert('Submenu 1!')">Submenu Item One</div>
    <div dojoType="dijit.MenuItem" onClick="alert('Submenu 2!')">Submenu Item Two</div>
   </div>
  </div>
  <div dojoType="dijit.CheckedMenuItem" checked="true" onChange="alert('Now set to ' + arguments[0])">Checked</div>
  <div dojoType="dijit.CheckedMenuItem">Not Checked</div>
  <div dojoType="dijit.CheckedMenuItem" checked="true" disabled="true">Checked Disabled</div>
 </div>

你可能感兴趣的:(职场,dojo,休闲,右键弹出式菜单)