Some further refactoring in form classes.
[timetracker.git] / WEB-INF / lib / form / Combobox.class.php
index 1908194..ce66739 100644 (file)
@@ -44,7 +44,7 @@ class Combobox extends FormElement {
     var $mCompareOn = "key"; // or "value"
     var $mDataDeep = 1;
     var $mDataKeys = array();
-    var $cClassName    = "Combobox";
+    var $class = 'Combobox';
 
        function __construct($name,$value="")
        {
@@ -65,9 +65,8 @@ class Combobox extends FormElement {
        function getDataKeys() { return $this->mDataKeys; }
        
        
-       function toStringControl()      {
-               if (!$this->isRenderable()) return "";
-           
+       function getHtml() {
+
            if ($this->id=="") $this->id = $this->name;
            
                $html = "\n\t<select";
@@ -85,7 +84,7 @@ class Combobox extends FormElement {
                if ($this->style!="")
                   $html .= " style=\"$this->style\"";
                 
-                if (!$this->isEnable())
+                if (!$this->isEnabled())
                   $html .= " disabled";
                   
                $html .= ">\n";