Use normal space instead of   in "white-space: nowrap
[lhc/web/wiklou.git] / languages / classes / LanguageKk.php
index 1a09818..0f60889 100644 (file)
@@ -279,27 +279,22 @@ class KkConverter extends LanguageConverter {
         * @return string
         */
        function translate( $text, $toVariant ) {
-               global $wgLanguageCode;
                $text = parent::translate( $text, $toVariant );
 
                switch ( $toVariant ) {
                        case 'kk-cyrl':
                        case 'kk-kz':
                                $letters = KK_L_UC . KK_L_LC . 'ʺʹ#0123456789';
-                               $wgLanguageCode = 'kk';
                                break;
                        case 'kk-latn':
                        case 'kk-tr':
                                $letters = KK_C_UC . KK_C_LC . '№0123456789';
-                               $wgLanguageCode = 'kk-Latn';
                                break;
                        case 'kk-arab':
                        case 'kk-cn':
                                $letters = KK_C_UC . KK_C_LC . /*KK_L_UC.KK_L_LC.'ʺʹ'.*/',;\?%\*№0123456789';
-                               $wgLanguageCode = 'kk-Arab';
                                break;
                        default:
-                               $wgLanguageCode = 'kk';
                                return $text;
                }
                // disable conversion variables like $1, $2...
@@ -427,13 +422,13 @@ class LanguageKk extends LanguageKk_cyrl {
         * @return string
         */
        function ucfirst( $string ) {
-               $variant = $this->getPreferredVariant();
-               if ( ( $variant == 'kk-latn' || $variant == 'kk-tr' ) && $string[0] == 'i' ) {
-                       $string = 'İ' . substr( $string, 1 );
-               } else {
-                       $string = parent::ucfirst( $string );
+               if ( $string[0] == 'i' ) {
+                       $variant = $this->getPreferredVariant();
+                       if ( $variant == 'kk-latn' || $variant == 'kk-tr' ) {
+                               return 'İ' . substr( $string, 1 );
+                       }
                }
-               return $string;
+               return parent::ucfirst( $string );
        }
 
        /**
@@ -444,13 +439,13 @@ class LanguageKk extends LanguageKk_cyrl {
         * @return string
         */
        function lcfirst( $string ) {
-               $variant = $this->getPreferredVariant();
-               if ( ( $variant == 'kk-latn' || $variant == 'kk-tr' ) && $string[0] == 'I' ) {
-                       $string = 'ı' . substr( $string, 1 );
-               } else {
-                       $string = parent::lcfirst( $string );
+               if ( $string[0] == 'I' ) {
+                       $variant = $this->getPreferredVariant();
+                       if ( $variant == 'kk-latn' || $variant == 'kk-tr' ) {
+                               return 'ı' . substr( $string, 1 );
+                       }
                }
-               return $string;
+               return parent::lcfirst( $string );
        }
 
        /**
@@ -459,7 +454,6 @@ class LanguageKk extends LanguageKk_cyrl {
         * @return string
         */
        function convertGrammar( $word, $case ) {
-               wfProfileIn( __METHOD__ );
 
                $variant = $this->getPreferredVariant();
                switch ( $variant ) {
@@ -478,7 +472,6 @@ class LanguageKk extends LanguageKk_cyrl {
                                $word = parent::convertGrammarKk_cyrl( $word, $case );
                }
 
-               wfProfileOut( __METHOD__ );
                return $word;
        }
 }