http://www.mediawiki.org/wiki/Special:Code/MediaWiki/83585

Revision: 83585
Author:   junaidpv
Date:     2011-03-09 12:55:51 +0000 (Wed, 09 Mar 2011)
Log Message:
-----------
Naryam: Add escaping for English characters on Sinhala Singlish. Correct errors 
occured in Oriya scheme due to copy pasting, reported in r83209 by Catrope 
(Roan Kattouw. Fix a bug: Selected scheme was not rembered in cookie, reported 
by vssun

Modified Paths:
--------------
    trunk/extensions/Narayam/ext.narayam.core.js
    trunk/extensions/Narayam/ext.narayam.rules.or.js
    trunk/extensions/Narayam/ext.narayam.rules.si-singlish.js

Modified: trunk/extensions/Narayam/ext.narayam.core.js
===================================================================
--- trunk/extensions/Narayam/ext.narayam.core.js        2011-03-09 12:42:56 UTC 
(rev 83584)
+++ trunk/extensions/Narayam/ext.narayam.core.js        2011-03-09 12:55:51 UTC 
(rev 83585)
@@ -342,7 +342,7 @@
        this.setScheme = function( name ) {
                if ( name in schemes ) {
                        currentScheme = schemes[name];
-                       $.cookie( 'narayam-scheme', scheme, { 'path': '/', 
'expires': 30 } );
+                       $.cookie( 'narayam-scheme', name, { 'path': '/', 
'expires': 30 } );
                        $select.val( name );
                }
        };

Modified: trunk/extensions/Narayam/ext.narayam.rules.or.js
===================================================================
--- trunk/extensions/Narayam/ext.narayam.rules.or.js    2011-03-09 12:42:56 UTC 
(rev 83584)
+++ trunk/extensions/Narayam/ext.narayam.rules.or.js    2011-03-09 12:55:51 UTC 
(rev 83585)
@@ -7,26 +7,26 @@
  */
 // Normal rules
 var rules = [
-['\\\\([A-Za-z\\>_~\\.0-9])', '\\\\','$2'],
+['\\\\([A-Za-z\\>_~\\.0-9])', '\\\\','$1'],
 
 ['ଞ୍ଜ୍h', '', 'ଞ୍ଝ୍'], // njh
 ['ଙ୍ଗ୍h', '', 'ଙ୍ଘ୍'], // ngh
 
-['([କ-ହ])୍a', '','$2'],
-['([କ-ହ])(a|୍A)', '','$2ା'],
-['([କ-ହ])୍i', '','$2\u0b3f'],
-['([କ-ହ])(୍I|\u0b3fe)', '','$2ୀ'],
-['([କ-ହ])୍u', '','$2\u0b41'],
-['([କ-ହ])(୍U|\u0b41u)', '','$2\u0b42'],
-['([କ-ହ])୍R', '','$2\u0b43'],
-['([କ-ହ])\u0b43R', '','$2\u0b44'],
-['([କ-ହ])୍ଳ୍l', '','$2ୢ'],
-['([କ-ହ])ୢl', '','$2ୣ'],
-['([କ-ହ])୍e', '','$2େ'],
-['([କ-ହ])i', '','$2ୈ'],
-['([କ-ହ])୍o', '','$2ୋ'],
-['([କ-ହ])ୋu', '','$2ୌ'],
-['([କ-ହ])୍E', '','$2\u0B48'],
+['([କ-ହ])୍a', '','$1'],
+['([କ-ହ])(a|୍A)', '','$1ା'],
+['([କ-ହ])୍i', '','$1\u0b3f'],
+['([କ-ହ])(୍I|\u0b3fe)', '','$1ୀ'],
+['([କ-ହ])୍u', '','$1\u0b41'],
+['([କ-ହ])(୍U|\u0b41u)', '','$1\u0b42'],
+['([କ-ହ])୍R', '','$1\u0b43'],
+['([କ-ହ])\u0b43R', '','$1\u0b44'],
+['([କ-ହ])୍ଳ୍l', '','$1ୢ'],
+['([କ-ହ])ୢl', '','$1ୣ'],
+['([କ-ହ])୍e', '','$1େ'],
+['([କ-ହ])i', '','$1ୈ'],
+['([କ-ହ])୍o', '','$1ୋ'],
+['([କ-ହ])ୋu', '','$1ୌ'],
+['([କ-ହ])୍E', '','$1\u0B48'],
 
 ['ଅa', '','ଆ'],
 ['(ଅi|ଏe)', '','ଐ'],
@@ -119,7 +119,7 @@
 jQuery.narayam.addScheme( 'or', {
        'namemsg': 'narayam-or',
        'extended_keyboard': true,
-       'lookbackLength': 0,
-       'keyBufferLength': 0,
+       'lookbackLength': 4,
+       'keyBufferLength': 2,
        'rules': rules
 } );

Modified: trunk/extensions/Narayam/ext.narayam.rules.si-singlish.js
===================================================================
--- trunk/extensions/Narayam/ext.narayam.rules.si-singlish.js   2011-03-09 
12:42:56 UTC (rev 83584)
+++ trunk/extensions/Narayam/ext.narayam.rules.si-singlish.js   2011-03-09 
12:55:51 UTC (rev 83585)
@@ -8,6 +8,8 @@
  
 // Normal rules
 var rules = [
+['\\\\([A-Za-z\\>_~\\.0-9])', '\\\\','$1'],
+
 ['ඬ්හ්a', '', 'ඳ'],    // nndha
 ['න්න්d', '', 'ඬ්'],   // nnd
 ['න්න්g', '', 'ඟ්'],   // nng
@@ -100,6 +102,6 @@
        'namemsg': 'narayam-si-singlish',
        'extended_keyboard': false,
        'lookbackLength': 5,
-       'keyBufferLength': 0,
+       'keyBufferLength': 2,
        'rules': rules
 } ); 


_______________________________________________
MediaWiki-CVS mailing list
MediaWiki-CVS@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to