Roo/menu/TextItem.js
authorAlan Knowles <alan@akbkhome.com>
Thu, 29 Jul 2010 09:45:16 +0000 (17:45 +0800)
committerAlan Knowles <alan@akbkhome.com>
Thu, 29 Jul 2010 09:45:16 +0000 (17:45 +0800)
Roo/menu/TextItem.js

index 7985228..5ab2d18 100644 (file)
  * Creates a new TextItem
  * @param {Object} cfg Configuration
  */
-Roo.menu.TextItem = function(text){
-    if (typeof(text) == 'string') {
-        this.text = text;
+Roo.menu.TextItem = function(cfg){
+    if (typeof(cfg) == 'string') {
+        this.text = cfg;
     } else {
-        Roo.apply(this,text);
+        Roo.apply(this,cfg);
     }
     
     Roo.menu.TextItem.superclass.constructor.call(this);