MenuSeparator.js 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. /*
  2. Copyright (c) 2004-2012, The Dojo Foundation All Rights Reserved.
  3. Available via Academic Free License >= 2.1 OR the modified BSD license.
  4. see: http://dojotoolkit.org/license for details
  5. */
  6. if(!dojo._hasResource["dijit.MenuSeparator"]){ //_hasResource checks added by build. Do not use _hasResource directly in your code.
  7. dojo._hasResource["dijit.MenuSeparator"] = true;
  8. dojo.provide("dijit.MenuSeparator");
  9. dojo.require("dijit._Widget");
  10. dojo.require("dijit._Templated");
  11. dojo.require("dijit._Contained");
  12. dojo.declare("dijit.MenuSeparator",
  13. [dijit._Widget, dijit._Templated, dijit._Contained],
  14. {
  15. // summary:
  16. // A line between two menu items
  17. templateString: dojo.cache("dijit", "templates/MenuSeparator.html", "<tr class=\"dijitMenuSeparator\">\n\t<td class=\"dijitMenuSeparatorIconCell\">\n\t\t<div class=\"dijitMenuSeparatorTop\"></div>\n\t\t<div class=\"dijitMenuSeparatorBottom\"></div>\n\t</td>\n\t<td colspan=\"3\" class=\"dijitMenuSeparatorLabelCell\">\n\t\t<div class=\"dijitMenuSeparatorTop dijitMenuSeparatorLabel\"></div>\n\t\t<div class=\"dijitMenuSeparatorBottom\"></div>\n\t</td>\n</tr>\n"),
  18. buildRendering: function(){
  19. this.inherited(arguments);
  20. dojo.setSelectable(this.domNode, false);
  21. },
  22. isFocusable: function(){
  23. // summary:
  24. // Override to always return false
  25. // tags:
  26. // protected
  27. return false; // Boolean
  28. }
  29. });
  30. }