diff options
author | wei <> | 2006-12-13 10:07:37 +0000 |
---|---|---|
committer | wei <> | 2006-12-13 10:07:37 +0000 |
commit | 3c24d31c69dffb6f65214b6d383d446ac122ff14 (patch) | |
tree | 971267876c36893930f84d9663031b154799b10b /tests/FunctionalTests/active-controls/protected/pages/MyTabPanelTest.php | |
parent | 840854be7886236d46d3408de5a084983373b4c7 (diff) |
Fixed #488.
Diffstat (limited to 'tests/FunctionalTests/active-controls/protected/pages/MyTabPanelTest.php')
-rw-r--r-- | tests/FunctionalTests/active-controls/protected/pages/MyTabPanelTest.php | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/tests/FunctionalTests/active-controls/protected/pages/MyTabPanelTest.php b/tests/FunctionalTests/active-controls/protected/pages/MyTabPanelTest.php new file mode 100644 index 00000000..723af42d --- /dev/null +++ b/tests/FunctionalTests/active-controls/protected/pages/MyTabPanelTest.php @@ -0,0 +1,42 @@ +<?php
+
+class MyTabPanelTest extends TPage
+{
+ private $panels = array('pnlContentsA', 'pnlContentsB', 'pnlContentsC', );
+
+ private function showPanel($id, $param)
+ {
+ foreach($this->panels as $panel)
+ {
+ if($id == $panel)
+ {
+ $this->$panel->setAttribute('style', 'display: block;');
+ $this->$panel->setVisible(true);
+ $this->$panel->render($param->NewWriter);
+ }
+ else
+ {
+ $this->$panel->setVisible(false);
+ }
+ }
+ }
+
+ public function onShowPanelA($sender, $param)
+ {
+ $this->showPanel('pnlContentsA', $param);
+ }
+
+ public function onShowPanelB($sender, $param)
+ {
+ $this->showPanel('pnlContentsB', $param);
+ }
+
+ public function onShowPanelC($sender, $param)
+ {
+ $this->showPanel('pnlContentsC', $param);
+ }
+}
+
+
+
+?>
\ No newline at end of file |