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 --- framework/I18N/TI18NControl.php | 180 ++++++++++++++++++++-------------------- 1 file changed, 90 insertions(+), 90 deletions(-) (limited to 'framework/I18N/TI18NControl.php') diff --git a/framework/I18N/TI18NControl.php b/framework/I18N/TI18NControl.php index 7e8efe0a..79c7d5ed 100644 --- a/framework/I18N/TI18NControl.php +++ b/framework/I18N/TI18NControl.php @@ -1,90 +1,90 @@ - - * @link http://www.pradosoft.com/ - * @copyright Copyright © 2005-2012 PradoSoft - * @license http://www.pradosoft.com/license/ - * @version $Id$ - * @package System.I18N - */ - - -/** - * TI18NControl class. - * - * Base class for I18N components, providing Culture and Charset properties. - * Namespace: System.I18N - * - * Properties - * - Culture, string, - *
Gets or sets the culture for formatting. If the Culture property - * is not specified. The culture from the Application/Page is used. - * - Charset, string, - *
Gets or sets the charset for both input and output. - * If the Charset property is not specified. The charset from the - * Application/Page is used. The default is UTF-8. - * - * @author Xiang Wei Zhuo - * @version v1.0, last update on Sat Dec 11 15:25:11 EST 2004 - * @package System.I18N - */ -class TI18NControl extends TControl -{ - /** - * Gets the charset. - * It is evaluated in the following order: - * 1) application charset, - * 2) the default charset in globalization - * 3) UTF-8 - * @return string charset - */ - public function getCharset() - { - $app = $this->getApplication()->getGlobalization(false); - - //instance charset - $charset = $this->getViewState('Charset',''); - - //fall back to globalization charset - if(empty($charset)) - $charset = ($app===null) ? '' : $app->getCharset(); - - //fall back to default charset - if(empty($charset)) - $charset = ($app===null) ? 'UTF-8' : $app->getDefaultCharset(); - - return $charset; - } - - /** - * Sets the charset for message output - * @param string the charset, e.g. UTF-8 - */ - public function setCharset($value) - { - $this->setViewState('Charset',$value,''); - } - - - /** - * Get the specific culture for this control. - * @param parameter - * @return string culture identifier. - */ - public function getCulture() - { - return $this->getViewState('Culture',''); - } - - /** - * Get the custom culture identifier. - * @param string culture identifier. - */ - public function setCulture($culture) - { - $this->setViewState('Culture',$culture,''); - } -} - + + * @link http://www.pradosoft.com/ + * @copyright Copyright © 2005-2012 PradoSoft + * @license http://www.pradosoft.com/license/ + * @version $Id$ + * @package System.I18N + */ + + +/** + * TI18NControl class. + * + * Base class for I18N components, providing Culture and Charset properties. + * Namespace: System.I18N + * + * Properties + * - Culture, string, + *
Gets or sets the culture for formatting. If the Culture property + * is not specified. The culture from the Application/Page is used. + * - Charset, string, + *
Gets or sets the charset for both input and output. + * If the Charset property is not specified. The charset from the + * Application/Page is used. The default is UTF-8. + * + * @author Xiang Wei Zhuo + * @version v1.0, last update on Sat Dec 11 15:25:11 EST 2004 + * @package System.I18N + */ +class TI18NControl extends TControl +{ + /** + * Gets the charset. + * It is evaluated in the following order: + * 1) application charset, + * 2) the default charset in globalization + * 3) UTF-8 + * @return string charset + */ + public function getCharset() + { + $app = $this->getApplication()->getGlobalization(false); + + //instance charset + $charset = $this->getViewState('Charset',''); + + //fall back to globalization charset + if(empty($charset)) + $charset = ($app===null) ? '' : $app->getCharset(); + + //fall back to default charset + if(empty($charset)) + $charset = ($app===null) ? 'UTF-8' : $app->getDefaultCharset(); + + return $charset; + } + + /** + * Sets the charset for message output + * @param string the charset, e.g. UTF-8 + */ + public function setCharset($value) + { + $this->setViewState('Charset',$value,''); + } + + + /** + * Get the specific culture for this control. + * @param parameter + * @return string culture identifier. + */ + public function getCulture() + { + return $this->getViewState('Culture',''); + } + + /** + * Get the custom culture identifier. + * @param string culture identifier. + */ + public function setCulture($culture) + { + $this->setViewState('Culture',$culture,''); + } +} + -- cgit v1.2.3