summaryrefslogtreecommitdiff
path: root/framework/Web/UI
diff options
context:
space:
mode:
authorxue <>2005-12-30 22:19:07 +0000
committerxue <>2005-12-30 22:19:07 +0000
commit71ca767f51b53d6b162bd6fdccfb125f2dc94d35 (patch)
treee239318ea5ef056900440bd89af7fced400539ae /framework/Web/UI
parentf5545817ebd1aeea0fd1527720ab83954665689e (diff)
Added TListBox samples.
Diffstat (limited to 'framework/Web/UI')
-rw-r--r--framework/Web/UI/TControl.php2
-rw-r--r--framework/Web/UI/WebControls/TListControl.php4
2 files changed, 3 insertions, 3 deletions
diff --git a/framework/Web/UI/TControl.php b/framework/Web/UI/TControl.php
index 372e87df..545bdf66 100644
--- a/framework/Web/UI/TControl.php
+++ b/framework/Web/UI/TControl.php
@@ -828,6 +828,8 @@ class TControl extends TComponent
*/
public function registerObject($name,$object)
{
+ if(isset($this->_rf[self::RF_NAMED_OBJECTS][$name]))
+ throw new TInvalidOperationException('control_object_reregistered',$name);
$this->_rf[self::RF_NAMED_OBJECTS][$name]=$object;
}
diff --git a/framework/Web/UI/WebControls/TListControl.php b/framework/Web/UI/WebControls/TListControl.php
index 7e81fd6c..ec7df0c9 100644
--- a/framework/Web/UI/WebControls/TListControl.php
+++ b/framework/Web/UI/WebControls/TListControl.php
@@ -24,6 +24,7 @@ abstract class TListControl extends TDataBoundControl
$writer->addAttribute('multiple','multiple');
if($this->getAutoPostBack() && $page->getClientSupportsJavaScript())
{
+ $writer->addAttribute('id',$this->getClientID());
$options = $this->getAutoPostBackOptions();
$scripts = $this->getPage()->getClientScript();
$postback = $scripts->getPostBackEventReference($this,'',$options,false);
@@ -387,9 +388,6 @@ abstract class TListControl extends TDataBoundControl
}
}
-
-
-
class TListItemCollection extends TList
{
private $_items=null;