From bde6488e19b9852011a657fda8aa39680d9c4a62 Mon Sep 17 00:00:00 2001 From: wei <> Date: Sat, 6 Jan 2007 00:00:57 +0000 Subject: Update docs. --- .../protected/pages/DMessagesPanel.php | 63 ++++++++++++++++++++++ .../protected/pages/DMessagesPanel.tpl | 4 ++ .../protected/pages/DatePickerInCallback.page | 7 +++ .../protected/pages/DatePickerInCallback.php | 17 ++++++ .../protected/pages/MessagesPanelTest.page | 7 +++ .../protected/pages/MessagesPanelTest.php | 16 ++++++ 6 files changed, 114 insertions(+) create mode 100644 tests/FunctionalTests/active-controls/protected/pages/DMessagesPanel.php create mode 100644 tests/FunctionalTests/active-controls/protected/pages/DMessagesPanel.tpl create mode 100644 tests/FunctionalTests/active-controls/protected/pages/DatePickerInCallback.page create mode 100644 tests/FunctionalTests/active-controls/protected/pages/DatePickerInCallback.php create mode 100644 tests/FunctionalTests/active-controls/protected/pages/MessagesPanelTest.page create mode 100644 tests/FunctionalTests/active-controls/protected/pages/MessagesPanelTest.php (limited to 'tests/FunctionalTests/active-controls/protected') diff --git a/tests/FunctionalTests/active-controls/protected/pages/DMessagesPanel.php b/tests/FunctionalTests/active-controls/protected/pages/DMessagesPanel.php new file mode 100644 index 00000000..d318660d --- /dev/null +++ b/tests/FunctionalTests/active-controls/protected/pages/DMessagesPanel.php @@ -0,0 +1,63 @@ +MessagesPanelEffect->Text = ""; + } + + public function setMessage($value) + { + $this->Message->Text = $value; + if ($value != '') + $this->setVisible(true); + else + $this->setVisible(false); + } + + public function setVisible($value) + { + $this->ensureChildControls(); + if ($value === true) { + echo "set visible"; + $this->MessagesPanel->Visible = true; + $this->Message->Visible = true; + $this->setEffect(null); + } else { + $this->MessagesPanel->Visible = false; + } + } + + public function setEffect($effect = null) + { + if ($effect !== null) { + $text = ""; + $this->MessagesPanelEffect->Text = $text; + } else { + $this->MessagesPanelEffect->Text = ''; + } + } + + public function setPanelCssClass($value) + { + $this->ensureChildControls(); + $this->MessagesPanel->CssClass = $value; + } + + public function setMessageCssClass($value) + { + $this->ensureChildControls(); + $this->Message->CssClass = $value; + } +} + +?> \ No newline at end of file diff --git a/tests/FunctionalTests/active-controls/protected/pages/DMessagesPanel.tpl b/tests/FunctionalTests/active-controls/protected/pages/DMessagesPanel.tpl new file mode 100644 index 00000000..b7e73119 --- /dev/null +++ b/tests/FunctionalTests/active-controls/protected/pages/DMessagesPanel.tpl @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/tests/FunctionalTests/active-controls/protected/pages/DatePickerInCallback.page b/tests/FunctionalTests/active-controls/protected/pages/DatePickerInCallback.page new file mode 100644 index 00000000..8b39dc55 --- /dev/null +++ b/tests/FunctionalTests/active-controls/protected/pages/DatePickerInCallback.page @@ -0,0 +1,7 @@ + +

DatePicker in Callback

+ + + + +
\ No newline at end of file diff --git a/tests/FunctionalTests/active-controls/protected/pages/DatePickerInCallback.php b/tests/FunctionalTests/active-controls/protected/pages/DatePickerInCallback.php new file mode 100644 index 00000000..94a4ec25 --- /dev/null +++ b/tests/FunctionalTests/active-controls/protected/pages/DatePickerInCallback.php @@ -0,0 +1,17 @@ +IsPostBack) + $this->datepicker->setTimeStamp(time()); + } + + public function testDatePicker($sender, $param){ + $this->status->Text = $this->datepicker->getTimestamp()." ".$this->datepicker->getText(); + } + + } + +?> \ No newline at end of file diff --git a/tests/FunctionalTests/active-controls/protected/pages/MessagesPanelTest.page b/tests/FunctionalTests/active-controls/protected/pages/MessagesPanelTest.page new file mode 100644 index 00000000..ab4798a8 --- /dev/null +++ b/tests/FunctionalTests/active-controls/protected/pages/MessagesPanelTest.page @@ -0,0 +1,7 @@ + + + + + + + \ No newline at end of file diff --git a/tests/FunctionalTests/active-controls/protected/pages/MessagesPanelTest.php b/tests/FunctionalTests/active-controls/protected/pages/MessagesPanelTest.php new file mode 100644 index 00000000..9a59713d --- /dev/null +++ b/tests/FunctionalTests/active-controls/protected/pages/MessagesPanelTest.php @@ -0,0 +1,16 @@ +panel1->setMessage("hello world"); + } + + function hide_clicked($sender, $param) + { + $this->panel1->setMessage(""); + } +} + +?> \ No newline at end of file -- cgit v1.2.3