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 --- .../pages/ActiveControls/ActiveControl.php | 86 +++++++++++----------- .../pages/ActiveControls/AutoComplete.php | 66 ++++++++--------- .../protected/pages/ActiveControls/Calculator.php | 28 +++---- .../protected/pages/ActiveControls/Calculator2.php | 38 +++++----- .../pages/ActiveControls/VisibleUpdate.php | 70 +++++++++--------- 5 files changed, 144 insertions(+), 144 deletions(-) (limited to 'tests/FunctionalTests/features/protected/pages/ActiveControls') diff --git a/tests/FunctionalTests/features/protected/pages/ActiveControls/ActiveControl.php b/tests/FunctionalTests/features/protected/pages/ActiveControls/ActiveControl.php index b2dd2233..322f4db7 100644 --- a/tests/FunctionalTests/features/protected/pages/ActiveControls/ActiveControl.php +++ b/tests/FunctionalTests/features/protected/pages/ActiveControls/ActiveControl.php @@ -1,43 +1,43 @@ -label1->setText("The time is ".time()." from ".$sender->ID); - $this->label1->setForeColor($this->getColor()); - $this->label1->renderControl($param->getOutput()); - - $this->button2->setEnabled(true); - - $this->panel2->setVisible(true); - $this->panel1->setBackColor($this->getColor()); - $this->panel1->renderControl($param->getOutput()); - $this->getCallbackClient()->shake($this->panel1); - } - - public function onButtonClicked($sender, $param) - { - $this->label2->setText("Muahaha !!! the time is ".time()." from ".$sender->ID); - } - - public function fastResponse($sender, $param) - { - $this->button2->setEnabled(false); - $style['color'] = $this->getColor(); - $this->getCallbackClient()->setStyle($this->label2, $style); - $this->getCallbackClient()->shake($this->label2); - } - - private function getColor() - { - return self::$_colors[rand(0,count(self::$_colors)-1)]; - } -} -?> +label1->setText("The time is ".time()." from ".$sender->ID); + $this->label1->setForeColor($this->getColor()); + $this->label1->renderControl($param->getOutput()); + + $this->button2->setEnabled(true); + + $this->panel2->setVisible(true); + $this->panel1->setBackColor($this->getColor()); + $this->panel1->renderControl($param->getOutput()); + $this->getCallbackClient()->shake($this->panel1); + } + + public function onButtonClicked($sender, $param) + { + $this->label2->setText("Muahaha !!! the time is ".time()." from ".$sender->ID); + } + + public function fastResponse($sender, $param) + { + $this->button2->setEnabled(false); + $style['color'] = $this->getColor(); + $this->getCallbackClient()->setStyle($this->label2, $style); + $this->getCallbackClient()->shake($this->label2); + } + + private function getColor() + { + return self::$_colors[rand(0,count(self::$_colors)-1)]; + } +} +?> diff --git a/tests/FunctionalTests/features/protected/pages/ActiveControls/AutoComplete.php b/tests/FunctionalTests/features/protected/pages/ActiveControls/AutoComplete.php index 3474234e..ac08e4ed 100644 --- a/tests/FunctionalTests/features/protected/pages/ActiveControls/AutoComplete.php +++ b/tests/FunctionalTests/features/protected/pages/ActiveControls/AutoComplete.php @@ -1,34 +1,34 @@ -setDataSource($this->matchCountries($param->getParameter())); - $sender->dataBind(); - $sender->render($param->getOutput()); - } - - protected function matchCountries($token) - { - $info = Prado::createComponent('System.I18N.core.CultureInfo', 'en'); - $list = array(); - $count = 0; - $token = strtolower($token); - foreach($info->getCountries() as $country) - { - if(strpos(strtolower($country), $token) === 0) - { - $list[] = $country; - $count++; - if($count > 10) break; - } - } - return $list; - } -} - +setDataSource($this->matchCountries($param->getParameter())); + $sender->dataBind(); + $sender->render($param->getOutput()); + } + + protected function matchCountries($token) + { + $info = Prado::createComponent('System.I18N.core.CultureInfo', 'en'); + $list = array(); + $count = 0; + $token = strtolower($token); + foreach($info->getCountries() as $country) + { + if(strpos(strtolower($country), $token) === 0) + { + $list[] = $country; + $count++; + if($count > 10) break; + } + } + return $list; + } +} + ?> \ No newline at end of file diff --git a/tests/FunctionalTests/features/protected/pages/ActiveControls/Calculator.php b/tests/FunctionalTests/features/protected/pages/ActiveControls/Calculator.php index 9821d8c9..7afd1d59 100644 --- a/tests/FunctionalTests/features/protected/pages/ActiveControls/Calculator.php +++ b/tests/FunctionalTests/features/protected/pages/ActiveControls/Calculator.php @@ -1,15 +1,15 @@ -c->Text = floatval($this->a->Text) + floatval($this->b->Text); - } -} - +c->Text = floatval($this->a->Text) + floatval($this->b->Text); + } +} + ?> \ No newline at end of file diff --git a/tests/FunctionalTests/features/protected/pages/ActiveControls/Calculator2.php b/tests/FunctionalTests/features/protected/pages/ActiveControls/Calculator2.php index df07440f..3789a3f9 100644 --- a/tests/FunctionalTests/features/protected/pages/ActiveControls/Calculator2.php +++ b/tests/FunctionalTests/features/protected/pages/ActiveControls/Calculator2.php @@ -1,20 +1,20 @@ -c->Text = floatval($this->a->Text) + floatval($this->b->Text); - } - - public function update_callback($sender, $param) - { - $this->do_sum($this->sum, null); - $this->panel1->renderControl($param->Output); - } -} - +c->Text = floatval($this->a->Text) + floatval($this->b->Text); + } + + public function update_callback($sender, $param) + { + $this->do_sum($this->sum, null); + $this->panel1->renderControl($param->Output); + } +} + ?> \ No newline at end of file diff --git a/tests/FunctionalTests/features/protected/pages/ActiveControls/VisibleUpdate.php b/tests/FunctionalTests/features/protected/pages/ActiveControls/VisibleUpdate.php index 0c9b16d5..1b1d0cbc 100644 --- a/tests/FunctionalTests/features/protected/pages/ActiveControls/VisibleUpdate.php +++ b/tests/FunctionalTests/features/protected/pages/ActiveControls/VisibleUpdate.php @@ -1,36 +1,36 @@ -label1->setText($this->getButtonState($sender)); - - //$this->button1->setEnabled(false); - $this->button1->setVisible(false); - // $this->button2->setEnabled(true); - $this->button2->setVisible(true); - } - - function click2($sender) - { - $this->label1->setText($this->getButtonState($sender)); - - // $this->button1->setEnabled(true); - $this->button1->setVisible(true); - /// $this->button2->setEnabled(false); - $this->button2->setVisible(false); - } - - protected function getButtonState($button) - { - return "Before you clicked on ".$button->Text. - ", Button 1 was ".($this->button1->Enabled ? 'enabled' : 'disabled'). - " and Button 2 was ".($this->button2->Enabled ? 'enabled' : 'disabled'); - } -} - +label1->setText($this->getButtonState($sender)); + + //$this->button1->setEnabled(false); + $this->button1->setVisible(false); + // $this->button2->setEnabled(true); + $this->button2->setVisible(true); + } + + function click2($sender) + { + $this->label1->setText($this->getButtonState($sender)); + + // $this->button1->setEnabled(true); + $this->button1->setVisible(true); + /// $this->button2->setEnabled(false); + $this->button2->setVisible(false); + } + + protected function getButtonState($button) + { + return "Before you clicked on ".$button->Text. + ", Button 1 was ".($this->button1->Enabled ? 'enabled' : 'disabled'). + " and Button 2 was ".($this->button2->Enabled ? 'enabled' : 'disabled'); + } +} + ?> \ No newline at end of file -- cgit v1.2.3