summaryrefslogtreecommitdiff
path: root/framework/Web
diff options
context:
space:
mode:
authorxue <>2007-07-17 13:21:57 +0000
committerxue <>2007-07-17 13:21:57 +0000
commit837b7af71deb8c16d9cf7301b989ffd6016c106d (patch)
tree44267a5d072ef475f13eafbbb33627a37e1de4c3 /framework/Web
parentfa46cf440d6ea3e506f5364825016feb73e211d8 (diff)
code moving.
Diffstat (limited to 'framework/Web')
-rw-r--r--framework/Web/UI/WebControls/TDatePicker.php16
1 files changed, 8 insertions, 8 deletions
diff --git a/framework/Web/UI/WebControls/TDatePicker.php b/framework/Web/UI/WebControls/TDatePicker.php
index eee5ac2f..3e9d97df 100644
--- a/framework/Web/UI/WebControls/TDatePicker.php
+++ b/framework/Web/UI/WebControls/TDatePicker.php
@@ -351,6 +351,14 @@ class TDatePicker extends TTextBox
public function onPreRender($param)
{
parent::onPreRender($param);
+ if($this->getInputMode() === TDatePickerInputMode::DropDownList)
+ {
+ $page = $this->getPage();
+ $uniqueID = $this->getUniqueID();
+ $page->registerPostDataLoader($uniqueID.TControl::ID_SEPARATOR.'day');
+ $page->registerPostDataLoader($uniqueID.TControl::ID_SEPARATOR.'month');
+ $page->registerPostDataLoader($uniqueID.TControl::ID_SEPARATOR.'year');
+ }
$this->publishCalendarStyle();
}
@@ -767,14 +775,6 @@ class TDatePicker extends TTextBox
*/
protected function publishCalendarStyle()
{
- if($this->getInputMode() === TDatePickerInputMode::DropDownList)
- {
- $page = $this->getPage();
- $uniqueID = $this->getUniqueID();
- $page->registerPostDataLoader($uniqueID.TControl::ID_SEPARATOR.'day');
- $page->registerPostDataLoader($uniqueID.TControl::ID_SEPARATOR.'month');
- $page->registerPostDataLoader($uniqueID.TControl::ID_SEPARATOR.'year');
- }
$url = $this->getAssetUrl($this->getCalendarStyle().'.css');
$cs = $this->getPage()->getClientScript();
if(!$cs->isStyleSheetFileRegistered($url))