From 9af56fd93ed071d86f14296cec618073f6c0941a Mon Sep 17 00:00:00 2001 From: wei <> Date: Sat, 23 Sep 2006 01:08:19 +0000 Subject: Fixed #383 --- .../active-controls/protected/pages/LTemplate.php | 72 ++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 tests/FunctionalTests/active-controls/protected/pages/LTemplate.php (limited to 'tests/FunctionalTests/active-controls/protected/pages/LTemplate.php') diff --git a/tests/FunctionalTests/active-controls/protected/pages/LTemplate.php b/tests/FunctionalTests/active-controls/protected/pages/LTemplate.php new file mode 100644 index 00000000..0a5c311e --- /dev/null +++ b/tests/FunctionalTests/active-controls/protected/pages/LTemplate.php @@ -0,0 +1,72 @@ +setEnableViewState(false); + } + + function setSize($value) + { + $this->setViewState("Size", $value); + } + + function getSize() + { + return $this->getViewState("Size", "Small"); + } + + function onInit($param) + { + parent :: onInit($param); + $this->Controls[] = "OnInit"; + } + + function onLoad($param) + { + parent :: onLoad($param); + $this->Controls[] = "OnLoad"; + $this->adjustLayout(); + } + + function onPreRender($param) + { + parent :: onPreRender($param); + $this->Controls[] = "OnPreRender"; + } + + function adjustLayout() + { + if ($this->getSize() == "Large") + { + $this->Small->setVisible(false); + } + else + { + $this->Large->setVisible(false); + } + } + +} +?> \ No newline at end of file -- cgit v1.2.3