summaryrefslogtreecommitdiff
path: root/framework/Web/UI/WebControls/TListControl.php
diff options
context:
space:
mode:
authorwei <>2006-01-18 04:20:26 +0000
committerwei <>2006-01-18 04:20:26 +0000
commit0226f8f5f430d34b3cead40c4eb7b458933d16c6 (patch)
tree68b21c4bec09ed73edc64019b4e20a2e3853d477 /framework/Web/UI/WebControls/TListControl.php
parente2219c91b98088289080bfa451d3083851eddf76 (diff)
update javascript library and usage in web controls
Diffstat (limited to 'framework/Web/UI/WebControls/TListControl.php')
-rw-r--r--framework/Web/UI/WebControls/TListControl.php16
1 files changed, 10 insertions, 6 deletions
diff --git a/framework/Web/UI/WebControls/TListControl.php b/framework/Web/UI/WebControls/TListControl.php
index cb740124..537df7c5 100644
--- a/framework/Web/UI/WebControls/TListControl.php
+++ b/framework/Web/UI/WebControls/TListControl.php
@@ -105,10 +105,11 @@ abstract class TListControl extends TDataBoundControl
if($this->getAutoPostBack() && $page->getClientSupportsJavaScript())
{
$writer->addAttribute('id',$this->getClientID());
- $options = $this->getAutoPostBackOptions();
+ $this->getPage()->getClientScript()->registerPostBackControl($this);
+ /*$options = $this->getAutoPostBackOptions();
$scripts = $this->getPage()->getClientScript();
$postback = $scripts->getPostBackEventReference($this,'',$options,false);
- $scripts->registerClientEvent($this, "change", $postback);
+ $scripts->registerClientEvent($this, "change", $postback);*/
}
if($this->getEnabled(true) && !$this->getEnabled())
$writer->addAttribute('disabled','disabled');
@@ -118,9 +119,9 @@ abstract class TListControl extends TDataBoundControl
/**
* @return TPostBackOptions postback options for JS postback code
*/
- protected function getAutoPostBackOptions()
+ public function getPostBackOptions()
{
- $option=new TPostBackOptions();
+/* $option=new TPostBackOptions();
$group = $this->getValidationGroup();
$hasValidators = $this->getPage()->getValidators($group)->getCount()>0;
if($this->getCausesValidation() && $hasValidators)
@@ -128,8 +129,11 @@ abstract class TListControl extends TDataBoundControl
$option->setPerformValidation(true);
$option->setValidationGroup($group);
}
- $option->setAutoPostBack(true);
- return $option;
+ $option->setAutoPostBack(true);*/
+ $options['CausesValidation'] = $this->getCausesValidation();
+ $options['ValidationGroup'] = $this->getValidationGroup();
+ $options['EventTarget'] = $this->getUniqueID();
+ return $options;
}
/**