r67718 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r67717‎ | r67718 | r67719 >
Date:13:57, 9 June 2010
Author:catrope
Status:deferred
Tags:
Comment:
UsabilityInitiative: (bug 23858) Special character insertion doesn't overwrite selection
Modified paths:
  • /trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php (modified) (history)
  • /trunk/extensions/UsabilityInitiative/js/plugins.combined.js (modified) (history)
  • /trunk/extensions/UsabilityInitiative/js/plugins.combined.min.js (modified) (history)
  • /trunk/extensions/UsabilityInitiative/js/plugins/jquery.wikiEditor.toolbar.js (modified) (history)

Diff [purge]

Index: trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php
@@ -77,7 +77,7 @@
7878 array( 'src' => 'js/plugins/jquery.textSelection.js', 'version' => 34 ),
7979 array( 'src' => 'js/plugins/jquery.wikiEditor.js', 'version' => 191 ),
8080 array( 'src' => 'js/plugins/jquery.wikiEditor.highlight.js', 'version' => 53 ),
81 - array( 'src' => 'js/plugins/jquery.wikiEditor.toolbar.js', 'version' => 65 ),
 81+ array( 'src' => 'js/plugins/jquery.wikiEditor.toolbar.js', 'version' => 66 ),
8282 array( 'src' => 'js/plugins/jquery.wikiEditor.dialogs.js', 'version' => 25 ),
8383 array( 'src' => 'js/plugins/jquery.wikiEditor.toc.js', 'version' => 98 ),
8484 array( 'src' => 'js/plugins/jquery.wikiEditor.preview.js', 'version' => 11 ),
@@ -89,10 +89,10 @@
9090 array( 'src' => 'js/thirdparty/contentCollector.js', 'version' => 1 ),
9191 ),
9292 'combined' => array(
93 - array( 'src' => 'js/plugins.combined.js', 'version' => 418 ),
 93+ array( 'src' => 'js/plugins.combined.js', 'version' => 419 ),
9494 ),
9595 'minified' => array(
96 - array( 'src' => 'js/plugins.combined.min.js', 'version' => 418 ),
 96+ array( 'src' => 'js/plugins.combined.min.js', 'version' => 419 ),
9797 ),
9898 ),
9999 );
Index: trunk/extensions/UsabilityInitiative/js/plugins/jquery.wikiEditor.toolbar.js
@@ -540,9 +540,9 @@
541541 character = {
542542 'label' : character,
543543 'action' : {
544 - 'type' : 'encapsulate',
 544+ 'type' : 'replace',
545545 'options' : {
546 - 'pre' : character
 546+ 'peri' : character
547547 }
548548 }
549549 };
@@ -550,9 +550,9 @@
551551 character = {
552552 'label' : character[0],
553553 'action' : {
554 - 'type' : 'encapsulate',
 554+ 'type' : 'replace',
555555 'options' : {
556 - 'pre' : character[1]
 556+ 'peri' : character[1]
557557 }
558558 }
559559 };
Index: trunk/extensions/UsabilityInitiative/js/plugins.combined.js
@@ -11634,9 +11634,9 @@
1163511635 character = {
1163611636 'label' : character,
1163711637 'action' : {
11638 - 'type' : 'encapsulate',
 11638+ 'type' : 'replace',
1163911639 'options' : {
11640 - 'pre' : character
 11640+ 'peri' : character
1164111641 }
1164211642 }
1164311643 };
@@ -11644,9 +11644,9 @@
1164511645 character = {
1164611646 'label' : character[0],
1164711647 'action' : {
11648 - 'type' : 'encapsulate',
 11648+ 'type' : 'replace',
1164911649 'options' : {
11650 - 'pre' : character[1]
 11650+ 'peri' : character[1]
1165111651 }
1165211652 }
1165311653 };
Index: trunk/extensions/UsabilityInitiative/js/plugins.combined.min.js
@@ -796,7 +796,7 @@
797797 return $page;},buildHeading:function(context,headings){var html='<tr>';for(heading in headings){html+='<th>'+$.wikiEditor.autoMsg(headings[heading],['html','text'])+'</th>';}
798798 return html;},buildRow:function(context,row){var html='<tr>';for(cell in row){html+='<td class="cell cell-'+cell+'" valign="top"><span>'+
799799 $.wikiEditor.autoMsg(row[cell],['html','text'])+'</span></td>';}
800 -html+='</tr>';return html;},buildCharacter:function(character,actions){if(typeof character=='string'){character={'label':character,'action':{'type':'encapsulate','options':{'pre':character}}};}else if(0 in character&&1 in character){character={'label':character[0],'action':{'type':'encapsulate','options':{'pre':character[1]}}};}
 800+html+='</tr>';return html;},buildCharacter:function(character,actions){if(typeof character=='string'){character={'label':character,'action':{'type':'replace','options':{'peri':character}}};}else if(0 in character&&1 in character){character={'label':character[0],'action':{'type':'replace','options':{'peri':character[1]}}};}
801801 if('action'in character&&'label'in character){actions[character.label]=character.action;return'<span rel="'+character.label+'">'+character.label+'</span>';}},buildTab:function(context,id,section){var selected=$.cookie('wikiEditor-'+context.instance+'-toolbar-section');if(selected!=null){$.cookie('wikiEditor-'+context.instance+'-toolbar-section',selected,{expires:30,path:'/'});}
802802 return $('<span />').attr({'class':'tab tab-'+id,'rel':id}).append($('<a />').addClass(selected==id?'current':null).attr('href','#').text($.wikiEditor.autoMsg(section,'label')).data('context',context).mouseup(function(e){$(this).blur();}).mousedown(function(e){e.preventDefault();return false;}).click(function(e){var $sections=$(this).data('context').$ui.find('.sections');var $section=$(this).data('context').$ui.find('.section-'+$(this).parent().attr('rel'));var show=$section.css('display')=='none';$previousSections=$section.parent().find('.section-visible');$previousSections.css('position','absolute');$previousSections.removeClass('section-visible');$previousSections.fadeOut('fast',function(){$(this).css('position','relative');});$(this).parent().parent().find('a').removeClass('current');$sections.css('overflow','hidden');function animate($this){$sections.css('display','block').animate({'height':$section.outerHeight()},$section.outerHeight()*2,function(){$this.css('overflow','visible').css('height','auto');context.fn.trigger('resize');});}
803803 if(show){$section.addClass('section-visible');$section.fadeIn('fast');if($section.hasClass('loading')){$this=$(this);$this.addClass('current loading');setTimeout(function(){$section.trigger('loadSection');animate($(this));$this.removeClass('loading');},1000);}else{animate($(this));$(this).addClass('current');}}else{$sections.css('height',$section.outerHeight()).animate({'height':'hide'},$section.outerHeight()*2,function(){$(this).css({'overflow':'visible','height':0});context.fn.trigger('resize');});}

Status & tagging log