X-Git-Url: https://git.immae.eu/?p=perso%2FImmae%2FProjets%2Fpackagist%2Fpiedsjaloux-ckeditor-component.git;a=blobdiff_plain;f=sources%2Fplugins%2Ftoolbar%2Fplugin.js;fp=sources%2Fplugins%2Ftoolbar%2Fplugin.js;h=fc19359ecb8312162b8bd5349507c3092084159a;hp=93e6e35baf7cb0547eb2d0150bc9972755baf669;hb=317f8f8f0651488f226b5280a8f036c7c135c639;hpb=1096cdefb1c9a3f3c4ca6807e272da6c92e5ed9c diff --git a/sources/plugins/toolbar/plugin.js b/sources/plugins/toolbar/plugin.js index 93e6e35..fc19359 100644 --- a/sources/plugins/toolbar/plugin.js +++ b/sources/plugins/toolbar/plugin.js @@ -1,5 +1,5 @@ /** - * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved. + * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.md or http://ckeditor.com/license */ @@ -34,7 +34,7 @@ if ( editor.toolbox ) { editor.toolbox.focusCommandExecuted = true; - // Make the first button focus accessible for IE. (#3417) + // Make the first button focus accessible for IE. (http://dev.ckeditor.com/ticket/3417) // Adobe AIR instead need while of delay. if ( CKEDITOR.env.ie || CKEDITOR.env.air ) { setTimeout( function() { @@ -51,7 +51,7 @@ CKEDITOR.plugins.add( 'toolbar', { requires: 'button', // jscs:disable maximumLineLength - lang: 'af,ar,bg,bn,bs,ca,cs,cy,da,de,de-ch,el,en,en-au,en-ca,en-gb,eo,es,et,eu,fa,fi,fo,fr,fr-ca,gl,gu,he,hi,hr,hu,id,is,it,ja,ka,km,ko,ku,lt,lv,mk,mn,ms,nb,nl,no,pl,pt,pt-br,ro,ru,si,sk,sl,sq,sr,sr-latn,sv,th,tr,tt,ug,uk,vi,zh,zh-cn', // %REMOVE_LINE_CORE% + lang: 'af,ar,az,bg,bn,bs,ca,cs,cy,da,de,de-ch,el,en,en-au,en-ca,en-gb,eo,es,es-mx,et,eu,fa,fi,fo,fr,fr-ca,gl,gu,he,hi,hr,hu,id,is,it,ja,ka,km,ko,ku,lt,lv,mk,mn,ms,nb,nl,no,oc,pl,pt,pt-br,ro,ru,si,sk,sl,sq,sr,sr-latn,sv,th,tr,tt,ug,uk,vi,zh,zh-cn', // %REMOVE_LINE_CORE% // jscs:enable maximumLineLength init: function( editor ) { @@ -118,10 +118,6 @@ return false; case 40: // DOWN-ARROW if ( item.button && item.button.hasArrow ) { - // Note: code is duplicated in plugins\richcombo\plugin.js in keyDownFn(). - editor.once( 'panelShow', function( evt ) { - evt.data._.panel._.currentBlock.onKeyDown( 40 ); - } ); item.execute(); } else { // Send left arrow key. @@ -190,20 +186,22 @@ output.push( '' : ' style="display:none">' ) ); var toolbars = editor.toolbox.toolbars, - toolbar = getToolbarConfig( editor ); + toolbar = getToolbarConfig( editor ), + toolbarLength = toolbar.length; - for ( var r = 0; r < toolbar.length; r++ ) { + for ( var r = 0; r < toolbarLength; r++ ) { var toolbarId, toolbarObj = 0, toolbarName, row = toolbar[ r ], + lastToolbarInRow = row !== '/' && ( toolbar[ r + 1 ] === '/' || r == toolbarLength - 1 ), items; // It's better to check if the row object is really // available because it's a common mistake to leave // an extra comma in the toolbar definition // settings, which leads on the editor not loading - // at all in IE. (#3983) + // at all in IE. (http://dev.ckeditor.com/ticket/3983) if ( !row ) continue; @@ -244,7 +242,8 @@ toolbarName = row.name && ( editor.lang.toolbar.toolbarGroups[ row.name ] || row.name ); // Output the toolbar opener. - output.push( '' ); + output.push( '' ); // If a toolbar name is available, send the voice label. toolbarName && output.push( '', toolbarName, '' ); @@ -284,7 +283,7 @@ itemObj.toolbar = toolbarObj; itemObj.onkey = itemKeystroke; - // Fix for #3052: + // Fix for http://dev.ckeditor.com/ticket/3052: // Prevent JAWS from focusing the toolbar after document load. itemObj.onfocus = function() { if ( !editor.toolbox.focusCommandExecuted )