From 903ae8a581fac1e6917fc3e31d2ad8fb91df80c3 Mon Sep 17 00:00:00 2001 From: ctrlaltca <> Date: Thu, 12 Jul 2012 11:21:01 +0000 Subject: standardize the use of unix eol; use svn properties to enforce native eol --- .../Samples/TActiveDropDownList/Home.php | 118 ++++++++++----------- 1 file changed, 59 insertions(+), 59 deletions(-) (limited to 'demos/quickstart/protected/pages/ActiveControls/Samples/TActiveDropDownList') diff --git a/demos/quickstart/protected/pages/ActiveControls/Samples/TActiveDropDownList/Home.php b/demos/quickstart/protected/pages/ActiveControls/Samples/TActiveDropDownList/Home.php index 0ba728c6..5b16af2c 100644 --- a/demos/quickstart/protected/pages/ActiveControls/Samples/TActiveDropDownList/Home.php +++ b/demos/quickstart/protected/pages/ActiveControls/Samples/TActiveDropDownList/Home.php @@ -1,60 +1,60 @@ -IsPostBack && !$this->IsCallback) - { - $this->resetClicked(null,null); - } - } - - protected function collectSelectionResult($input,$output) - { - $indices=$input->SelectedIndices; - $result=''; - foreach($indices as $index) - { - $item=$input->Items[$index]; - $result.="(Index: $index, Value: $item->Value, Text: $item->Text)"; - } - if($result==='') - $output->Text='Your selection is empty.'; - else - $output->Text='Your selection is: '.$result; - } - - public function selectionChanged($sender,$param) - { - $this->collectSelectionResult($sender,$this->SelectionResult); - } - - public function buttonClicked($sender, $param) - { - $data=array(); - for($i = 0; $i <= $this->ddl1->Items->Count; $i++) - $data[$i]="Item number #".$i; - $this->ddl1->DataSource=$data; - $this->ddl1->dataBind(); - $this->label1->Text="Total ".count($data)." items"; - } - - public function resetClicked($sender, $param) - { - $data=array('item 1','item 2','item 3','item 4'); - $this->ddl2->DataSource=$data; - $this->ddl2->dataBind(); - $this->label2->Text="DropDownList has been reset"; - } - - public function clearClicked($sender, $param) - { - $this->ddl2->DataSource=array(); - $this->ddl2->dataBind(); - $this->label2->Text="DropDownList cleared"; - } -} - +IsPostBack && !$this->IsCallback) + { + $this->resetClicked(null,null); + } + } + + protected function collectSelectionResult($input,$output) + { + $indices=$input->SelectedIndices; + $result=''; + foreach($indices as $index) + { + $item=$input->Items[$index]; + $result.="(Index: $index, Value: $item->Value, Text: $item->Text)"; + } + if($result==='') + $output->Text='Your selection is empty.'; + else + $output->Text='Your selection is: '.$result; + } + + public function selectionChanged($sender,$param) + { + $this->collectSelectionResult($sender,$this->SelectionResult); + } + + public function buttonClicked($sender, $param) + { + $data=array(); + for($i = 0; $i <= $this->ddl1->Items->Count; $i++) + $data[$i]="Item number #".$i; + $this->ddl1->DataSource=$data; + $this->ddl1->dataBind(); + $this->label1->Text="Total ".count($data)." items"; + } + + public function resetClicked($sender, $param) + { + $data=array('item 1','item 2','item 3','item 4'); + $this->ddl2->DataSource=$data; + $this->ddl2->dataBind(); + $this->label2->Text="DropDownList has been reset"; + } + + public function clearClicked($sender, $param) + { + $this->ddl2->DataSource=array(); + $this->ddl2->dataBind(); + $this->label2->Text="DropDownList cleared"; + } +} + ?> \ No newline at end of file -- cgit v1.2.3