diff options
author | Ismaël Bouya <ismael.bouya@normalesup.org> | 2016-01-25 17:45:33 +0100 |
---|---|---|
committer | Ismaël Bouya <ismael.bouya@normalesup.org> | 2016-01-25 18:00:33 +0100 |
commit | 7adcb81e4f83f98c468889aaa5a85558ba88c770 (patch) | |
tree | 0d6ede733777b29060b48df4afaa2c64bfbae276 /sources/plugins/wsc | |
download | connexionswing-ckeditor-component-7adcb81e4f83f98c468889aaa5a85558ba88c770.tar.gz connexionswing-ckeditor-component-7adcb81e4f83f98c468889aaa5a85558ba88c770.tar.zst connexionswing-ckeditor-component-7adcb81e4f83f98c468889aaa5a85558ba88c770.zip |
Initial commit4.5.6
Diffstat (limited to 'sources/plugins/wsc')
72 files changed, 5211 insertions, 0 deletions
diff --git a/sources/plugins/wsc/LICENSE.md b/sources/plugins/wsc/LICENSE.md new file mode 100644 index 00000000..6096de23 --- /dev/null +++ b/sources/plugins/wsc/LICENSE.md | |||
@@ -0,0 +1,28 @@ | |||
1 | Software License Agreement | ||
2 | ========================== | ||
3 | |||
4 | **CKEditor WSC Plugin** | ||
5 | Copyright © 2012, [CKSource](http://cksource.com) - Frederico Knabben. All rights reserved. | ||
6 | |||
7 | Licensed under the terms of any of the following licenses at your choice: | ||
8 | |||
9 | * GNU General Public License Version 2 or later (the "GPL"): | ||
10 | http://www.gnu.org/licenses/gpl.html | ||
11 | |||
12 | * GNU Lesser General Public License Version 2.1 or later (the "LGPL"): | ||
13 | http://www.gnu.org/licenses/lgpl.html | ||
14 | |||
15 | * Mozilla Public License Version 1.1 or later (the "MPL"): | ||
16 | http://www.mozilla.org/MPL/MPL-1.1.html | ||
17 | |||
18 | You are not required to, but if you want to explicitly declare the license you have chosen to be bound to when using, reproducing, modifying and distributing this software, just include a text file titled "legal.txt" in your version of this software, indicating your license choice. | ||
19 | |||
20 | Sources of Intellectual Property Included in this plugin | ||
21 | -------------------------------------------------------- | ||
22 | |||
23 | Where not otherwise indicated, all plugin content is authored by CKSource engineers and consists of CKSource-owned intellectual property. In some specific instances, the plugin will incorporate work done by developers outside of CKSource with their express permission. | ||
24 | |||
25 | Trademarks | ||
26 | ---------- | ||
27 | |||
28 | CKEditor is a trademark of CKSource - Frederico Knabben. All other brand and product names are trademarks, registered trademarks or service marks of their respective holders. | ||
diff --git a/sources/plugins/wsc/README.md b/sources/plugins/wsc/README.md new file mode 100644 index 00000000..346e2ab1 --- /dev/null +++ b/sources/plugins/wsc/README.md | |||
@@ -0,0 +1,25 @@ | |||
1 | CKEditor WebSpellChecker Plugin | ||
2 | =============================== | ||
3 | |||
4 | This plugin brings Web Spell Checker (WSC) into CKEditor. | ||
5 | |||
6 | WSC is "installation-less", using the web-services of [WebSpellChecker.net](http://www.webspellchecker.net/). It's an out of the box solution. | ||
7 | |||
8 | Installation | ||
9 | ------------ | ||
10 | |||
11 | 1. Clone/copy this repository contents in a new "plugins/wsc" folder in your CKEditor installation. | ||
12 | 2. Enable the "wsc" plugin in the CKEditor configuration file (config.js): | ||
13 | |||
14 | config.extraPlugins = 'wsc'; | ||
15 | |||
16 | That's all. WSC will appear on the editor toolbar and will be ready to use. | ||
17 | |||
18 | License | ||
19 | ------- | ||
20 | |||
21 | Licensed under the terms of any of the following licenses at your choice: [GPL](http://www.gnu.org/licenses/gpl.html), [LGPL](http://www.gnu.org/licenses/lgpl.html) and [MPL](http://www.mozilla.org/MPL/MPL-1.1.html). | ||
22 | |||
23 | See LICENSE.md for more information. | ||
24 | |||
25 | Developed in cooperation with [WebSpellChecker.net](http://www.webspellchecker.net/). | ||
diff --git a/sources/plugins/wsc/dialogs/ciframe.html b/sources/plugins/wsc/dialogs/ciframe.html new file mode 100644 index 00000000..8e4e6bc9 --- /dev/null +++ b/sources/plugins/wsc/dialogs/ciframe.html | |||
@@ -0,0 +1,66 @@ | |||
1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> | ||
2 | <!-- | ||
3 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
4 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
5 | --> | ||
6 | <html> | ||
7 | <head> | ||
8 | <title></title> | ||
9 | <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | ||
10 | <script type="text/javascript"> | ||
11 | |||
12 | function gup( name ) | ||
13 | { | ||
14 | name = name.replace( /[\[]/, '\\\[' ).replace( /[\]]/, '\\\]' ) ; | ||
15 | var regexS = '[\\?&]' + name + '=([^&#]*)' ; | ||
16 | var regex = new RegExp( regexS ) ; | ||
17 | var results = regex.exec( window.location.href ) ; | ||
18 | |||
19 | if ( results ) | ||
20 | return results[ 1 ] ; | ||
21 | else | ||
22 | return '' ; | ||
23 | } | ||
24 | |||
25 | var interval; | ||
26 | |||
27 | function sendData2Master() | ||
28 | { | ||
29 | var destination = window.parent.parent ; | ||
30 | try | ||
31 | { | ||
32 | if ( destination.XDTMaster ) | ||
33 | { | ||
34 | var t = destination.XDTMaster.read( [ gup( 'cmd' ), gup( 'data' ) ] ) ; | ||
35 | window.clearInterval( interval ) ; | ||
36 | } | ||
37 | } | ||
38 | catch (e) {} | ||
39 | } | ||
40 | |||
41 | function OnMessage (event) { | ||
42 | var message = event.data; | ||
43 | var destination = window.parent.parent; | ||
44 | destination.XDTMaster.read( [ 'end', message, 'fpm' ] ) ; | ||
45 | } | ||
46 | |||
47 | function listenPostMessage() { | ||
48 | if (window.addEventListener) { // all browsers except IE before version 9 | ||
49 | window.addEventListener ("message", OnMessage, false); | ||
50 | }else { | ||
51 | if (window.attachEvent) { // IE before version 9 | ||
52 | window.attachEvent("onmessage", OnMessage); | ||
53 | } | ||
54 | } | ||
55 | } | ||
56 | |||
57 | function onLoad() | ||
58 | { | ||
59 | interval = window.setInterval( sendData2Master, 100 ); | ||
60 | listenPostMessage(); | ||
61 | } | ||
62 | |||
63 | </script> | ||
64 | </head> | ||
65 | <body onload="onLoad()"><p></p></body> | ||
66 | </html> | ||
diff --git a/sources/plugins/wsc/dialogs/tmpFrameset.html b/sources/plugins/wsc/dialogs/tmpFrameset.html new file mode 100644 index 00000000..19c7c9cc --- /dev/null +++ b/sources/plugins/wsc/dialogs/tmpFrameset.html | |||
@@ -0,0 +1,52 @@ | |||
1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd"> | ||
2 | <!-- | ||
3 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
4 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
5 | --> | ||
6 | <html> | ||
7 | <head> | ||
8 | <title></title> | ||
9 | <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | ||
10 | <script type="text/javascript"> | ||
11 | |||
12 | function doLoadScript( url ) | ||
13 | { | ||
14 | if ( !url ) | ||
15 | return false ; | ||
16 | |||
17 | var s = document.createElement( "script" ) ; | ||
18 | s.type = "text/javascript" ; | ||
19 | s.src = url ; | ||
20 | document.getElementsByTagName( "head" )[ 0 ].appendChild( s ) ; | ||
21 | |||
22 | return true ; | ||
23 | } | ||
24 | |||
25 | var opener; | ||
26 | function tryLoad() | ||
27 | { | ||
28 | opener = window.parent; | ||
29 | |||
30 | // get access to global parameters | ||
31 | var oParams = window.opener.oldFramesetPageParams; | ||
32 | |||
33 | // make frameset rows string prepare | ||
34 | var sFramesetRows = ( parseInt( oParams.firstframeh, 10 ) || '30') + ",*," + ( parseInt( oParams.thirdframeh, 10 ) || '150' ) + ',0' ; | ||
35 | document.getElementById( 'itFrameset' ).rows = sFramesetRows ; | ||
36 | |||
37 | // dynamic including init frames and crossdomain transport code | ||
38 | // from config sproxy_js_frameset url | ||
39 | var addScriptUrl = oParams.sproxy_js_frameset ; | ||
40 | doLoadScript( addScriptUrl ) ; | ||
41 | } | ||
42 | |||
43 | </script> | ||
44 | </head> | ||
45 | |||
46 | <frameset id="itFrameset" onload="tryLoad();" border="0" rows="30,*,*,0"> | ||
47 | <frame scrolling="no" framespacing="0" frameborder="0" noresize="noresize" marginheight="0" marginwidth="2" src="" name="navbar"></frame> | ||
48 | <frame scrolling="auto" framespacing="0" frameborder="0" noresize="noresize" marginheight="0" marginwidth="0" src="" name="mid"></frame> | ||
49 | <frame scrolling="no" framespacing="0" frameborder="0" noresize="noresize" marginheight="1" marginwidth="1" src="" name="bot"></frame> | ||
50 | <frame scrolling="no" framespacing="0" frameborder="0" noresize="noresize" marginheight="1" marginwidth="1" src="" name="spellsuggestall"></frame> | ||
51 | </frameset> | ||
52 | </html> | ||
diff --git a/sources/plugins/wsc/dialogs/wsc.css b/sources/plugins/wsc/dialogs/wsc.css new file mode 100644 index 00000000..2a622f22 --- /dev/null +++ b/sources/plugins/wsc/dialogs/wsc.css | |||
@@ -0,0 +1,82 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | |||
6 | html, body | ||
7 | { | ||
8 | background-color: transparent; | ||
9 | margin: 0px; | ||
10 | padding: 0px; | ||
11 | } | ||
12 | |||
13 | body | ||
14 | { | ||
15 | padding: 10px; | ||
16 | } | ||
17 | |||
18 | body, td, input, select, textarea | ||
19 | { | ||
20 | font-size: 11px; | ||
21 | font-family: 'Microsoft Sans Serif' , Arial, Helvetica, Verdana; | ||
22 | } | ||
23 | |||
24 | .midtext | ||
25 | { | ||
26 | padding:0px; | ||
27 | margin:10px; | ||
28 | } | ||
29 | |||
30 | .midtext p | ||
31 | { | ||
32 | padding:0px; | ||
33 | margin:10px; | ||
34 | } | ||
35 | |||
36 | .Button | ||
37 | { | ||
38 | border: #737357 1px solid; | ||
39 | color: #3b3b1f; | ||
40 | background-color: #c7c78f; | ||
41 | } | ||
42 | |||
43 | .PopupTabArea | ||
44 | { | ||
45 | color: #737357; | ||
46 | background-color: #e3e3c7; | ||
47 | } | ||
48 | |||
49 | .PopupTitleBorder | ||
50 | { | ||
51 | border-bottom: #d5d59d 1px solid; | ||
52 | } | ||
53 | .PopupTabEmptyArea | ||
54 | { | ||
55 | padding-left: 10px; | ||
56 | border-bottom: #d5d59d 1px solid; | ||
57 | } | ||
58 | |||
59 | .PopupTab, .PopupTabSelected | ||
60 | { | ||
61 | border-right: #d5d59d 1px solid; | ||
62 | border-top: #d5d59d 1px solid; | ||
63 | border-left: #d5d59d 1px solid; | ||
64 | padding: 3px 5px 3px 5px; | ||
65 | color: #737357; | ||
66 | } | ||
67 | |||
68 | .PopupTab | ||
69 | { | ||
70 | margin-top: 1px; | ||
71 | border-bottom: #d5d59d 1px solid; | ||
72 | cursor: pointer; | ||
73 | } | ||
74 | |||
75 | .PopupTabSelected | ||
76 | { | ||
77 | font-weight: bold; | ||
78 | cursor: default; | ||
79 | padding-top: 4px; | ||
80 | border-bottom: #f1f1e3 1px solid; | ||
81 | background-color: #f1f1e3; | ||
82 | } | ||
diff --git a/sources/plugins/wsc/dialogs/wsc.js b/sources/plugins/wsc/dialogs/wsc.js new file mode 100644 index 00000000..eb96af8a --- /dev/null +++ b/sources/plugins/wsc/dialogs/wsc.js | |||
@@ -0,0 +1,3152 @@ | |||
1 | /** | ||
2 | * @license Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | * For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | (function() { | ||
6 | // Create support tools | ||
7 | var appTools = (function(){ | ||
8 | var inited = {}; | ||
9 | |||
10 | var _init = function(handler) { | ||
11 | if (window.addEventListener) { | ||
12 | window.addEventListener('message', handler, false); | ||
13 | } else { | ||
14 | window.attachEvent("onmessage", handler); | ||
15 | } | ||
16 | }; | ||
17 | |||
18 | var unbindHandler = function(handler) { | ||
19 | if (window.removeEventListener) { | ||
20 | window.removeEventListener('message', handler, false); | ||
21 | } else { | ||
22 | window.detachEvent('onmessage', handler); | ||
23 | } | ||
24 | }; | ||
25 | |||
26 | var _sendCmd = function(o) { | ||
27 | var str, | ||
28 | type = Object.prototype.toString, | ||
29 | objObject = "[object Object]", | ||
30 | fn = o.fn || null, | ||
31 | id = o.id || '', | ||
32 | target = o.target || window, | ||
33 | message = o.message || { | ||
34 | 'id': id | ||
35 | }; | ||
36 | |||
37 | if (o.message && type.call(o.message) == objObject) { | ||
38 | (o.message.id) ? o.message.id : o.message.id = id; | ||
39 | message = o.message; | ||
40 | } | ||
41 | |||
42 | str = window.JSON.stringify(message, fn); | ||
43 | target.postMessage(str, '*'); | ||
44 | }; | ||
45 | |||
46 | var _hashCreate = function(o, fn) { | ||
47 | fn = fn || null; | ||
48 | var str = window.JSON.stringify(o, fn); | ||
49 | return str; | ||
50 | }; | ||
51 | |||
52 | var _hashParse = function(str, fn) { | ||
53 | fn = fn || null; | ||
54 | return window.JSON.parse(str, fn); | ||
55 | }; | ||
56 | |||
57 | var setCookie = function(name, value, options) { | ||
58 | options = options || {}; | ||
59 | |||
60 | var expires = options.expires; | ||
61 | |||
62 | if (typeof expires == "number" && expires) { | ||
63 | var d = new Date(); | ||
64 | d.setTime(d.getTime() + expires*1000); | ||
65 | expires = options.expires = d; | ||
66 | } | ||
67 | if (expires && expires.toUTCString) { | ||
68 | options.expires = expires.toUTCString(); | ||
69 | } | ||
70 | |||
71 | value = encodeURIComponent(value); | ||
72 | var updatedCookie = name + "=" + value; | ||
73 | |||
74 | for(var propName in options) { | ||
75 | var propValue = options[propName]; | ||
76 | updatedCookie += "; " + propName; | ||
77 | if (propValue !== true) { | ||
78 | updatedCookie += "=" + propValue; | ||
79 | } | ||
80 | } | ||
81 | document.cookie = updatedCookie; | ||
82 | }; | ||
83 | |||
84 | var getCookie = function(name) { | ||
85 | var matches = document.cookie.match(new RegExp( | ||
86 | "(?:^|; )" + name.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g, '\\$1') + "=([^;]*)" | ||
87 | )); | ||
88 | return matches ? decodeURIComponent(matches[1]) : undefined; | ||
89 | }; | ||
90 | |||
91 | var deleteCookie = function(name) { | ||
92 | setCookie(name, "", { expires: -1 }); | ||
93 | }; | ||
94 | |||
95 | var findFocusable = function(ckEl) { | ||
96 | var result = null, | ||
97 | focusableSelectors = 'a[href], area[href], input, select, textarea, button, *[tabindex], *[contenteditable]'; | ||
98 | |||
99 | if(ckEl) { | ||
100 | result = ckEl.find(focusableSelectors); | ||
101 | } | ||
102 | |||
103 | return result; | ||
104 | }; | ||
105 | |||
106 | var getStyle = function(el, prop) { | ||
107 | if(document.defaultView && document.defaultView.getComputedStyle) { | ||
108 | return document.defaultView.getComputedStyle(el, null)[prop]; | ||
109 | } else if(el.currentStyle) { | ||
110 | return el.currentStyle[prop]; | ||
111 | } else { | ||
112 | return el.style[prop]; | ||
113 | } | ||
114 | }; | ||
115 | |||
116 | var isHidden = function(el) { | ||
117 | return el.offsetWidth === 0 || el.offsetHeight == 0 || getStyle(el, 'display') === 'none'; | ||
118 | }; | ||
119 | |||
120 | var isVisible = function(el) { | ||
121 | return !isHidden(el); | ||
122 | }; | ||
123 | |||
124 | var hasClass = function (obj, cname) { | ||
125 | return !!(obj.className ? obj.className.match(new RegExp('(\\s|^)'+cname+'(\\s|$)')) : false); | ||
126 | }; | ||
127 | |||
128 | return { | ||
129 | postMessage: { | ||
130 | init: _init, | ||
131 | send: _sendCmd, | ||
132 | unbindHandler: unbindHandler | ||
133 | }, | ||
134 | hash: { | ||
135 | create: function() { | ||
136 | |||
137 | }, | ||
138 | |||
139 | parse: function() { | ||
140 | |||
141 | } | ||
142 | }, | ||
143 | cookie: { | ||
144 | set: setCookie, | ||
145 | get: getCookie, | ||
146 | remove: deleteCookie | ||
147 | }, | ||
148 | misc: { | ||
149 | findFocusable: findFocusable, | ||
150 | isVisible: isVisible, | ||
151 | hasClass: hasClass | ||
152 | } | ||
153 | }; | ||
154 | })(); | ||
155 | |||
156 | var NS = NS || {}; | ||
157 | NS.TextAreaNumber = null; | ||
158 | NS.load = true; | ||
159 | NS.cmd = { | ||
160 | "SpellTab": 'spell', | ||
161 | "Thesaurus": 'thes', | ||
162 | "GrammTab": 'grammar' | ||
163 | }; | ||
164 | NS.dialog = null; | ||
165 | NS.optionNode = null; | ||
166 | NS.selectNode = null; | ||
167 | NS.grammerSuggest = null; | ||
168 | NS.textNode = {}; | ||
169 | NS.iframeMain = null; | ||
170 | NS.dataTemp = ''; | ||
171 | NS.div_overlay = null; | ||
172 | NS.textNodeInfo = {}; | ||
173 | NS.selectNode = {}; | ||
174 | NS.selectNodeResponce = {}; | ||
175 | NS.langList = null; | ||
176 | NS.langSelectbox = null; | ||
177 | NS.banner = ''; | ||
178 | NS.show_grammar = null; | ||
179 | NS.div_overlay_no_check = null; | ||
180 | NS.targetFromFrame = {}; | ||
181 | NS.onLoadOverlay = null; | ||
182 | NS.LocalizationComing = {}; | ||
183 | NS.OverlayPlace = null; | ||
184 | NS.sessionid = ''; | ||
185 | NS.LocalizationButton = { | ||
186 | 'ChangeTo_button': { | ||
187 | 'instance' : null, | ||
188 | 'text' : 'Change to', | ||
189 | 'localizationID': 'ChangeTo' | ||
190 | }, | ||
191 | |||
192 | 'ChangeAll': { | ||
193 | 'instance' : null, | ||
194 | 'text' : 'Change All' | ||
195 | }, | ||
196 | |||
197 | 'IgnoreWord': { | ||
198 | 'instance' : null, | ||
199 | 'text' : 'Ignore word' | ||
200 | }, | ||
201 | |||
202 | 'IgnoreAllWords': { | ||
203 | 'instance' : null, | ||
204 | 'text' : 'Ignore all words' | ||
205 | }, | ||
206 | |||
207 | 'Options': { | ||
208 | 'instance' : null, | ||
209 | 'text' : 'Options', | ||
210 | 'optionsDialog': { | ||
211 | 'instance' : null | ||
212 | } | ||
213 | }, | ||
214 | |||
215 | 'AddWord': { | ||
216 | 'instance' : null, | ||
217 | 'text' : 'Add word' | ||
218 | }, | ||
219 | |||
220 | 'FinishChecking_button': { | ||
221 | 'instance' : null, | ||
222 | 'text' : 'Finish Checking', | ||
223 | 'localizationID': 'FinishChecking' | ||
224 | }, | ||
225 | |||
226 | 'FinishChecking_button_block': { | ||
227 | 'instance' : null, | ||
228 | 'text' : 'Finish Checking', | ||
229 | 'localizationID': 'FinishChecking' | ||
230 | } | ||
231 | }; | ||
232 | |||
233 | NS.LocalizationLabel = { | ||
234 | 'ChangeTo_label': { | ||
235 | 'instance' : null, | ||
236 | 'text' : 'Change to', | ||
237 | 'localizationID': 'ChangeTo' | ||
238 | }, | ||
239 | |||
240 | 'Suggestions': { | ||
241 | 'instance' : null, | ||
242 | 'text' : 'Suggestions' | ||
243 | }, | ||
244 | |||
245 | 'Categories': { | ||
246 | 'instance' : null, | ||
247 | 'text' : 'Categories' | ||
248 | }, | ||
249 | |||
250 | 'Synonyms': { | ||
251 | 'instance' : null, | ||
252 | 'text' : 'Synonyms' | ||
253 | } | ||
254 | }; | ||
255 | |||
256 | var SetLocalizationButton = function(obj) { | ||
257 | var el, localizationID; | ||
258 | |||
259 | for(var i in obj) { | ||
260 | el = NS.dialog.getContentElement(NS.dialog._.currentTabId, i); | ||
261 | |||
262 | if(el) { | ||
263 | el = el.getElement(); | ||
264 | } else { | ||
265 | el = obj[i].instance.getElement().getFirst() || obj[i].instance.getElement(); | ||
266 | } | ||
267 | |||
268 | localizationID = obj[i].localizationID || i; | ||
269 | el.setText(NS.LocalizationComing[localizationID]); | ||
270 | } | ||
271 | }; | ||
272 | |||
273 | var SetLocalizationLabel = function(obj) { | ||
274 | var el, localizationID; | ||
275 | |||
276 | for(var i in obj) { | ||
277 | el = NS.dialog.getContentElement(NS.dialog._.currentTabId, i); | ||
278 | |||
279 | if(!el) { | ||
280 | el = obj[i].instance; | ||
281 | } | ||
282 | |||
283 | if(el.setLabel) { | ||
284 | localizationID = obj[i].localizationID || i; | ||
285 | el.setLabel(NS.LocalizationComing[localizationID] + ':'); | ||
286 | } | ||
287 | } | ||
288 | }; | ||
289 | var OptionsConfirm = function(state) { | ||
290 | if (state) { | ||
291 | nameNode.setValue(''); | ||
292 | } | ||
293 | }; | ||
294 | |||
295 | var iframeOnload = false; | ||
296 | var nameNode, selectNode, frameId; | ||
297 | |||
298 | NS.framesetHtml = function(tab) { | ||
299 | var str = '<iframe id=' + NS.iframeNumber + '_' + tab + ' frameborder="0" allowtransparency="1" style="width:100%;border: 1px solid #AEB3B9;overflow: auto;background:#fff; border-radius: 3px;"></iframe>'; | ||
300 | return str; | ||
301 | }; | ||
302 | |||
303 | NS.setIframe = function(that, nameTab) { | ||
304 | var iframe, | ||
305 | str = NS.framesetHtml(nameTab), | ||
306 | iframeId = NS.iframeNumber + '_' + nameTab, | ||
307 | // tmp.html from wsc/dialogs | ||
308 | iframeInnerHtml = | ||
309 | '<!DOCTYPE html>' + | ||
310 | '<html>' + | ||
311 | '<head>' + | ||
312 | '<meta charset="UTF-8">' + | ||
313 | '<title>iframe</title>' + | ||
314 | |||
315 | '<style>' + | ||
316 | 'html,body{' + | ||
317 | 'margin: 0;' + | ||
318 | 'height: 100%;' + | ||
319 | 'font: 13px/1.555 "Trebuchet MS", sans-serif;' + | ||
320 | '}' + | ||
321 | 'a{' + | ||
322 | 'color: #888;' + | ||
323 | 'font-weight: bold;' + | ||
324 | 'text-decoration: none;' + | ||
325 | 'border-bottom: 1px solid #888;' + | ||
326 | '}' + | ||
327 | '.main-box {' + | ||
328 | 'color:#252525;' + | ||
329 | 'padding: 3px 5px;' + | ||
330 | 'text-align: justify;' + | ||
331 | '}' + | ||
332 | '.main-box p{margin: 0 0 14px;}' + | ||
333 | '.main-box .cerr{' + | ||
334 | 'color: #f00000;' + | ||
335 | 'border-bottom-color: #f00000;' + | ||
336 | '}' + | ||
337 | '</style>' + | ||
338 | '</head>' + | ||
339 | '<body>' + | ||
340 | '<div id="content" class="main-box"></div>' + | ||
341 | '<iframe src="" frameborder="0" id="spelltext" name="spelltext" style="display:none; width: 100%" ></iframe>' + | ||
342 | '<iframe src="" frameborder="0" id="loadsuggestfirst" name="loadsuggestfirst" style="display:none; width: 100%" ></iframe>' + | ||
343 | '<iframe src="" frameborder="0" id="loadspellsuggestall" name="loadspellsuggestall" style="display:none; width: 100%" ></iframe>' + | ||
344 | '<iframe src="" frameborder="0" id="loadOptionsForm" name="loadOptionsForm" style="display:none; width: 100%" ></iframe>' + | ||
345 | '<script>' + | ||
346 | '(function(window) {' + | ||
347 | // Constructor Manager PostMessage | ||
348 | |||
349 | 'var ManagerPostMessage = function() {' + | ||
350 | 'var _init = function(handler) {' + | ||
351 | 'if (document.addEventListener) {' + | ||
352 | 'window.addEventListener("message", handler, false);' + | ||
353 | '} else {' + | ||
354 | 'window.attachEvent("onmessage", handler);' + | ||
355 | '};' + | ||
356 | '};' + | ||
357 | 'var _sendCmd = function(o) {' + | ||
358 | 'var str,' + | ||
359 | 'type = Object.prototype.toString,' + | ||
360 | 'fn = o.fn || null,' + | ||
361 | 'id = o.id || "",' + | ||
362 | 'target = o.target || window,' + | ||
363 | 'message = o.message || { "id": id };' + | ||
364 | |||
365 | 'if (o.message && type.call(o.message) == "[object Object]") {' + | ||
366 | '(o.message["id"]) ? o.message["id"] : o.message["id"] = id;' + | ||
367 | 'message = o.message;' + | ||
368 | '};' + | ||
369 | |||
370 | 'str = JSON.stringify(message, fn);' + | ||
371 | 'target.postMessage(str, "*");' + | ||
372 | '};' + | ||
373 | |||
374 | 'return {' + | ||
375 | 'init: _init,' + | ||
376 | 'send: _sendCmd' + | ||
377 | '};' + | ||
378 | '};' + | ||
379 | |||
380 | 'var manageMessageTmp = new ManagerPostMessage;' + | ||
381 | |||
382 | |||
383 | 'var appString = (function(){' + | ||
384 | 'var spell = parent.CKEDITOR.config.wsc.DefaultParams.scriptPath;' + | ||
385 | 'var serverUrl = parent.CKEDITOR.config.wsc.DefaultParams.serviceHost;' + | ||
386 | 'return serverUrl + spell;' + | ||
387 | '})();' + | ||
388 | |||
389 | 'function loadScript(src, callback) {' + | ||
390 | 'var scriptTag = document.createElement("script");' + | ||
391 | 'scriptTag.type = "text/javascript";' + | ||
392 | 'callback ? callback : callback = function() {};' + | ||
393 | 'if(scriptTag.readyState) {' + | ||
394 | //IE | ||
395 | 'scriptTag.onreadystatechange = function() {' + | ||
396 | 'if (scriptTag.readyState == "loaded" ||' + | ||
397 | 'scriptTag.readyState == "complete") {' + | ||
398 | 'scriptTag.onreadystatechange = null;' + | ||
399 | 'setTimeout(function(){scriptTag.parentNode.removeChild(scriptTag)},1);' + | ||
400 | 'callback();' + | ||
401 | '}' + | ||
402 | '};' + | ||
403 | '}else{' + | ||
404 | //Others | ||
405 | 'scriptTag.onload = function() {' + | ||
406 | 'setTimeout(function(){scriptTag.parentNode.removeChild(scriptTag)},1);' + | ||
407 | 'callback();' + | ||
408 | '};' + | ||
409 | '};' + | ||
410 | 'scriptTag.src = src;' + | ||
411 | 'document.getElementsByTagName("head")[0].appendChild(scriptTag);' + | ||
412 | '};' + | ||
413 | |||
414 | |||
415 | 'window.onload = function(){' + | ||
416 | 'loadScript(appString, function(){' + | ||
417 | 'manageMessageTmp.send({' + | ||
418 | '"id": "iframeOnload",' + | ||
419 | '"target": window.parent' + | ||
420 | '});' + | ||
421 | '});' + | ||
422 | '}' + | ||
423 | '})(this);' + | ||
424 | '</script>' + | ||
425 | '</body>' + | ||
426 | '</html>'; | ||
427 | |||
428 | that.getElement().setHtml(str); | ||
429 | iframe = document.getElementById(iframeId); | ||
430 | iframe = (iframe.contentWindow) ? iframe.contentWindow : (iframe.contentDocument.document) ? iframe.contentDocument.document : iframe.contentDocument; | ||
431 | iframe.document.open(); | ||
432 | iframe.document.write(iframeInnerHtml); | ||
433 | iframe.document.close(); | ||
434 | }; | ||
435 | |||
436 | NS.setCurrentIframe = function(currentTab) { | ||
437 | var that = NS.dialog._.contents[currentTab].Content, | ||
438 | tabID, iframe; | ||
439 | |||
440 | NS.setIframe(that, currentTab); | ||
441 | |||
442 | }; | ||
443 | |||
444 | NS.setHeightBannerFrame = function() { | ||
445 | var height = "90px", | ||
446 | bannerPlaceSpellTab = NS.dialog.getContentElement('SpellTab', 'banner').getElement(), | ||
447 | bannerPlaceGrammTab = NS.dialog.getContentElement('GrammTab', 'banner').getElement(), | ||
448 | bannerPlaceThesaurus = NS.dialog.getContentElement('Thesaurus', 'banner').getElement(); | ||
449 | |||
450 | bannerPlaceSpellTab.setStyle('height', height); | ||
451 | bannerPlaceGrammTab.setStyle('height', height); | ||
452 | bannerPlaceThesaurus.setStyle('height', height); | ||
453 | }; | ||
454 | |||
455 | NS.setHeightFrame = function() { | ||
456 | var currentTab = NS.dialog._.currentTabId, | ||
457 | tabID = NS.iframeNumber + '_' + currentTab, | ||
458 | iframe = document.getElementById(tabID); | ||
459 | |||
460 | iframe.style.height = '240px'; | ||
461 | }; | ||
462 | |||
463 | NS.sendData = function(scope) { | ||
464 | var currentTab = scope._.currentTabId, | ||
465 | that = scope._.contents[currentTab].Content, | ||
466 | tabID, iframe; | ||
467 | |||
468 | NS.previousTab = currentTab; | ||
469 | NS.setIframe(that, currentTab); | ||
470 | |||
471 | var loadNewTab = function(event) { | ||
472 | currentTab = scope._.currentTabId; | ||
473 | event = event || window.event; | ||
474 | |||
475 | if (!event.data.getTarget().is('a')) { | ||
476 | return; | ||
477 | } | ||
478 | |||
479 | if(currentTab === NS.previousTab) return; | ||
480 | NS.previousTab = currentTab; | ||
481 | |||
482 | that = scope._.contents[currentTab].Content; | ||
483 | tabID = NS.iframeNumber + '_' + currentTab; | ||
484 | NS.div_overlay.setEnable(); | ||
485 | |||
486 | if (!that.getElement().getChildCount()) { | ||
487 | NS.setIframe(that, currentTab); | ||
488 | iframe = document.getElementById(tabID); | ||
489 | NS.targetFromFrame[tabID] = iframe.contentWindow; | ||
490 | } else { | ||
491 | sendData(NS.targetFromFrame[tabID], NS.cmd[currentTab]); | ||
492 | } | ||
493 | }; | ||
494 | |||
495 | scope.parts.tabs.removeListener('click', loadNewTab); | ||
496 | scope.parts.tabs.on('click', loadNewTab); | ||
497 | }; | ||
498 | |||
499 | NS.buildSelectLang = function(aId) { | ||
500 | var divContainer = new CKEDITOR.dom.element('div'), | ||
501 | selectContainer = new CKEDITOR.dom.element('select'), | ||
502 | id = "wscLang" + aId; | ||
503 | |||
504 | divContainer.addClass("cke_dialog_ui_input_select"); | ||
505 | divContainer.setAttribute("role", "presentation"); | ||
506 | divContainer.setStyles({ | ||
507 | 'height': 'auto', | ||
508 | 'position': 'absolute', | ||
509 | 'right': '0', | ||
510 | 'top': '-1px', | ||
511 | 'width': '160px', | ||
512 | 'white-space': 'normal' | ||
513 | }); | ||
514 | |||
515 | selectContainer.setAttribute('id', id); | ||
516 | selectContainer.addClass("cke_dialog_ui_input_select"); | ||
517 | selectContainer.setStyles({ | ||
518 | 'width': '160px' | ||
519 | }); | ||
520 | var currentTabId = NS.dialog._.currentTabId, | ||
521 | frameId = NS.iframeNumber + '_' + currentTabId; | ||
522 | |||
523 | divContainer.append(selectContainer); | ||
524 | |||
525 | return divContainer; | ||
526 | |||
527 | }; | ||
528 | |||
529 | NS.buildOptionLang = function(key, aId) { | ||
530 | var id = "wscLang" + aId; | ||
531 | var select = document.getElementById(id), | ||
532 | fragment = document.createDocumentFragment(), | ||
533 | create_option, txt_option, | ||
534 | sort = []; | ||
535 | |||
536 | if(select.options.length === 0) { | ||
537 | for (var lang in key) { | ||
538 | sort.push([lang, key[lang]]); | ||
539 | } | ||
540 | sort.sort(); | ||
541 | |||
542 | for (var i = 0; i < sort.length; i++) { | ||
543 | create_option=document.createElement("option"); | ||
544 | create_option.setAttribute("value", sort[i][1]); | ||
545 | txt_option = document.createTextNode(sort[i][0]); | ||
546 | create_option.appendChild(txt_option); | ||
547 | |||
548 | fragment.appendChild(create_option); | ||
549 | } | ||
550 | select.appendChild(fragment); | ||
551 | } | ||
552 | |||
553 | // make appropriate option selected according to current selected language | ||
554 | for (var j = 0; j < select.options.length; j++) { | ||
555 | if (select.options[j].value == NS.selectingLang) { | ||
556 | select.options[j].selected = "selected"; | ||
557 | } | ||
558 | } | ||
559 | }; | ||
560 | |||
561 | NS.buildOptionSynonyms = function(key) { | ||
562 | var syn = NS.selectNodeResponce[key]; | ||
563 | |||
564 | var select = getSelect( NS.selectNode['Synonyms'] ); | ||
565 | |||
566 | NS.selectNode['Synonyms'].clear(); | ||
567 | |||
568 | for (var i = 0; i < syn.length; i++) { | ||
569 | var option = document.createElement('option'); | ||
570 | option.text = syn[i]; | ||
571 | option.value = syn[i]; | ||
572 | |||
573 | select.$.add(option, i); | ||
574 | } | ||
575 | |||
576 | NS.selectNode['Synonyms'].getInputElement().$.firstChild.selected = true; | ||
577 | NS.textNode['Thesaurus'].setValue(NS.selectNode['Synonyms'].getInputElement().getValue()); | ||
578 | }; | ||
579 | |||
580 | var setBannerInPlace = function(htmlBanner) { | ||
581 | var findBannerPlace = NS.dialog.getContentElement(NS.dialog._.currentTabId, 'banner').getElement(); | ||
582 | findBannerPlace.setHtml(htmlBanner); | ||
583 | |||
584 | }; | ||
585 | |||
586 | var overlayBlock = function overlayBlock(opt) { | ||
587 | var progress = opt.progress || "", | ||
588 | doc = document, | ||
589 | target = opt.target || doc.body, | ||
590 | overlayId = opt.id || "overlayBlock", | ||
591 | opacity = opt.opacity || "0.9", | ||
592 | background = opt.background || "#f1f1f1", | ||
593 | getOverlay = doc.getElementById(overlayId), | ||
594 | thisOverlay = getOverlay || doc.createElement("div"); | ||
595 | |||
596 | thisOverlay.style.cssText = "position: absolute;" + | ||
597 | "top:30px;" + | ||
598 | "bottom:41px;" + | ||
599 | "left:1px;" + | ||
600 | "right:1px;" + | ||
601 | "z-index: 10020;" + | ||
602 | "padding:0;" + | ||
603 | "margin:0;" + | ||
604 | "background:" + background + ";" + | ||
605 | "opacity: " + opacity + ";" + | ||
606 | "filter: alpha(opacity=" + opacity * 100 + ");" + | ||
607 | "display: none;"; | ||
608 | thisOverlay.id = overlayId; | ||
609 | |||
610 | if (!getOverlay) { | ||
611 | target.appendChild(thisOverlay); | ||
612 | } | ||
613 | |||
614 | return { | ||
615 | setDisable: function() { | ||
616 | thisOverlay.style.display = "none"; | ||
617 | }, | ||
618 | setEnable: function() { | ||
619 | thisOverlay.style.display = "block"; | ||
620 | } | ||
621 | }; | ||
622 | }; | ||
623 | |||
624 | var buildRadioInputs = function(key, value, check) { | ||
625 | var divContainer = new CKEDITOR.dom.element('div'), | ||
626 | radioButton = new CKEDITOR.dom.element('input'), | ||
627 | radioLabel = new CKEDITOR.dom.element('label'), | ||
628 | id = "wscGrammerSuggest" + key + "_" + value; | ||
629 | |||
630 | divContainer.addClass("cke_dialog_ui_input_radio"); | ||
631 | divContainer.setAttribute("role", "presentation"); | ||
632 | divContainer.setStyles({ | ||
633 | width: "97%", | ||
634 | padding: "5px", | ||
635 | 'white-space': 'normal' | ||
636 | }); | ||
637 | |||
638 | radioButton.setAttributes({ | ||
639 | type: "radio", | ||
640 | value: value, | ||
641 | name: 'wscGrammerSuggest', | ||
642 | id: id | ||
643 | }); | ||
644 | radioButton.setStyles({ | ||
645 | "float":"left" | ||
646 | }); | ||
647 | |||
648 | radioButton.on("click", function(data) { | ||
649 | NS.textNode['GrammTab'].setValue(data.sender.getValue()); | ||
650 | }); | ||
651 | |||
652 | (check) ? radioButton.setAttribute("checked", true) : false; | ||
653 | |||
654 | radioButton.addClass("cke_dialog_ui_radio_input"); | ||
655 | |||
656 | radioLabel.appendText(key); | ||
657 | radioLabel.setAttribute("for", id); | ||
658 | radioLabel.setStyles({ | ||
659 | 'display': "block", | ||
660 | 'line-height': '16px', | ||
661 | 'margin-left': '18px', | ||
662 | 'white-space': 'normal' | ||
663 | }); | ||
664 | |||
665 | divContainer.append(radioButton); | ||
666 | divContainer.append(radioLabel); | ||
667 | |||
668 | return divContainer; | ||
669 | }; | ||
670 | |||
671 | var statusGrammarTab = function(aState) { //#19221 | ||
672 | aState = aState || 'true'; | ||
673 | if(aState !== null && aState == 'false'){ | ||
674 | hideGrammTab(); | ||
675 | } | ||
676 | }; | ||
677 | |||
678 | var langConstructor = function(lang) { | ||
679 | var langSelectBox = new __constructLangSelectbox(lang), | ||
680 | selectId = "wscLang" + NS.dialog.getParentEditor().name, | ||
681 | selectContainer = document.getElementById(selectId), | ||
682 | currentTabId = NS.dialog._.currentTabId, | ||
683 | frameId = NS.iframeNumber + '_' + currentTabId; | ||
684 | |||
685 | NS.buildOptionLang(langSelectBox.setLangList, NS.dialog.getParentEditor().name); | ||
686 | tabView[langSelectBox.getCurrentLangGroup(NS.selectingLang)].onShow(); | ||
687 | statusGrammarTab(NS.show_grammar); | ||
688 | |||
689 | selectContainer.onchange = function(e) { | ||
690 | var langGroup = langSelectBox.getCurrentLangGroup(this.value), | ||
691 | currentTabId = NS.dialog._.currentTabId, | ||
692 | cmd; | ||
693 | |||
694 | e = e || window.event; | ||
695 | |||
696 | tabView[langGroup].onShow(); | ||
697 | statusGrammarTab(NS.show_grammar); | ||
698 | NS.div_overlay.setEnable(); | ||
699 | NS.selectingLang = this.value; | ||
700 | |||
701 | // get command for current opened tan | ||
702 | cmd = NS.cmd[currentTabId]; | ||
703 | // check whether current tab can be opened after language switching | ||
704 | if(!langGroup || !tabView[langGroup] || !tabView[langGroup].allowedTabCommands[cmd]) { | ||
705 | // if not so - set default tab to open after reload | ||
706 | cmd = tabView[langGroup].defaultTabCommand; | ||
707 | } | ||
708 | |||
709 | for(var key in NS.cmd) { | ||
710 | if(NS.cmd[key] == cmd) { | ||
711 | NS.previousTab = key; | ||
712 | break; | ||
713 | } | ||
714 | } | ||
715 | |||
716 | appTools.postMessage.send({ | ||
717 | 'message': { | ||
718 | 'changeLang': NS.selectingLang, | ||
719 | 'text': NS.dataTemp, | ||
720 | 'cmd': cmd | ||
721 | }, | ||
722 | 'target': NS.targetFromFrame[frameId], | ||
723 | 'id': 'selectionLang_outer__page' | ||
724 | }); | ||
725 | }; | ||
726 | |||
727 | }; | ||
728 | |||
729 | var disableButtonSuggest = function(word) { | ||
730 | var changeToButton, changeAllButton, | ||
731 | styleDisable = function(instanceButton) { | ||
732 | var button = NS.dialog.getContentElement(NS.dialog._.currentTabId, instanceButton) || NS.LocalizationButton[instanceButton].instance; | ||
733 | button.getElement().hasClass('cke_disabled') ? button.getElement().setStyle('color', '#a0a0a0') : button.disable(); | ||
734 | }, | ||
735 | styleEnable = function(instanceButton) { | ||
736 | var button = NS.dialog.getContentElement(NS.dialog._.currentTabId, instanceButton) || NS.LocalizationButton[instanceButton].instance; | ||
737 | button.enable(); | ||
738 | button.getElement().setStyle('color', '#333'); | ||
739 | }; | ||
740 | |||
741 | if (word == 'no_any_suggestions') { | ||
742 | word = 'No suggestions'; | ||
743 | |||
744 | changeToButton = NS.dialog.getContentElement(NS.dialog._.currentTabId, 'ChangeTo_button') || NS.LocalizationButton['ChangeTo_button'].instance; | ||
745 | changeToButton.disable(); | ||
746 | changeAllButton = NS.dialog.getContentElement(NS.dialog._.currentTabId, 'ChangeAll') || NS.LocalizationButton['ChangeAll'].instance; | ||
747 | changeAllButton.disable(); | ||
748 | |||
749 | styleDisable('ChangeTo_button'); | ||
750 | styleDisable('ChangeAll'); | ||
751 | |||
752 | return word; | ||
753 | } else { | ||
754 | styleEnable('ChangeTo_button'); | ||
755 | styleEnable('ChangeAll'); | ||
756 | |||
757 | return word; | ||
758 | } | ||
759 | }; | ||
760 | |||
761 | function getSelect( obj ) { | ||
762 | if ( obj && obj.domId && obj.getInputElement().$ ) | ||
763 | return obj.getInputElement(); | ||
764 | else if ( obj && obj.$ ) | ||
765 | return obj; | ||
766 | return false; | ||
767 | } | ||
768 | |||
769 | var handlerId = { | ||
770 | iframeOnload: function(response) { | ||
771 | NS.div_overlay.setEnable(); | ||
772 | iframeOnload = true; | ||
773 | var currentTab = NS.dialog._.currentTabId, | ||
774 | tabId = NS.iframeNumber + '_' + currentTab; | ||
775 | sendData(NS.targetFromFrame[tabId], NS.cmd[currentTab]); | ||
776 | }, | ||
777 | |||
778 | suggestlist: function(response) { | ||
779 | delete response.id; | ||
780 | NS.div_overlay_no_check.setDisable(); | ||
781 | hideCurrentFinishChecking(); | ||
782 | langConstructor(NS.langList); | ||
783 | |||
784 | var word = disableButtonSuggest(response.word), | ||
785 | suggestionsList = ''; | ||
786 | |||
787 | if (word instanceof Array) { | ||
788 | word = response.word[0]; | ||
789 | } | ||
790 | |||
791 | word = word.split(','); | ||
792 | suggestionsList = word; | ||
793 | |||
794 | NS.textNode['SpellTab'].setValue(suggestionsList[0]); | ||
795 | |||
796 | var select = getSelect( selectNode ); | ||
797 | |||
798 | selectNode.clear(); | ||
799 | |||
800 | for (var i = 0; i < suggestionsList.length; i++) { | ||
801 | var option = document.createElement('option'); | ||
802 | option.text = suggestionsList[i]; | ||
803 | option.value = suggestionsList[i]; | ||
804 | |||
805 | select.$.add(option, i); | ||
806 | } | ||
807 | |||
808 | showCurrentTabs(); | ||
809 | NS.div_overlay.setDisable(); | ||
810 | |||
811 | }, | ||
812 | |||
813 | grammerSuggest: function(response) { | ||
814 | delete response.id; | ||
815 | delete response.mocklangs; | ||
816 | |||
817 | hideCurrentFinishChecking(); | ||
818 | langConstructor(NS.langList); // Show select language for this command CKEDITOR.config.wsc_cmd | ||
819 | var firstSuggestValue = response.grammSuggest[0];// ? firstSuggestValue = response.grammSuggest[0] : firstSuggestValue = 'No suggestion for this words'; | ||
820 | NS.grammerSuggest.getElement().setHtml(''); | ||
821 | |||
822 | NS.textNode['GrammTab'].reset(); | ||
823 | NS.textNode['GrammTab'].setValue(firstSuggestValue); | ||
824 | |||
825 | NS.textNodeInfo['GrammTab'].getElement().setHtml(''); | ||
826 | NS.textNodeInfo['GrammTab'].getElement().setText(response.info); | ||
827 | |||
828 | var arr = response.grammSuggest, | ||
829 | len = arr.length, | ||
830 | check = true; | ||
831 | |||
832 | for (var i = 0; i < len; i++) { | ||
833 | NS.grammerSuggest.getElement().append(buildRadioInputs(arr[i], arr[i], check)); | ||
834 | check = false; | ||
835 | } | ||
836 | |||
837 | showCurrentTabs(); | ||
838 | NS.div_overlay.setDisable(); | ||
839 | }, | ||
840 | |||
841 | thesaurusSuggest: function(response) { | ||
842 | delete response.id; | ||
843 | delete response.mocklangs; | ||
844 | |||
845 | hideCurrentFinishChecking(); | ||
846 | langConstructor(NS.langList); // Show select language for this command CKEDITOR.config.wsc_cmd | ||
847 | NS.selectNodeResponce = response; | ||
848 | |||
849 | NS.textNode['Thesaurus'].reset(); | ||
850 | |||
851 | var select = getSelect( NS.selectNode['Categories'] ), | ||
852 | count = 0; | ||
853 | |||
854 | NS.selectNode['Categories'].clear(); | ||
855 | |||
856 | for (var i in response) { | ||
857 | |||
858 | var option = document.createElement('option'); | ||
859 | option.text = i; | ||
860 | option.value = i; | ||
861 | |||
862 | select.$.add(option, count); | ||
863 | count++ | ||
864 | } | ||
865 | |||
866 | var synKey = NS.selectNode['Categories'].getInputElement().getChildren().$[0].value; | ||
867 | NS.selectNode['Categories'].getInputElement().getChildren().$[0].selected = true; | ||
868 | NS.buildOptionSynonyms(synKey); | ||
869 | |||
870 | showCurrentTabs(); | ||
871 | NS.div_overlay.setDisable(); | ||
872 | count = 0; | ||
873 | }, | ||
874 | finish: function(response) { | ||
875 | delete response.id; | ||
876 | |||
877 | hideCurrentTabs(); | ||
878 | showCurrentFinishChecking(); | ||
879 | NS.div_overlay.setDisable(); | ||
880 | }, | ||
881 | settext: function(response) { | ||
882 | delete response.id; | ||
883 | |||
884 | var command = NS.dialog.getParentEditor().getCommand( 'checkspell' ), | ||
885 | editor = NS.dialog.getParentEditor(); | ||
886 | |||
887 | //set local storage for synchronization before scayt reinit | ||
888 | if (editor.scayt && editor.wsc.isSsrvSame) { | ||
889 | var wscUDN = editor.wsc.udn; | ||
890 | |||
891 | if (!wscUDN) { | ||
892 | editor.wsc.DataStorage.setData('scayt_user_dictionary_name', ''); | ||
893 | } else { | ||
894 | editor.wsc.DataStorage.setData('scayt_user_dictionary_name', wscUDN); | ||
895 | } | ||
896 | } | ||
897 | |||
898 | |||
899 | try { | ||
900 | editor.focus(); | ||
901 | } catch(e) {} | ||
902 | |||
903 | editor.setData(response.text, function(){ | ||
904 | NS.dataTemp = ''; | ||
905 | editor.unlockSelection(); | ||
906 | editor.fire('saveSnapshot'); | ||
907 | NS.dialog.hide(); | ||
908 | }); | ||
909 | |||
910 | }, | ||
911 | ReplaceText: function(response) { | ||
912 | |||
913 | delete response.id; | ||
914 | NS.div_overlay.setEnable(); | ||
915 | |||
916 | NS.dataTemp = response.text; | ||
917 | NS.selectingLang = response.currentLang; | ||
918 | |||
919 | if (response.cmd = 'spell' && response.len !== '0' && response.len) { | ||
920 | NS.div_overlay.setDisable(); | ||
921 | } else { | ||
922 | window.setTimeout(function() { | ||
923 | try { | ||
924 | NS.div_overlay.setDisable(); | ||
925 | } catch(e) {} | ||
926 | }, 500); | ||
927 | } | ||
928 | |||
929 | SetLocalizationButton(NS.LocalizationButton); | ||
930 | SetLocalizationLabel(NS.LocalizationLabel); | ||
931 | |||
932 | }, | ||
933 | options_checkbox_send: function(response) { | ||
934 | delete response.id; | ||
935 | |||
936 | var obj = { | ||
937 | 'osp': appTools.cookie.get('osp'), | ||
938 | 'udn': appTools.cookie.get('udn'), | ||
939 | 'cust_dic_ids': NS.cust_dic_ids | ||
940 | }; | ||
941 | |||
942 | var currentTabId = NS.dialog._.currentTabId, | ||
943 | frameId = NS.iframeNumber + '_' + currentTabId; | ||
944 | |||
945 | appTools.postMessage.send({ | ||
946 | 'message': obj, | ||
947 | 'target': NS.targetFromFrame[frameId], | ||
948 | 'id': 'options_outer__page' | ||
949 | }); | ||
950 | }, | ||
951 | |||
952 | getOptions: function(response) { | ||
953 | var udn = response.DefOptions.udn; | ||
954 | NS.LocalizationComing = response.DefOptions.localizationButtonsAndText; | ||
955 | NS.show_grammar = response.show_grammar; | ||
956 | NS.langList = response.lang; | ||
957 | NS.bnr = response.bannerId; | ||
958 | NS.sessionid = response.sessionid; | ||
959 | if (response.bannerId) { | ||
960 | NS.setHeightBannerFrame(); | ||
961 | setBannerInPlace(response.banner); | ||
962 | } else { | ||
963 | NS.setHeightFrame(); | ||
964 | } | ||
965 | |||
966 | if (udn == 'undefined') { | ||
967 | if (NS.userDictionaryName) { | ||
968 | udn = NS.userDictionaryName; | ||
969 | |||
970 | var obj = { | ||
971 | 'osp': appTools.cookie.get('osp'), | ||
972 | 'udn': NS.userDictionaryName, | ||
973 | 'cust_dic_ids': NS.cust_dic_ids, | ||
974 | 'id': 'options_dic_send', | ||
975 | 'udnCmd': 'create' | ||
976 | }; | ||
977 | |||
978 | appTools.postMessage.send({ | ||
979 | 'message': obj, | ||
980 | 'target': NS.targetFromFrame[frameId] | ||
981 | }); | ||
982 | |||
983 | } else{ | ||
984 | udn = ''; | ||
985 | } | ||
986 | } | ||
987 | |||
988 | appTools.cookie.set('osp', response.DefOptions.osp); | ||
989 | appTools.cookie.set('udn', udn); | ||
990 | appTools.cookie.set('cust_dic_ids', response.DefOptions.cust_dic_ids); | ||
991 | |||
992 | appTools.postMessage.send({ | ||
993 | 'id': 'giveOptions' | ||
994 | }); | ||
995 | }, | ||
996 | |||
997 | options_dic_send: function(response) { | ||
998 | |||
999 | var obj = { | ||
1000 | 'osp': appTools.cookie.get('osp'), | ||
1001 | 'udn': appTools.cookie.get('udn'), | ||
1002 | 'cust_dic_ids': NS.cust_dic_ids, | ||
1003 | 'id': 'options_dic_send', | ||
1004 | 'udnCmd': appTools.cookie.get('udnCmd') | ||
1005 | }; | ||
1006 | |||
1007 | var currentTabId = NS.dialog._.currentTabId, | ||
1008 | frameId = NS.iframeNumber + '_' + currentTabId; | ||
1009 | |||
1010 | appTools.postMessage.send({ | ||
1011 | 'message': obj, | ||
1012 | 'target': NS.targetFromFrame[frameId] | ||
1013 | }); | ||
1014 | }, | ||
1015 | data: function(response) { | ||
1016 | delete response.id; | ||
1017 | }, | ||
1018 | |||
1019 | giveOptions: function() { | ||
1020 | |||
1021 | }, | ||
1022 | |||
1023 | setOptionsConfirmF:function() { | ||
1024 | OptionsConfirm(false); | ||
1025 | }, | ||
1026 | |||
1027 | setOptionsConfirmT:function() { | ||
1028 | OptionsConfirm(true); | ||
1029 | }, | ||
1030 | |||
1031 | clickBusy: function() { | ||
1032 | NS.div_overlay.setEnable(); | ||
1033 | }, | ||
1034 | |||
1035 | suggestAllCame: function() { | ||
1036 | NS.div_overlay.setDisable(); | ||
1037 | NS.div_overlay_no_check.setDisable(); | ||
1038 | }, | ||
1039 | |||
1040 | TextCorrect: function() { | ||
1041 | langConstructor(NS.langList); | ||
1042 | } | ||
1043 | |||
1044 | }; | ||
1045 | |||
1046 | var handlerIncomingData = function(event) { | ||
1047 | event = event || window.event; | ||
1048 | var response = window.JSON.parse(event.data); | ||
1049 | |||
1050 | if(response && response.id) { | ||
1051 | handlerId[response.id](response); | ||
1052 | } | ||
1053 | }; | ||
1054 | |||
1055 | var handlerButtonOptions = function(event) { | ||
1056 | event = event || window.event; | ||
1057 | |||
1058 | var currentTabId = NS.dialog._.currentTabId, | ||
1059 | frameId = NS.iframeNumber + '_' + currentTabId; | ||
1060 | |||
1061 | appTools.postMessage.send({ | ||
1062 | 'message': { | ||
1063 | 'cmd': 'Options' | ||
1064 | }, | ||
1065 | 'target': NS.targetFromFrame[frameId], | ||
1066 | 'id': 'cmd' | ||
1067 | }); | ||
1068 | |||
1069 | }; | ||
1070 | |||
1071 | var sendData = function(frameTarget, cmd, sendText, reset_suggest) { | ||
1072 | cmd = cmd || CKEDITOR.config.wsc_cmd; | ||
1073 | reset_suggest = reset_suggest || false; | ||
1074 | sendText = sendText || NS.dataTemp; | ||
1075 | |||
1076 | appTools.postMessage.send({ | ||
1077 | 'message': { | ||
1078 | 'customerId': NS.wsc_customerId, | ||
1079 | 'text': sendText, | ||
1080 | 'txt_ctrl': NS.TextAreaNumber, | ||
1081 | 'cmd': cmd, | ||
1082 | 'cust_dic_ids': NS.cust_dic_ids, | ||
1083 | 'udn': NS.userDictionaryName, | ||
1084 | 'slang': NS.selectingLang, | ||
1085 | 'reset_suggest': reset_suggest, | ||
1086 | 'sessionid': NS.sessionid | ||
1087 | }, | ||
1088 | 'target': frameTarget, | ||
1089 | 'id': 'data_outer__page' | ||
1090 | }); | ||
1091 | |||
1092 | NS.div_overlay.setEnable(); | ||
1093 | }; | ||
1094 | |||
1095 | var tabView = { | ||
1096 | "superset": { | ||
1097 | onShow: function() { | ||
1098 | showThesaurusTab(); | ||
1099 | showGrammTab(); | ||
1100 | showSpellTab(); | ||
1101 | }, | ||
1102 | allowedTabCommands: { | ||
1103 | "spell": true, | ||
1104 | "grammar": true, | ||
1105 | "thes": true | ||
1106 | }, | ||
1107 | defaultTabCommand: "spell" | ||
1108 | }, | ||
1109 | "usual": { | ||
1110 | onShow: function() { | ||
1111 | hideThesaurusTab(); | ||
1112 | hideGrammTab(); | ||
1113 | showSpellTab(); | ||
1114 | }, | ||
1115 | allowedTabCommands: { | ||
1116 | "spell": true | ||
1117 | }, | ||
1118 | defaultTabCommand: "spell" | ||
1119 | }, | ||
1120 | "rtl": { | ||
1121 | onShow: function() { | ||
1122 | hideThesaurusTab(); | ||
1123 | hideGrammTab(); | ||
1124 | showSpellTab(); | ||
1125 | }, | ||
1126 | allowedTabCommands: { | ||
1127 | "spell": true | ||
1128 | }, | ||
1129 | defaultTabCommand: "spell" | ||
1130 | }, | ||
1131 | "spellgrammar": { | ||
1132 | onShow: function() { | ||
1133 | hideThesaurusTab(); | ||
1134 | showGrammTab(); | ||
1135 | showSpellTab(); | ||
1136 | }, | ||
1137 | allowedTabCommands: { | ||
1138 | "spell": true, | ||
1139 | "grammar": true | ||
1140 | }, | ||
1141 | defaultTabCommand: "spell" | ||
1142 | }, | ||
1143 | "spellthes": { | ||
1144 | onShow: function() { | ||
1145 | showThesaurusTab(); | ||
1146 | hideGrammTab(); | ||
1147 | showSpellTab(); | ||
1148 | }, | ||
1149 | allowedTabCommands: { | ||
1150 | "spell": true, | ||
1151 | "thes": true | ||
1152 | }, | ||
1153 | defaultTabCommand: "spell" | ||
1154 | } | ||
1155 | }; | ||
1156 | |||
1157 | var showFirstTab = function(scope) { | ||
1158 | var cmdManger = function(cmdView) { | ||
1159 | var obj = {}; | ||
1160 | var _getCmd = function(cmd) { | ||
1161 | for (var tabId in cmdView) { | ||
1162 | obj[cmdView[tabId]] = tabId; | ||
1163 | } | ||
1164 | return obj[cmd]; | ||
1165 | }; | ||
1166 | return { | ||
1167 | getCmdByTab: _getCmd | ||
1168 | }; | ||
1169 | }; | ||
1170 | |||
1171 | var cmdM = new cmdManger(NS.cmd), | ||
1172 | tabToOpen = cmdM.getCmdByTab(CKEDITOR.config.wsc_cmd); | ||
1173 | |||
1174 | scope.selectPage(tabToOpen); | ||
1175 | NS.sendData(scope); | ||
1176 | }; | ||
1177 | |||
1178 | var showThesaurusTab = function() { | ||
1179 | NS.dialog.showPage('Thesaurus'); | ||
1180 | }; | ||
1181 | |||
1182 | var hideThesaurusTab = function() { | ||
1183 | NS.dialog.hidePage('Thesaurus'); | ||
1184 | }; | ||
1185 | |||
1186 | var showGrammTab = function() { | ||
1187 | NS.dialog.showPage('GrammTab'); | ||
1188 | }; | ||
1189 | |||
1190 | var hideGrammTab = function() { | ||
1191 | NS.dialog.hidePage('GrammTab'); | ||
1192 | }; | ||
1193 | |||
1194 | var showSpellTab = function() { | ||
1195 | NS.dialog.showPage('SpellTab'); | ||
1196 | }; | ||
1197 | |||
1198 | var hideSpellTab = function() { | ||
1199 | NS.dialog.hidePage('SpellTab'); | ||
1200 | }; | ||
1201 | |||
1202 | var showCurrentTabs = function() { | ||
1203 | var target = NS.dialog.getContentElement(NS.dialog._.currentTabId, 'bottomGroup').getElement(); | ||
1204 | |||
1205 | target.removeStyle('display'); | ||
1206 | target.removeStyle('position'); | ||
1207 | target.removeStyle('left'); | ||
1208 | |||
1209 | target.show(); | ||
1210 | }; | ||
1211 | |||
1212 | var hideCurrentTabs = function() { | ||
1213 | var target = NS.dialog.getContentElement(NS.dialog._.currentTabId, 'bottomGroup').getElement(), | ||
1214 | activeElement = document.activeElement, | ||
1215 | focusableElements; | ||
1216 | |||
1217 | target.setStyles({ | ||
1218 | display: 'block', | ||
1219 | position: 'absolute', | ||
1220 | left: '-9999px' | ||
1221 | }); | ||
1222 | |||
1223 | setTimeout(function() { | ||
1224 | target.removeStyle('display'); | ||
1225 | target.removeStyle('position'); | ||
1226 | target.removeStyle('left'); | ||
1227 | |||
1228 | target.hide(); | ||
1229 | |||
1230 | NS.dialog._.editor.focusManager.currentActive.focusNext(); | ||
1231 | |||
1232 | focusableElements = appTools.misc.findFocusable(NS.dialog.parts.contents); | ||
1233 | if(!appTools.misc.hasClass(activeElement, 'cke_dialog_tab') && !appTools.misc.hasClass(activeElement, 'cke_dialog_contents_body') && appTools.misc.isVisible(activeElement)) { | ||
1234 | try { | ||
1235 | activeElement.focus(); | ||
1236 | } catch(e) {} | ||
1237 | } else { | ||
1238 | for(var i = 0, tmpCkEl; i < focusableElements.count(); i++) { | ||
1239 | tmpCkEl = focusableElements.getItem(i); | ||
1240 | if(appTools.misc.isVisible(tmpCkEl.$)) { | ||
1241 | try { | ||
1242 | tmpCkEl.$.focus(); | ||
1243 | } catch(e) {} | ||
1244 | |||
1245 | break; | ||
1246 | } | ||
1247 | } | ||
1248 | } | ||
1249 | }, 0); | ||
1250 | }; | ||
1251 | |||
1252 | var showCurrentFinishChecking = function() { | ||
1253 | var target = NS.dialog.getContentElement(NS.dialog._.currentTabId, 'BlockFinishChecking').getElement(); | ||
1254 | |||
1255 | target.removeStyle('display'); | ||
1256 | target.removeStyle('position'); | ||
1257 | target.removeStyle('left'); | ||
1258 | |||
1259 | target.show(); | ||
1260 | }; | ||
1261 | |||
1262 | var hideCurrentFinishChecking = function() { | ||
1263 | var target = NS.dialog.getContentElement(NS.dialog._.currentTabId, 'BlockFinishChecking').getElement(), | ||
1264 | activeElement = document.activeElement, | ||
1265 | focusableElements; | ||
1266 | |||
1267 | target.setStyles({ | ||
1268 | display: 'block', | ||
1269 | position: 'absolute', | ||
1270 | left: '-9999px' | ||
1271 | }); | ||
1272 | |||
1273 | setTimeout(function() { | ||
1274 | target.removeStyle('display'); | ||
1275 | target.removeStyle('position'); | ||
1276 | target.removeStyle('left'); | ||
1277 | |||
1278 | target.hide(); | ||
1279 | |||
1280 | NS.dialog._.editor.focusManager.currentActive.focusNext(); | ||
1281 | |||
1282 | focusableElements = appTools.misc.findFocusable(NS.dialog.parts.contents); | ||
1283 | if(!appTools.misc.hasClass(activeElement, 'cke_dialog_tab') && !appTools.misc.hasClass(activeElement, 'cke_dialog_contents_body') && appTools.misc.isVisible(activeElement)) { | ||
1284 | try { | ||
1285 | activeElement.focus(); | ||
1286 | } catch(e) {} | ||
1287 | } else { | ||
1288 | for(var i = 0, tmpCkEl; i < focusableElements.count(); i++) { | ||
1289 | tmpCkEl = focusableElements.getItem(i); | ||
1290 | if(appTools.misc.isVisible(tmpCkEl.$)) { | ||
1291 | try { | ||
1292 | tmpCkEl.$.focus(); | ||
1293 | } catch(e) {} | ||
1294 | |||
1295 | break; | ||
1296 | } | ||
1297 | } | ||
1298 | } | ||
1299 | }, 0); | ||
1300 | }; | ||
1301 | |||
1302 | |||
1303 | |||
1304 | function __constructLangSelectbox(languageGroup) { | ||
1305 | if( !languageGroup ) { throw "Languages-by-groups list are required for construct selectbox"; } | ||
1306 | |||
1307 | var that = this, | ||
1308 | o_arr = [], | ||
1309 | priorLang ="en_US", | ||
1310 | priorLangTitle = "", | ||
1311 | currLang = NS.selectingLang; | ||
1312 | |||
1313 | for ( var group in languageGroup){ | ||
1314 | for ( var langCode in languageGroup[group]){ | ||
1315 | var langName = languageGroup[group][langCode]; | ||
1316 | if ( langName == priorLang ) { | ||
1317 | priorLangTitle = langName; | ||
1318 | } else { | ||
1319 | o_arr.push( langName ); | ||
1320 | } | ||
1321 | } | ||
1322 | } | ||
1323 | |||
1324 | o_arr.sort(); | ||
1325 | if(priorLangTitle) { | ||
1326 | o_arr.unshift( priorLangTitle ); | ||
1327 | } | ||
1328 | |||
1329 | var searchGroup = function ( code ){ | ||
1330 | for ( var group in languageGroup){ | ||
1331 | for ( var langCode in languageGroup[group]){ | ||
1332 | if ( langCode.toUpperCase() === code.toUpperCase() ) { | ||
1333 | return group; | ||
1334 | } | ||
1335 | } | ||
1336 | } | ||
1337 | return ""; | ||
1338 | }; | ||
1339 | |||
1340 | var _setLangList = function() { | ||
1341 | var langList = {}, | ||
1342 | langArray = []; | ||
1343 | for (var group in languageGroup) { | ||
1344 | for ( var langCode in languageGroup[group]){ | ||
1345 | langList[languageGroup[group][langCode]] = langCode; | ||
1346 | } | ||
1347 | } | ||
1348 | return langList; | ||
1349 | }; | ||
1350 | |||
1351 | var _return = { | ||
1352 | getCurrentLangGroup: function(code) { | ||
1353 | return searchGroup(code); | ||
1354 | }, | ||
1355 | setLangList: _setLangList() | ||
1356 | }; | ||
1357 | |||
1358 | return _return; | ||
1359 | } | ||
1360 | |||
1361 | CKEDITOR.dialog.add('checkspell', function(editor) { | ||
1362 | var handlerButtons = function(event) { | ||
1363 | event = event || window.event; | ||
1364 | |||
1365 | // because in chrome and safary document.activeElement returns <body> tag. We need to signal that clicked element is active | ||
1366 | this.getElement().focus(); | ||
1367 | |||
1368 | NS.div_overlay.setEnable(); | ||
1369 | var currentTabId = NS.dialog._.currentTabId, | ||
1370 | frameId = NS.iframeNumber + '_' + currentTabId, | ||
1371 | new_word = NS.textNode[currentTabId].getValue(), | ||
1372 | cmd = this.getElement().getAttribute("title-cmd"); | ||
1373 | |||
1374 | appTools.postMessage.send({ | ||
1375 | 'message': { | ||
1376 | 'cmd': cmd, | ||
1377 | 'tabId': currentTabId, | ||
1378 | 'new_word': new_word | ||
1379 | }, | ||
1380 | 'target': NS.targetFromFrame[frameId], | ||
1381 | 'id': 'cmd_outer__page' | ||
1382 | }); | ||
1383 | |||
1384 | if (cmd == 'ChangeTo' || cmd == 'ChangeAll') { | ||
1385 | editor.fire('saveSnapshot'); | ||
1386 | } | ||
1387 | |||
1388 | if (cmd == 'FinishChecking') { | ||
1389 | editor.config.wsc_onFinish.call(CKEDITOR.document.getWindow().getFrame()); | ||
1390 | } | ||
1391 | |||
1392 | }, | ||
1393 | constraints = { | ||
1394 | minWidth: 560, | ||
1395 | minHeight: 444 | ||
1396 | }; | ||
1397 | |||
1398 | function initView(dialog) { | ||
1399 | var newViewSettings = { | ||
1400 | left: parseInt(editor.config.wsc_left, 10), | ||
1401 | top: parseInt(editor.config.wsc_top, 10), | ||
1402 | width: parseInt(editor.config.wsc_width, 10), | ||
1403 | height: parseInt(editor.config.wsc_height, 10) | ||
1404 | }, | ||
1405 | viewSize = CKEDITOR.document.getWindow().getViewPaneSize(), | ||
1406 | currentPosition = dialog.getPosition(), | ||
1407 | currentSize = dialog.getSize(), | ||
1408 | savePosition = 0; | ||
1409 | |||
1410 | if(!dialog._.resized) { | ||
1411 | var wrapperHeight = currentSize.height - dialog.parts.contents.getSize('height', !(CKEDITOR.env.gecko || CKEDITOR.env.opera || CKEDITOR.env.ie && CKEDITOR.env.quirks)), | ||
1412 | wrapperWidth = currentSize.width - dialog.parts.contents.getSize('width', 1); | ||
1413 | |||
1414 | if(newViewSettings.width < constraints.minWidth || isNaN(newViewSettings.width)) { | ||
1415 | newViewSettings.width = constraints.minWidth; | ||
1416 | } | ||
1417 | if(newViewSettings.width > viewSize.width - wrapperWidth) { | ||
1418 | newViewSettings.width = viewSize.width - wrapperWidth; | ||
1419 | } | ||
1420 | |||
1421 | if(newViewSettings.height < constraints.minHeight || isNaN(newViewSettings.height)) { | ||
1422 | newViewSettings.height = constraints.minHeight; | ||
1423 | } | ||
1424 | if(newViewSettings.height > viewSize.height - wrapperHeight) { | ||
1425 | newViewSettings.height = viewSize.height - wrapperHeight; | ||
1426 | } | ||
1427 | |||
1428 | currentSize.width = newViewSettings.width + wrapperWidth; | ||
1429 | currentSize.height = newViewSettings.height + wrapperHeight; | ||
1430 | |||
1431 | dialog._.fromResizeEvent = false; | ||
1432 | dialog.resize(newViewSettings.width, newViewSettings.height); | ||
1433 | setTimeout(function() { | ||
1434 | dialog._.fromResizeEvent = false; | ||
1435 | CKEDITOR.dialog.fire('resize', { | ||
1436 | dialog: dialog, | ||
1437 | width: newViewSettings.width, | ||
1438 | height: newViewSettings.height | ||
1439 | }, editor); | ||
1440 | }, 300); | ||
1441 | } | ||
1442 | |||
1443 | if(!dialog._.moved) { | ||
1444 | savePosition = isNaN(newViewSettings.left) && isNaN(newViewSettings.top) ? 0 : 1; | ||
1445 | |||
1446 | if(isNaN(newViewSettings.left)) { | ||
1447 | newViewSettings.left = (viewSize.width - currentSize.width) / 2; | ||
1448 | } | ||
1449 | if(newViewSettings.left < 0) { | ||
1450 | newViewSettings.left = 0; | ||
1451 | } | ||
1452 | if(newViewSettings.left > viewSize.width - currentSize.width) { | ||
1453 | newViewSettings.left = viewSize.width - currentSize.width; | ||
1454 | } | ||
1455 | |||
1456 | if(isNaN(newViewSettings.top)) { | ||
1457 | newViewSettings.top = (viewSize.height - currentSize.height) / 2; | ||
1458 | } | ||
1459 | if(newViewSettings.top < 0) { | ||
1460 | newViewSettings.top = 0; | ||
1461 | } | ||
1462 | if(newViewSettings.top > viewSize.height - currentSize.height) { | ||
1463 | newViewSettings.top = viewSize.height - currentSize.height; | ||
1464 | } | ||
1465 | |||
1466 | dialog.move(newViewSettings.left, newViewSettings.top, savePosition); | ||
1467 | } | ||
1468 | } | ||
1469 | |||
1470 | function createWscObjectForUdAndUdnSyncrhonization() { | ||
1471 | editor.wsc = {}; | ||
1472 | |||
1473 | //DataStorage object for cookies and localStorage manipulation | ||
1474 | (function( object ) { | ||
1475 | 'use strict'; | ||
1476 | |||
1477 | var DataTypeManager = { | ||
1478 | separator: '<$>', | ||
1479 | getDataType: function(value) { | ||
1480 | var type; | ||
1481 | |||
1482 | if(typeof value === 'undefined') { | ||
1483 | type = 'undefined'; | ||
1484 | } else if(value === null) { | ||
1485 | type = 'null'; | ||
1486 | } else { | ||
1487 | type = Object.prototype.toString.call(value).slice(8, -1); | ||
1488 | } | ||
1489 | return type; | ||
1490 | }, | ||
1491 | convertDataToString: function(value) { | ||
1492 | var str, | ||
1493 | type = this.getDataType(value).toLowerCase(); | ||
1494 | |||
1495 | str = type + this.separator + value; | ||
1496 | return str; | ||
1497 | }, | ||
1498 | // get value type and convert value due to type, since all stored values are String | ||
1499 | restoreDataFromString: function(str) { | ||
1500 | var value = str, | ||
1501 | type, | ||
1502 | separatorStartIndex; | ||
1503 | |||
1504 | // @TODO: remove this line much later. Support of old format for options | ||
1505 | str = this.backCompatibility(str); | ||
1506 | |||
1507 | if(typeof str === 'string') { | ||
1508 | separatorStartIndex = str.indexOf(this.separator); | ||
1509 | type = str.substring(0, separatorStartIndex); | ||
1510 | value = str.substring(separatorStartIndex + this.separator.length); | ||
1511 | |||
1512 | switch(type) { | ||
1513 | case 'boolean': | ||
1514 | value = value === 'true'; | ||
1515 | break; | ||
1516 | case 'number': | ||
1517 | value = parseFloat(value); | ||
1518 | break; | ||
1519 | // we assume that we will store string values only, due to performance | ||
1520 | case 'array': | ||
1521 | value = value === '' ? [] : value.split(','); | ||
1522 | break; | ||
1523 | case 'null': | ||
1524 | value = null; | ||
1525 | break; | ||
1526 | case 'undefined': | ||
1527 | value = undefined; | ||
1528 | break; | ||
1529 | } | ||
1530 | } | ||
1531 | return value; | ||
1532 | }, | ||
1533 | // old data type support | ||
1534 | // here we trying to convert data from old format into new | ||
1535 | // @TODO: remove this function much later | ||
1536 | backCompatibility: function(str) { | ||
1537 | var convertedStr = str, | ||
1538 | value, | ||
1539 | separatorStartIndex; | ||
1540 | |||
1541 | if(typeof str === 'string') { | ||
1542 | separatorStartIndex = str.indexOf(this.separator); | ||
1543 | // is it old format? | ||
1544 | if(separatorStartIndex < 0) { | ||
1545 | // try to get number from string | ||
1546 | value = parseFloat(str); | ||
1547 | // is it not a number? | ||
1548 | if(isNaN(value)) { | ||
1549 | // yes, this is not a number. Lets check is this is an array "[comma,separated,values]" | ||
1550 | if((str[0] === '[') && (str[str.length - 1] === ']')) { | ||
1551 | // this is an array. Lets remove brackets symbols and extract the words | ||
1552 | str = str.replace('[', ''); | ||
1553 | str = str.replace(']', ''); | ||
1554 | if(str === '') { | ||
1555 | value = []; | ||
1556 | } else { | ||
1557 | value = str.split(','); | ||
1558 | } | ||
1559 | // value = str === '[]' ? [] : str.split(','); | ||
1560 | } else if(str === 'true' || str === 'false') { | ||
1561 | // this is boolean value | ||
1562 | value = str === 'true'; | ||
1563 | } else { | ||
1564 | // this is string | ||
1565 | value = str; | ||
1566 | } | ||
1567 | } | ||
1568 | |||
1569 | convertedStr = this.convertDataToString(value); | ||
1570 | } | ||
1571 | } | ||
1572 | |||
1573 | return convertedStr; | ||
1574 | } | ||
1575 | }; | ||
1576 | |||
1577 | var LocalStorage = { | ||
1578 | |||
1579 | get: function( key ) { | ||
1580 | var value = DataTypeManager.restoreDataFromString( window.localStorage.getItem(key) ); | ||
1581 | return value; | ||
1582 | }, | ||
1583 | |||
1584 | set: function( key, value ) { | ||
1585 | var _value = DataTypeManager.convertDataToString( value ); | ||
1586 | window.localStorage.setItem( key, _value ); | ||
1587 | }, | ||
1588 | |||
1589 | del: function( key ) { | ||
1590 | window.localStorage.removeItem( key ); | ||
1591 | }, | ||
1592 | |||
1593 | clear: function() { | ||
1594 | window.localStorage.clear(); | ||
1595 | } | ||
1596 | }; | ||
1597 | |||
1598 | var CookiesStorage = { | ||
1599 | |||
1600 | expiration: (function() { | ||
1601 | return 60 * 60 * 24 * 366; | ||
1602 | }()), | ||
1603 | |||
1604 | get: function(key) { | ||
1605 | var value = DataTypeManager.restoreDataFromString(this.getCookie(key)); | ||
1606 | return value; | ||
1607 | }, | ||
1608 | |||
1609 | set: function(key, value) { | ||
1610 | var _value = DataTypeManager.convertDataToString(value); | ||
1611 | this.setCookie(key, _value, {expires: this.expiration}); | ||
1612 | }, | ||
1613 | |||
1614 | del: function(key) { | ||
1615 | this.deleteCookie(key); | ||
1616 | }, | ||
1617 | |||
1618 | getCookie: function(name) { | ||
1619 | var matches = document.cookie.match(new RegExp("(?:^|; )" + name.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g, '\\$1') + "=([^;]*)")); | ||
1620 | return matches ? decodeURIComponent(matches[1]) : undefined; | ||
1621 | }, | ||
1622 | |||
1623 | setCookie: function(name, value, props) { | ||
1624 | props = props || {}; | ||
1625 | var exp = props.expires; | ||
1626 | |||
1627 | if (typeof exp === "number" && exp) { | ||
1628 | var d = new Date(); | ||
1629 | |||
1630 | d.setTime(d.getTime() + exp * 1000); | ||
1631 | exp = props.expires = d; | ||
1632 | } | ||
1633 | |||
1634 | if(exp && exp.toUTCString) { | ||
1635 | props.expires = exp.toUTCString(); | ||
1636 | } | ||
1637 | |||
1638 | value = encodeURIComponent(value); | ||
1639 | var updatedCookie = name + "=" + value; | ||
1640 | |||
1641 | for(var propName in props) { | ||
1642 | var propValue = props[propName]; | ||
1643 | |||
1644 | updatedCookie += "; " + propName; | ||
1645 | |||
1646 | if(propValue !== true) { | ||
1647 | updatedCookie += "=" + propValue; | ||
1648 | } | ||
1649 | } | ||
1650 | |||
1651 | document.cookie = updatedCookie; | ||
1652 | }, | ||
1653 | |||
1654 | deleteCookie: function(name) { | ||
1655 | this.setCookie(name, null, {expires: -1}); | ||
1656 | }, | ||
1657 | |||
1658 | // delete all cookies | ||
1659 | clear: function() { | ||
1660 | var cookies = document.cookie.split(";"); | ||
1661 | |||
1662 | for (var i = 0; i < cookies.length; i++) { | ||
1663 | var cookie = cookies[i]; | ||
1664 | var eqPos = cookie.indexOf("="); | ||
1665 | var name = eqPos > -1 ? cookie.substr(0, eqPos) : cookie; | ||
1666 | |||
1667 | this.deleteCookie(name); | ||
1668 | } | ||
1669 | } | ||
1670 | }; | ||
1671 | |||
1672 | var strategy = window.localStorage ? LocalStorage : CookiesStorage; | ||
1673 | |||
1674 | var DataStorage = { | ||
1675 | // Get data within storage for key | ||
1676 | getData: function( key ) { | ||
1677 | return strategy.get( key ); | ||
1678 | }, | ||
1679 | |||
1680 | // Set data within storage | ||
1681 | setData: function( key, value ) { | ||
1682 | strategy.set( key, value ); | ||
1683 | }, | ||
1684 | |||
1685 | // Delete data within storage for key | ||
1686 | deleteData: function( key ) { | ||
1687 | strategy.del( key ); | ||
1688 | }, | ||
1689 | |||
1690 | // Clear storage | ||
1691 | clear: function() { | ||
1692 | strategy.clear(); | ||
1693 | } | ||
1694 | }; | ||
1695 | |||
1696 | // Static Module of Storage Data in the localStorage. | ||
1697 | object.DataStorage = DataStorage; | ||
1698 | }( editor.wsc )); | ||
1699 | |||
1700 | editor.wsc.operationWithUDN = function(command, UDName) { | ||
1701 | var obj = { | ||
1702 | 'udn': UDName, | ||
1703 | 'id': 'operationWithUDN', | ||
1704 | 'udnCmd': command | ||
1705 | }; | ||
1706 | var currentTabId = NS.dialog._.currentTabId, | ||
1707 | frameId = NS.iframeNumber + '_' + currentTabId; | ||
1708 | |||
1709 | appTools.postMessage.send({ | ||
1710 | 'message': obj, | ||
1711 | 'target': NS.targetFromFrame[frameId] | ||
1712 | }); | ||
1713 | }; | ||
1714 | editor.wsc.getLocalStorageUDN = function() { | ||
1715 | var udn = editor.wsc.DataStorage.getData('scayt_user_dictionary_name'); | ||
1716 | |||
1717 | if (!udn) { | ||
1718 | return; | ||
1719 | } | ||
1720 | |||
1721 | return udn; | ||
1722 | }; | ||
1723 | editor.wsc.getLocalStorageUD = function() { | ||
1724 | var ud = editor.wsc.DataStorage.getData('scayt_user_dictionary'); | ||
1725 | |||
1726 | if (!ud) { | ||
1727 | return; | ||
1728 | } | ||
1729 | |||
1730 | return ud; | ||
1731 | }; | ||
1732 | editor.wsc.addWords = function(words, callback) { | ||
1733 | var url = editor.config.wsc.DefaultParams.serviceHost + editor.config.wsc.DefaultParams.ssrvHost + | ||
1734 | '?cmd=dictionary&format=json&' + | ||
1735 | 'customerid=1%3AncttD3-fIoSf2-huzwE4-Y5muI2-mD0Tt-kG9Wz-UEDFC-tYu243-1Uq474-d9Z2l3&' + | ||
1736 | 'action=addword&word='+ words + '&callback=toString&synchronization=true', | ||
1737 | script = document.createElement('script'); | ||
1738 | |||
1739 | script['type'] = 'text/javascript'; | ||
1740 | script['src'] = url; | ||
1741 | document.getElementsByTagName("head")[0].appendChild(script); | ||
1742 | |||
1743 | //chrome, firefox, safari | ||
1744 | script.onload = callback; | ||
1745 | |||
1746 | //IE | ||
1747 | script.onreadystatechange = function() { | ||
1748 | if (this.readyState === 'loaded') { | ||
1749 | callback(); | ||
1750 | } | ||
1751 | }; | ||
1752 | }; | ||
1753 | editor.wsc.cgiOrigin = function() { | ||
1754 | var wscServiceHostString = editor.config.wsc.DefaultParams.serviceHost, | ||
1755 | wscServiceHostArray = wscServiceHostString.split('/'), | ||
1756 | cgiOrigin = wscServiceHostArray[0] + '//' + wscServiceHostArray[2]; | ||
1757 | |||
1758 | return cgiOrigin; | ||
1759 | }; | ||
1760 | editor.wsc.isSsrvSame = false; | ||
1761 | } | ||
1762 | |||
1763 | return { | ||
1764 | title: editor.config.wsc_dialogTitle || editor.lang.wsc.title, | ||
1765 | minWidth: constraints.minWidth, | ||
1766 | minHeight: constraints.minHeight, | ||
1767 | buttons: [CKEDITOR.dialog.cancelButton], | ||
1768 | onLoad: function() { | ||
1769 | NS.dialog = this; | ||
1770 | hideThesaurusTab(); | ||
1771 | hideGrammTab(); | ||
1772 | showSpellTab(); | ||
1773 | |||
1774 | //creating wsc object for UD synchronization between wsc and scayt | ||
1775 | if (editor.plugins.scayt) { | ||
1776 | createWscObjectForUdAndUdnSyncrhonization(); | ||
1777 | } | ||
1778 | }, | ||
1779 | onShow: function() { | ||
1780 | NS.dialog = this; | ||
1781 | |||
1782 | editor.lockSelection(editor.getSelection()); | ||
1783 | |||
1784 | NS.TextAreaNumber = 'cke_textarea_' + editor.name; | ||
1785 | appTools.postMessage.init(handlerIncomingData); | ||
1786 | NS.dataTemp = editor.getData(); | ||
1787 | //NS.div_overlay.setDisable(); | ||
1788 | NS.OverlayPlace = NS.dialog.parts.tabs.getParent().$; | ||
1789 | if(CKEDITOR && CKEDITOR.config){ | ||
1790 | NS.wsc_customerId = editor.config.wsc_customerId; | ||
1791 | NS.cust_dic_ids = editor.config.wsc_customDictionaryIds; | ||
1792 | NS.userDictionaryName = editor.config.wsc_userDictionaryName; | ||
1793 | NS.defaultLanguage = CKEDITOR.config.defaultLanguage; | ||
1794 | var protocol = document.location.protocol == "file:" ? "http:" : document.location.protocol; | ||
1795 | var wscCoreUrl = editor.config.wsc_customLoaderScript || ( protocol + '//loader.webspellchecker.net/sproxy_fck/sproxy.php?plugin=fck2&customerid=' + NS.wsc_customerId + '&cmd=script&doc=wsc&schema=22'); | ||
1796 | } else { | ||
1797 | NS.dialog.hide(); | ||
1798 | return; | ||
1799 | } | ||
1800 | |||
1801 | initView(this); | ||
1802 | |||
1803 | CKEDITOR.scriptLoader.load(wscCoreUrl, function(success) { | ||
1804 | if(CKEDITOR.config && CKEDITOR.config.wsc && CKEDITOR.config.wsc.DefaultParams){ | ||
1805 | NS.serverLocationHash = CKEDITOR.config.wsc.DefaultParams.serviceHost; | ||
1806 | NS.logotype = CKEDITOR.config.wsc.DefaultParams.logoPath; | ||
1807 | NS.loadIcon = CKEDITOR.config.wsc.DefaultParams.iconPath; | ||
1808 | NS.loadIconEmptyEditor = CKEDITOR.config.wsc.DefaultParams.iconPathEmptyEditor; | ||
1809 | NS.LangComparer = new CKEDITOR.config.wsc.DefaultParams._SP_FCK_LangCompare(); | ||
1810 | }else{ | ||
1811 | NS.serverLocationHash = DefaultParams.serviceHost; | ||
1812 | NS.logotype = DefaultParams.logoPath; | ||
1813 | NS.loadIcon = DefaultParams.iconPath; | ||
1814 | NS.loadIconEmptyEditor = DefaultParams.iconPathEmptyEditor; | ||
1815 | NS.LangComparer = new _SP_FCK_LangCompare(); | ||
1816 | } | ||
1817 | |||
1818 | NS.pluginPath = CKEDITOR.getUrl(editor.plugins.wsc.path); | ||
1819 | NS.iframeNumber = NS.TextAreaNumber; | ||
1820 | NS.templatePath = NS.pluginPath + 'dialogs/tmp.html'; | ||
1821 | NS.LangComparer.setDefaulLangCode( NS.defaultLanguage ); | ||
1822 | NS.currentLang = editor.config.wsc_lang || NS.LangComparer.getSPLangCode( editor.langCode ) || 'en_US'; | ||
1823 | NS.selectingLang = NS.currentLang; | ||
1824 | NS.div_overlay = new overlayBlock({ | ||
1825 | opacity: "1", | ||
1826 | background: "#fff url(" + NS.loadIcon + ") no-repeat 50% 50%", | ||
1827 | target: NS.OverlayPlace | ||
1828 | |||
1829 | }); | ||
1830 | |||
1831 | var number_ck = NS.dialog.parts.tabs.getId(), | ||
1832 | dialogPartsTab = CKEDITOR.document.getById(number_ck); | ||
1833 | |||
1834 | dialogPartsTab.setStyle('width', '97%'); | ||
1835 | if (!dialogPartsTab.getElementsByTag('DIV').count()){ | ||
1836 | dialogPartsTab.append(NS.buildSelectLang(NS.dialog.getParentEditor().name)); | ||
1837 | } | ||
1838 | |||
1839 | NS.div_overlay_no_check = new overlayBlock({ | ||
1840 | opacity: "1", | ||
1841 | id: 'no_check_over', | ||
1842 | background: "#fff url(" + NS.loadIconEmptyEditor + ") no-repeat 50% 50%", | ||
1843 | target: NS.OverlayPlace | ||
1844 | }); | ||
1845 | |||
1846 | if (success) { | ||
1847 | showFirstTab(NS.dialog); | ||
1848 | NS.dialog.setupContent(NS.dialog); | ||
1849 | } | ||
1850 | |||
1851 | if (editor.plugins.scayt) { | ||
1852 | //is ssrv.cgi path for WSC and scayt same | ||
1853 | editor.wsc.isSsrvSame = (function() { | ||
1854 | var wscSsrvWholePath, | ||
1855 | wscServiceHost = CKEDITOR.config.wsc.DefaultParams.serviceHost.replace('lf/22/js/../../../', '').split('//')[1], | ||
1856 | wscSsrvHost = CKEDITOR.config.wsc.DefaultParams.ssrvHost, | ||
1857 | scaytSsrvWholePath, | ||
1858 | scaytSsrvProtocol, | ||
1859 | scaytSsrvHost, | ||
1860 | scaytSsrvPath, | ||
1861 | |||
1862 | scaytSrcUrl = editor.config.scayt_srcUrl, | ||
1863 | scaytSsrvSrcUrlSsrvProtocol, | ||
1864 | scaytSsrvSrcUrlSsrvHost, | ||
1865 | scaytSsrvSrcUrlSsrvPath, | ||
1866 | |||
1867 | scaytBasePath, | ||
1868 | scaytBasePathSsrvProtocol, | ||
1869 | scaytBasePathSsrvHost, | ||
1870 | scaytBasePathSsrvPath; | ||
1871 | |||
1872 | if (window.SCAYT && window.SCAYT.CKSCAYT) { | ||
1873 | scaytBasePath = SCAYT.CKSCAYT.prototype.basePath; | ||
1874 | scaytBasePathSsrvProtocol = scaytBasePath.split('//')[0]; | ||
1875 | scaytBasePathSsrvHost = scaytBasePath.split('//')[1].split('/')[0]; | ||
1876 | scaytBasePathSsrvPath = scaytBasePath.split(scaytBasePathSsrvHost + '/')[1].replace('/lf/scayt3/ckscayt/', '') + '/script/ssrv.cgi'; | ||
1877 | } | ||
1878 | |||
1879 | if (scaytSrcUrl && !scaytBasePath && !editor.config.scayt_servicePath) { | ||
1880 | scaytSsrvSrcUrlSsrvProtocol = scaytSrcUrl.split('//')[0]; | ||
1881 | scaytSsrvSrcUrlSsrvHost = scaytSrcUrl.split('//')[1].split('/')[0]; | ||
1882 | scaytSsrvSrcUrlSsrvPath = scaytSrcUrl.split(scaytSsrvSrcUrlSsrvHost + '/')[1].replace('/lf/scayt3/ckscayt/ckscayt.js', '') + '/script/ssrv.cgi'; | ||
1883 | } | ||
1884 | |||
1885 | scaytSsrvProtocol = editor.config.scayt_serviceProtocol || scaytBasePathSsrvProtocol || scaytSsrvSrcUrlSsrvProtocol; | ||
1886 | scaytSsrvHost = editor.config.scayt_serviceHost || scaytBasePathSsrvHost || scaytSsrvSrcUrlSsrvHost; | ||
1887 | scaytSsrvPath = editor.config.scayt_servicePath || scaytBasePathSsrvPath || scaytSsrvSrcUrlSsrvPath; | ||
1888 | |||
1889 | wscSsrvWholePath = '//' + wscServiceHost + wscSsrvHost; | ||
1890 | scaytSsrvWholePath = '//' + scaytSsrvHost + '/' + scaytSsrvPath; | ||
1891 | |||
1892 | return wscSsrvWholePath === scaytSsrvWholePath; | ||
1893 | })(); | ||
1894 | } | ||
1895 | |||
1896 | //wsc on scayt UserDictionary and UserDictionaryName synchronization | ||
1897 | if (window.SCAYT && editor.wsc && editor.wsc.isSsrvSame) { | ||
1898 | var cgiOrigin = editor.wsc.cgiOrigin(); | ||
1899 | editor.wsc.syncIsDone = false; | ||
1900 | |||
1901 | var getUdOrUdn = function (e) { | ||
1902 | if (e.origin === cgiOrigin) { | ||
1903 | var data = JSON.parse(e.data); | ||
1904 | |||
1905 | if (data.ud && data.ud !== 'undefined') { | ||
1906 | editor.wsc.ud = data.ud; | ||
1907 | } else if (data.ud === 'undefined') { | ||
1908 | editor.wsc.ud = undefined; | ||
1909 | } | ||
1910 | |||
1911 | if (data.udn && data.udn !== 'undefined') { | ||
1912 | editor.wsc.udn = data.udn; | ||
1913 | } else if (data.udn === 'undefined') { | ||
1914 | editor.wsc.udn = undefined; | ||
1915 | } | ||
1916 | |||
1917 | if (!editor.wsc.syncIsDone) { | ||
1918 | udSynchronization(editor.wsc.ud); | ||
1919 | editor.wsc.syncIsDone = true; | ||
1920 | } | ||
1921 | } | ||
1922 | }; | ||
1923 | |||
1924 | var udSynchronization = function(cookieUd) { | ||
1925 | var localStorageUdArray = editor.wsc.getLocalStorageUD(), | ||
1926 | newUd; | ||
1927 | |||
1928 | if (localStorageUdArray instanceof Array) { | ||
1929 | newUd = localStorageUdArray.toString(); | ||
1930 | } | ||
1931 | |||
1932 | if (newUd !== undefined && newUd !== '') { | ||
1933 | setTimeout(function() { | ||
1934 | editor.wsc.addWords(newUd, function() { | ||
1935 | showFirstTab(NS.dialog); | ||
1936 | NS.dialog.setupContent(NS.dialog); | ||
1937 | }); | ||
1938 | }, 400); | ||
1939 | } | ||
1940 | }; | ||
1941 | |||
1942 | if (window.addEventListener){ | ||
1943 | addEventListener("message", getUdOrUdn, false); | ||
1944 | } else { | ||
1945 | window.attachEvent("onmessage", getUdOrUdn); | ||
1946 | } | ||
1947 | |||
1948 | //wsc on scayt UserDictionaryName synchronization | ||
1949 | setTimeout( | ||
1950 | function() { | ||
1951 | var udn = editor.wsc.getLocalStorageUDN(); | ||
1952 | |||
1953 | if (udn !== undefined) { | ||
1954 | editor.wsc.operationWithUDN('restore', udn); | ||
1955 | } | ||
1956 | |||
1957 | }, | ||
1958 | 500); //need to wait spell.js file to load | ||
1959 | |||
1960 | } | ||
1961 | }); | ||
1962 | |||
1963 | }, | ||
1964 | onHide: function() { | ||
1965 | var scaytPlugin = CKEDITOR.plugins.scayt, | ||
1966 | scaytInstance = editor.scayt; | ||
1967 | |||
1968 | editor.unlockSelection(); | ||
1969 | |||
1970 | if(scaytPlugin && scaytInstance && scaytPlugin.state[editor.name]) { | ||
1971 | scaytInstance.setMarkupPaused(false); | ||
1972 | } | ||
1973 | |||
1974 | NS.dataTemp = ''; | ||
1975 | NS.sessionid = ''; | ||
1976 | appTools.postMessage.unbindHandler(handlerIncomingData); | ||
1977 | |||
1978 | //scayt on wsc UserDictionary and UserDictionaryName synchronization | ||
1979 | if (editor.plugins.scayt && editor.wsc && editor.wsc.isSsrvSame) { | ||
1980 | var wscUDN = editor.wsc.udn, | ||
1981 | wscUD = editor.wsc.ud, | ||
1982 | wscUDarray, | ||
1983 | i; | ||
1984 | |||
1985 | if (editor.scayt) { // if SCAYT active | ||
1986 | if (!wscUDN) { | ||
1987 | editor.wsc.DataStorage.setData('scayt_user_dictionary_name', ''); | ||
1988 | editor.scayt.removeUserDictionary(); | ||
1989 | } else { | ||
1990 | editor.wsc.DataStorage.setData('scayt_user_dictionary_name', wscUDN); | ||
1991 | editor.scayt.restoreUserDictionary(wscUDN); | ||
1992 | } | ||
1993 | |||
1994 | if (wscUD) { | ||
1995 | setTimeout(function() { | ||
1996 | wscUDarray = wscUD.split(','); | ||
1997 | for (i = 0; i < wscUDarray.length; i += 1) { | ||
1998 | editor.scayt.addWordToUserDictionary(wscUDarray[i]); | ||
1999 | } | ||
2000 | }, 200); //wait for 'removeUserDictionary' command response | ||
2001 | } | ||
2002 | |||
2003 | if (!wscUD) { | ||
2004 | editor.wsc.DataStorage.setData('scayt_user_dictionary', []); | ||
2005 | } | ||
2006 | |||
2007 | } else { //if SCAYT not active | ||
2008 | |||
2009 | if (!wscUDN) { | ||
2010 | editor.wsc.DataStorage.setData('scayt_user_dictionary_name', ''); | ||
2011 | } else { | ||
2012 | editor.wsc.DataStorage.setData('scayt_user_dictionary_name', wscUDN); | ||
2013 | } | ||
2014 | |||
2015 | if (wscUD) { | ||
2016 | wscUDarray = wscUD.split(','); | ||
2017 | editor.wsc.DataStorage.setData('scayt_user_dictionary', wscUDarray); | ||
2018 | } | ||
2019 | } | ||
2020 | } | ||
2021 | }, | ||
2022 | contents: [ | ||
2023 | { | ||
2024 | id: 'SpellTab', | ||
2025 | label: 'SpellChecker', | ||
2026 | accessKey: 'S', | ||
2027 | elements: [ | ||
2028 | { | ||
2029 | type: 'html', | ||
2030 | id: 'banner', | ||
2031 | label: 'banner', | ||
2032 | style: '', //TODO | ||
2033 | html: '<div></div>' | ||
2034 | }, | ||
2035 | { | ||
2036 | type: 'html', | ||
2037 | id: 'Content', | ||
2038 | label: 'spellContent', | ||
2039 | html: '', | ||
2040 | setup: function(dialog) { | ||
2041 | var tabId = NS.iframeNumber + '_' + dialog._.currentTabId; | ||
2042 | var iframe = document.getElementById(tabId); | ||
2043 | NS.targetFromFrame[tabId] = iframe.contentWindow; | ||
2044 | } | ||
2045 | }, | ||
2046 | { | ||
2047 | type: 'hbox', | ||
2048 | id: 'bottomGroup', | ||
2049 | style: 'width:560px; margin: 0 auto;', | ||
2050 | widths: ['50%', '50%'], | ||
2051 | children: [ | ||
2052 | { | ||
2053 | type: 'hbox', | ||
2054 | id: 'leftCol', | ||
2055 | align: 'left', | ||
2056 | width: '50%', | ||
2057 | children: [ | ||
2058 | { | ||
2059 | type: 'vbox', | ||
2060 | id: 'rightCol1', | ||
2061 | widths: ['50%', '50%'], | ||
2062 | children: [ | ||
2063 | { | ||
2064 | type: 'text', | ||
2065 | id: 'ChangeTo_label', | ||
2066 | label: NS.LocalizationLabel['ChangeTo_label'].text + ':', | ||
2067 | labelLayout: 'horizontal', | ||
2068 | labelStyle: 'font: 12px/25px arial, sans-serif;', | ||
2069 | width: '140px', | ||
2070 | 'default': '', | ||
2071 | onShow: function() { | ||
2072 | NS.textNode['SpellTab'] = this; | ||
2073 | NS.LocalizationLabel['ChangeTo_label'].instance = this; | ||
2074 | }, | ||
2075 | onHide: function() { | ||
2076 | this.reset(); | ||
2077 | } | ||
2078 | }, | ||
2079 | { | ||
2080 | type: 'hbox', | ||
2081 | id: 'rightCol', | ||
2082 | align: 'right', | ||
2083 | width: '30%', | ||
2084 | children: [ | ||
2085 | { | ||
2086 | type: 'vbox', | ||
2087 | id: 'rightCol_col__left', | ||
2088 | children: [ | ||
2089 | { | ||
2090 | type: 'text', | ||
2091 | id: 'labelSuggestions', | ||
2092 | label: NS.LocalizationLabel['Suggestions'].text + ':', | ||
2093 | onShow: function() { | ||
2094 | NS.LocalizationLabel['Suggestions'].instance = this; | ||
2095 | this.getInputElement().setStyles({ | ||
2096 | display: 'none' | ||
2097 | }); | ||
2098 | } | ||
2099 | }, | ||
2100 | { | ||
2101 | type: 'html', | ||
2102 | id: 'logo', | ||
2103 | html: '<img width="99" height="68" border="0" src="" title="WebSpellChecker.net" alt="WebSpellChecker.net" style="display: inline-block;">', | ||
2104 | setup: function(dialog) { | ||
2105 | this.getElement().$.src = NS.logotype; | ||
2106 | this.getElement().getParent().setStyles({ | ||
2107 | "text-align": "left" | ||
2108 | }); | ||
2109 | } | ||
2110 | } | ||
2111 | ] | ||
2112 | }, | ||
2113 | { | ||
2114 | type: 'select', | ||
2115 | id: 'list_of_suggestions', | ||
2116 | labelStyle: 'font: 12px/25px arial, sans-serif;', | ||
2117 | size: '6', | ||
2118 | inputStyle: 'width: 140px; height: auto;', | ||
2119 | items: [['loading...']], | ||
2120 | onShow: function() { | ||
2121 | selectNode = this; | ||
2122 | }, | ||
2123 | onChange: function() { | ||
2124 | NS.textNode['SpellTab'].setValue(this.getValue()); | ||
2125 | } | ||
2126 | } | ||
2127 | ] | ||
2128 | } | ||
2129 | ] | ||
2130 | } | ||
2131 | ] | ||
2132 | }, | ||
2133 | { | ||
2134 | type: 'hbox', | ||
2135 | id: 'rightCol', | ||
2136 | align: 'right', | ||
2137 | width: '50%', | ||
2138 | children: [ | ||
2139 | { | ||
2140 | type: 'vbox', | ||
2141 | id: 'rightCol_col__left', | ||
2142 | widths: ['50%', '50%', '50%', '50%'], | ||
2143 | children: [ | ||
2144 | { | ||
2145 | type: 'button', | ||
2146 | id: 'ChangeTo_button', | ||
2147 | label: NS.LocalizationButton['ChangeTo_button'].text, | ||
2148 | title: 'Change to', | ||
2149 | style: 'width: 100%;', | ||
2150 | onLoad: function() { | ||
2151 | this.getElement().setAttribute("title-cmd", 'ChangeTo'); | ||
2152 | NS.LocalizationButton['ChangeTo_button'].instance = this; | ||
2153 | }, | ||
2154 | onClick: handlerButtons | ||
2155 | }, | ||
2156 | { | ||
2157 | type: 'button', | ||
2158 | id: 'ChangeAll', | ||
2159 | label: NS.LocalizationButton['ChangeAll'].text, | ||
2160 | title: 'Change All', | ||
2161 | style: 'width: 100%;', | ||
2162 | onLoad: function() { | ||
2163 | this.getElement().setAttribute("title-cmd", this.id); | ||
2164 | NS.LocalizationButton['ChangeAll'].instance = this; | ||
2165 | }, | ||
2166 | onClick: handlerButtons | ||
2167 | }, | ||
2168 | { | ||
2169 | type: 'button', | ||
2170 | id: 'AddWord', | ||
2171 | label: NS.LocalizationButton['AddWord'].text, | ||
2172 | title: 'Add word', | ||
2173 | style: 'width: 100%;', | ||
2174 | onLoad: function() { | ||
2175 | this.getElement().setAttribute("title-cmd", this.id); | ||
2176 | NS.LocalizationButton['AddWord'].instance = this; | ||
2177 | }, | ||
2178 | onClick: handlerButtons | ||
2179 | }, | ||
2180 | { | ||
2181 | type: 'button', | ||
2182 | id: 'FinishChecking_button', | ||
2183 | label: NS.LocalizationButton['FinishChecking_button'].text, | ||
2184 | title: 'Finish Checking', | ||
2185 | style: 'width: 100%;margin-top: 9px;', | ||
2186 | onLoad: function() { | ||
2187 | this.getElement().setAttribute("title-cmd", 'FinishChecking'); | ||
2188 | NS.LocalizationButton['FinishChecking_button'].instance = this; | ||
2189 | }, | ||
2190 | onClick: handlerButtons | ||
2191 | } | ||
2192 | ] | ||
2193 | }, | ||
2194 | { | ||
2195 | type: 'vbox', | ||
2196 | id: 'rightCol_col__right', | ||
2197 | widths: ['50%', '50%', '50%'], | ||
2198 | children: [ | ||
2199 | { | ||
2200 | type: 'button', | ||
2201 | id: 'IgnoreWord', | ||
2202 | label: NS.LocalizationButton['IgnoreWord'].text, | ||
2203 | title: 'Ignore word', | ||
2204 | style: 'width: 100%;', | ||
2205 | onLoad: function() { | ||
2206 | this.getElement().setAttribute("title-cmd", this.id); | ||
2207 | NS.LocalizationButton['IgnoreWord'].instance = this; | ||
2208 | }, | ||
2209 | onClick: handlerButtons | ||
2210 | }, | ||
2211 | { | ||
2212 | type: 'button', | ||
2213 | id: 'IgnoreAllWords', | ||
2214 | label: NS.LocalizationButton['IgnoreAllWords'].text, | ||
2215 | title: 'Ignore all words', | ||
2216 | style: 'width: 100%;', | ||
2217 | onLoad: function() { | ||
2218 | this.getElement().setAttribute("title-cmd", this.id); | ||
2219 | NS.LocalizationButton['IgnoreAllWords'].instance = this; | ||
2220 | }, | ||
2221 | onClick: handlerButtons | ||
2222 | }, | ||
2223 | { | ||
2224 | type: 'button', | ||
2225 | id: 'Options', | ||
2226 | label: NS.LocalizationButton['Options'].text, | ||
2227 | title: 'Option', | ||
2228 | style: 'width: 100%;', | ||
2229 | onLoad: function() { | ||
2230 | NS.LocalizationButton['Options'].instance = this; | ||
2231 | if (document.location.protocol == "file:") { | ||
2232 | this.disable(); | ||
2233 | } | ||
2234 | }, | ||
2235 | onClick: function() { | ||
2236 | // because in chrome and safary document.activeElement returns <body> tag. We need to signal that clicked element is active | ||
2237 | this.getElement().focus(); | ||
2238 | |||
2239 | if (document.location.protocol == "file:") { | ||
2240 | alert('WSC: Options functionality is disabled when runing from file system'); | ||
2241 | } else { | ||
2242 | activeElement = document.activeElement; | ||
2243 | editor.openDialog('options'); | ||
2244 | } | ||
2245 | } | ||
2246 | } | ||
2247 | ] | ||
2248 | } | ||
2249 | ] | ||
2250 | } | ||
2251 | ] | ||
2252 | }, | ||
2253 | { | ||
2254 | type: 'hbox', | ||
2255 | id: 'BlockFinishChecking', | ||
2256 | style: 'width:560px; margin: 0 auto;', | ||
2257 | widths: ['70%', '30%'], | ||
2258 | onShow: function() { | ||
2259 | this.getElement().setStyles({ | ||
2260 | display: 'block', | ||
2261 | position: 'absolute', | ||
2262 | left: '-9999px' | ||
2263 | }); | ||
2264 | }, | ||
2265 | onHide: showCurrentTabs, | ||
2266 | children: [ | ||
2267 | { | ||
2268 | type: 'hbox', | ||
2269 | id: 'leftCol', | ||
2270 | align: 'left', | ||
2271 | width: '70%', | ||
2272 | children: [ | ||
2273 | { | ||
2274 | type: 'vbox', | ||
2275 | id: 'rightCol1', | ||
2276 | setup: function() { | ||
2277 | this.getChild()[0].getElement().$.src = NS.logotype; | ||
2278 | this.getChild()[0].getElement().getParent().setStyles({ | ||
2279 | "text-align": "center" | ||
2280 | }); | ||
2281 | }, | ||
2282 | children: [ | ||
2283 | { | ||
2284 | type: 'html', | ||
2285 | id: 'logo', | ||
2286 | html: '<img width="99" height="68" border="0" src="" title="WebSpellChecker.net" alt="WebSpellChecker.net" style="display: inline-block;">' | ||
2287 | } | ||
2288 | ] | ||
2289 | } | ||
2290 | ] | ||
2291 | }, | ||
2292 | { | ||
2293 | type: 'hbox', | ||
2294 | id: 'rightCol', | ||
2295 | align: 'right', | ||
2296 | width: '30%', | ||
2297 | children: [ | ||
2298 | { | ||
2299 | type: 'vbox', | ||
2300 | id: 'rightCol_col__left', | ||
2301 | children: [ | ||
2302 | { | ||
2303 | type: 'button', | ||
2304 | id: 'Option_button', | ||
2305 | label: NS.LocalizationButton['Options'].text, | ||
2306 | title: 'Option', | ||
2307 | style: 'width: 100%;', | ||
2308 | onLoad: function() { | ||
2309 | this.getElement().setAttribute("title-cmd", this.id); | ||
2310 | if (document.location.protocol == "file:") { | ||
2311 | this.disable(); | ||
2312 | } | ||
2313 | }, | ||
2314 | onClick: function() { | ||
2315 | // because in chrome and safary document.activeElement returns <body> tag. We need to signal that clicked element is active | ||
2316 | this.getElement().focus(); | ||
2317 | |||
2318 | if (document.location.protocol == "file:") { | ||
2319 | alert('WSC: Options functionality is disabled when runing from file system'); | ||
2320 | } else { | ||
2321 | activeElement = document.activeElement; | ||
2322 | editor.openDialog('options'); | ||
2323 | } | ||
2324 | } | ||
2325 | }, | ||
2326 | { | ||
2327 | type: 'button', | ||
2328 | id: 'FinishChecking_button_block', | ||
2329 | label: NS.LocalizationButton['FinishChecking_button_block'].text, | ||
2330 | title: 'Finish Checking', | ||
2331 | style: 'width: 100%;', | ||
2332 | onLoad: function() { | ||
2333 | this.getElement().setAttribute("title-cmd", 'FinishChecking'); | ||
2334 | }, | ||
2335 | onClick: handlerButtons | ||
2336 | } | ||
2337 | ] | ||
2338 | } | ||
2339 | ] | ||
2340 | } | ||
2341 | ] | ||
2342 | } | ||
2343 | ] | ||
2344 | }, | ||
2345 | { | ||
2346 | id: 'GrammTab', | ||
2347 | label: 'Grammar', | ||
2348 | accessKey: 'G', | ||
2349 | elements: [ | ||
2350 | { | ||
2351 | type: 'html', | ||
2352 | id: 'banner', | ||
2353 | label: 'banner', | ||
2354 | style: '', //TODO | ||
2355 | html: '<div></div>' | ||
2356 | }, | ||
2357 | { | ||
2358 | type: 'html', | ||
2359 | id: 'Content', | ||
2360 | label: 'GrammarContent', | ||
2361 | html: '', | ||
2362 | setup: function() { | ||
2363 | var tabId = NS.iframeNumber + '_' + NS.dialog._.currentTabId; | ||
2364 | var iframe = document.getElementById(tabId); | ||
2365 | NS.targetFromFrame[tabId] = iframe.contentWindow; | ||
2366 | } | ||
2367 | }, | ||
2368 | { | ||
2369 | type: 'vbox', | ||
2370 | id: 'bottomGroup', | ||
2371 | style: 'width:560px; margin: 0 auto;', | ||
2372 | children: [ | ||
2373 | { | ||
2374 | type: 'hbox', | ||
2375 | id: 'leftCol', | ||
2376 | widths: ['66%', '34%'], | ||
2377 | children: [ | ||
2378 | { | ||
2379 | type: 'vbox', | ||
2380 | children: [ | ||
2381 | { | ||
2382 | type: 'text', | ||
2383 | id: 'text', | ||
2384 | label: "Change to:", | ||
2385 | labelLayout: 'horizontal', | ||
2386 | labelStyle: 'font: 12px/25px arial, sans-serif;', | ||
2387 | inputStyle: 'float: right; width: 200px;', | ||
2388 | 'default': '', | ||
2389 | onShow: function() { | ||
2390 | NS.textNode['GrammTab'] = this; | ||
2391 | }, | ||
2392 | onHide: function() { | ||
2393 | this.reset(); | ||
2394 | } | ||
2395 | }, | ||
2396 | { | ||
2397 | type: 'html', | ||
2398 | id: 'html_text', | ||
2399 | html: "<div style='min-height: 17px; line-height: 17px; padding: 5px; text-align: left;background: #F1F1F1;color: #595959; white-space: normal!important;'></div>", | ||
2400 | onShow: function(e) { | ||
2401 | NS.textNodeInfo['GrammTab'] = this; | ||
2402 | } | ||
2403 | }, | ||
2404 | { | ||
2405 | type: 'html', | ||
2406 | id: 'radio', | ||
2407 | html: "", | ||
2408 | onShow: function() { | ||
2409 | NS.grammerSuggest = this; | ||
2410 | } | ||
2411 | } | ||
2412 | ] | ||
2413 | }, | ||
2414 | { | ||
2415 | type: 'vbox', | ||
2416 | children: [ | ||
2417 | { | ||
2418 | type: 'button', | ||
2419 | id: 'ChangeTo_button', | ||
2420 | label: 'Change to', | ||
2421 | title: 'Change to', | ||
2422 | style: 'width: 133px; float: right;', | ||
2423 | onLoad: function() { | ||
2424 | this.getElement().setAttribute("title-cmd", 'ChangeTo'); | ||
2425 | }, | ||
2426 | onClick: handlerButtons | ||
2427 | }, | ||
2428 | { | ||
2429 | type: 'button', | ||
2430 | id: 'IgnoreWord', | ||
2431 | label: 'Ignore word', | ||
2432 | title: 'Ignore word', | ||
2433 | style: 'width: 133px; float: right;', | ||
2434 | onLoad: function() { | ||
2435 | this.getElement().setAttribute("title-cmd", this.id); | ||
2436 | }, | ||
2437 | onClick: handlerButtons | ||
2438 | }, | ||
2439 | { | ||
2440 | type: 'button', | ||
2441 | id: 'IgnoreAllWords', | ||
2442 | label: 'Ignore Problem', | ||
2443 | title: 'Ignore Problem', | ||
2444 | style: 'width: 133px; float: right;', | ||
2445 | onLoad: function() { | ||
2446 | this.getElement().setAttribute("title-cmd", this.id); | ||
2447 | }, | ||
2448 | onClick: handlerButtons | ||
2449 | }, | ||
2450 | { | ||
2451 | type: 'button', | ||
2452 | id: 'FinishChecking_button', | ||
2453 | label: NS.LocalizationButton['FinishChecking_button'].text, | ||
2454 | title: 'Finish Checking', | ||
2455 | style: 'width: 133px; float: right; margin-top: 9px;', | ||
2456 | onLoad: function() { | ||
2457 | this.getElement().setAttribute("title-cmd", 'FinishChecking'); | ||
2458 | }, | ||
2459 | onClick: handlerButtons | ||
2460 | } | ||
2461 | ] | ||
2462 | } | ||
2463 | ] | ||
2464 | } | ||
2465 | ] | ||
2466 | }, | ||
2467 | { | ||
2468 | type: 'hbox', | ||
2469 | id: 'BlockFinishChecking', | ||
2470 | style: 'width:560px; margin: 0 auto;', | ||
2471 | widths: ['70%', '30%'], | ||
2472 | onShow: function() { | ||
2473 | this.getElement().setStyles({ | ||
2474 | display: 'block', | ||
2475 | position: 'absolute', | ||
2476 | left: '-9999px' | ||
2477 | }); | ||
2478 | }, | ||
2479 | onHide: showCurrentTabs, | ||
2480 | children: [ | ||
2481 | { | ||
2482 | type: 'hbox', | ||
2483 | id: 'leftCol', | ||
2484 | align: 'left', | ||
2485 | width: '70%', | ||
2486 | children: [ | ||
2487 | { | ||
2488 | type: 'vbox', | ||
2489 | id: 'rightCol1', | ||
2490 | children: [ | ||
2491 | { | ||
2492 | type: 'html', | ||
2493 | id: 'logo', | ||
2494 | html: '<img width="99" height="68" border="0" src="" title="WebSpellChecker.net" alt="WebSpellChecker.net" style="display: inline-block;">', | ||
2495 | setup: function() { | ||
2496 | this.getElement().$.src = NS.logotype; | ||
2497 | this.getElement().getParent().setStyles({ | ||
2498 | "text-align": "center" | ||
2499 | }); | ||
2500 | } | ||
2501 | } | ||
2502 | ] | ||
2503 | } | ||
2504 | ] | ||
2505 | }, | ||
2506 | { | ||
2507 | type: 'hbox', | ||
2508 | id: 'rightCol', | ||
2509 | align: 'right', | ||
2510 | width: '30%', | ||
2511 | children: [ | ||
2512 | { | ||
2513 | type: 'vbox', | ||
2514 | id: 'rightCol_col__left', | ||
2515 | children: [ | ||
2516 | { | ||
2517 | type: 'button', | ||
2518 | id: 'FinishChecking_button_block', | ||
2519 | label: NS.LocalizationButton['FinishChecking_button_block'].text, | ||
2520 | title: 'Finish Checking', | ||
2521 | style: 'width: 100%;', | ||
2522 | onLoad: function() { | ||
2523 | this.getElement().setAttribute("title-cmd", 'FinishChecking'); | ||
2524 | }, | ||
2525 | onClick: handlerButtons | ||
2526 | } | ||
2527 | ] | ||
2528 | } | ||
2529 | ] | ||
2530 | } | ||
2531 | ] | ||
2532 | } | ||
2533 | ] | ||
2534 | }, | ||
2535 | { | ||
2536 | id: 'Thesaurus', | ||
2537 | label: 'Thesaurus', | ||
2538 | accessKey: 'T', | ||
2539 | elements: [ | ||
2540 | { | ||
2541 | type: 'html', | ||
2542 | id: 'banner', | ||
2543 | label: 'banner', | ||
2544 | style: '', //TODO | ||
2545 | html: '<div></div>' | ||
2546 | }, | ||
2547 | { | ||
2548 | type: 'html', | ||
2549 | id: 'Content', | ||
2550 | label: 'spellContent', | ||
2551 | html: '', | ||
2552 | setup: function() { | ||
2553 | var tabId = NS.iframeNumber + '_' + NS.dialog._.currentTabId; | ||
2554 | var iframe = document.getElementById(tabId); | ||
2555 | NS.targetFromFrame[tabId] = iframe.contentWindow; | ||
2556 | } | ||
2557 | }, | ||
2558 | { | ||
2559 | type: 'vbox', | ||
2560 | id: 'bottomGroup', | ||
2561 | style: 'width:560px; margin: -10px auto; overflow: hidden;', | ||
2562 | children: [ | ||
2563 | { | ||
2564 | type: 'hbox', | ||
2565 | widths: ['75%', '25%'], | ||
2566 | children: [ | ||
2567 | { | ||
2568 | type: 'vbox', | ||
2569 | children: [ | ||
2570 | { | ||
2571 | type: 'hbox', | ||
2572 | widths: ['65%', '35%'], | ||
2573 | children: [ | ||
2574 | { | ||
2575 | type: 'text', | ||
2576 | id: 'ChangeTo_label', | ||
2577 | label: NS.LocalizationLabel['ChangeTo_label'].text + ':', | ||
2578 | labelLayout: 'horizontal', | ||
2579 | inputStyle: 'width: 160px;', | ||
2580 | labelStyle: 'font: 12px/25px arial, sans-serif;', | ||
2581 | 'default': '', | ||
2582 | onShow: function(e) { | ||
2583 | NS.textNode['Thesaurus'] = this; | ||
2584 | NS.LocalizationLabel['ChangeTo_label'].instance = this; | ||
2585 | }, | ||
2586 | onHide: function() { | ||
2587 | this.reset(); | ||
2588 | } | ||
2589 | }, | ||
2590 | { | ||
2591 | type: 'button', | ||
2592 | id: 'ChangeTo_button', | ||
2593 | label: NS.LocalizationButton['ChangeTo_button'].text, | ||
2594 | title: 'Change to', | ||
2595 | style: 'width: 121px; margin-top: 1px;', | ||
2596 | onLoad: function() { | ||
2597 | this.getElement().setAttribute("title-cmd", 'ChangeTo'); | ||
2598 | NS.LocalizationButton['ChangeTo_button'].instance = this; | ||
2599 | }, | ||
2600 | onClick: handlerButtons | ||
2601 | } | ||
2602 | ] | ||
2603 | }, | ||
2604 | { | ||
2605 | type: 'hbox', | ||
2606 | children: [ | ||
2607 | { | ||
2608 | type: 'select', | ||
2609 | id: 'Categories', | ||
2610 | label: NS.LocalizationLabel['Categories'].text + ':', | ||
2611 | labelStyle: 'font: 12px/25px arial, sans-serif;', | ||
2612 | size: '5', | ||
2613 | inputStyle: 'width: 180px; height: auto;', | ||
2614 | items: [], | ||
2615 | onShow: function() { | ||
2616 | NS.selectNode['Categories'] = this; | ||
2617 | NS.LocalizationLabel['Categories'].instance = this; | ||
2618 | }, | ||
2619 | onChange: function() { | ||
2620 | NS.buildOptionSynonyms(this.getValue()); | ||
2621 | } | ||
2622 | }, | ||
2623 | { | ||
2624 | type: 'select', | ||
2625 | id: 'Synonyms', | ||
2626 | label: NS.LocalizationLabel['Synonyms'].text + ':', | ||
2627 | labelStyle: 'font: 12px/25px arial, sans-serif;', | ||
2628 | size: '5', | ||
2629 | inputStyle: 'width: 180px; height: auto;', | ||
2630 | items: [], | ||
2631 | onShow: function() { | ||
2632 | NS.selectNode['Synonyms'] = this; | ||
2633 | NS.textNode['Thesaurus'].setValue(this.getValue()); | ||
2634 | NS.LocalizationLabel['Synonyms'].instance = this; | ||
2635 | }, | ||
2636 | onChange: function(e) { | ||
2637 | NS.textNode['Thesaurus'].setValue(this.getValue()); | ||
2638 | } | ||
2639 | } | ||
2640 | ] | ||
2641 | } | ||
2642 | ] | ||
2643 | }, | ||
2644 | { | ||
2645 | type: 'vbox', | ||
2646 | width: '120px', | ||
2647 | style: "margin-top:46px;", | ||
2648 | children: [ | ||
2649 | { | ||
2650 | type: 'html', | ||
2651 | id: 'logotype', | ||
2652 | label: 'WebSpellChecker.net', | ||
2653 | html: '<img width="99" height="68" border="0" src="" title="WebSpellChecker.net" alt="WebSpellChecker.net" style="display: inline-block;">', | ||
2654 | setup: function() { | ||
2655 | this.getElement().$.src = NS.logotype; | ||
2656 | this.getElement().getParent().setStyles({ | ||
2657 | "text-align": "center" | ||
2658 | }); | ||
2659 | } | ||
2660 | }, | ||
2661 | { | ||
2662 | type: 'button', | ||
2663 | id: 'FinishChecking_button', | ||
2664 | label: NS.LocalizationButton['FinishChecking_button'].text, | ||
2665 | title: 'Finish Checking', | ||
2666 | style: 'width: 100%; float: right; margin-top: 9px;', | ||
2667 | onLoad: function() { | ||
2668 | this.getElement().setAttribute("title-cmd", 'FinishChecking'); | ||
2669 | }, | ||
2670 | onClick: handlerButtons | ||
2671 | } | ||
2672 | ] | ||
2673 | } | ||
2674 | ] | ||
2675 | } | ||
2676 | ] | ||
2677 | }, | ||
2678 | { | ||
2679 | type: 'hbox', | ||
2680 | id: 'BlockFinishChecking', | ||
2681 | style: 'width:560px; margin: 0 auto;', | ||
2682 | widths: ['70%', '30%'], | ||
2683 | onShow: function() { | ||
2684 | this.getElement().setStyles({ | ||
2685 | display: 'block', | ||
2686 | position: 'absolute', | ||
2687 | left: '-9999px' | ||
2688 | }); | ||
2689 | }, | ||
2690 | children: [ | ||
2691 | { | ||
2692 | type: 'hbox', | ||
2693 | id: 'leftCol', | ||
2694 | align: 'left', | ||
2695 | width: '70%', | ||
2696 | children: [ | ||
2697 | { | ||
2698 | type: 'vbox', | ||
2699 | id: 'rightCol1', | ||
2700 | children: [ | ||
2701 | { | ||
2702 | type: 'html', | ||
2703 | id: 'logo', | ||
2704 | html: '<img width="99" height="68" border="0" src="" title="WebSpellChecker.net" alt="WebSpellChecker.net" style="display: inline-block;">', | ||
2705 | setup: function() { | ||
2706 | this.getElement().$.src = NS.logotype; | ||
2707 | this.getElement().getParent().setStyles({ | ||
2708 | "text-align": "center" | ||
2709 | }); | ||
2710 | } | ||
2711 | } | ||
2712 | ] | ||
2713 | } | ||
2714 | ] | ||
2715 | }, | ||
2716 | { | ||
2717 | type: 'hbox', | ||
2718 | id: 'rightCol', | ||
2719 | align: 'right', | ||
2720 | width: '30%', | ||
2721 | children: [ | ||
2722 | { | ||
2723 | type: 'vbox', | ||
2724 | id: 'rightCol_col__left', | ||
2725 | children: [ | ||
2726 | { | ||
2727 | type: 'button', | ||
2728 | id: 'FinishChecking_button_block', | ||
2729 | label: NS.LocalizationButton['FinishChecking_button_block'].text, | ||
2730 | title: 'Finish Checking', | ||
2731 | style: 'width: 100%;', | ||
2732 | onLoad: function() { | ||
2733 | this.getElement().setAttribute("title-cmd", 'FinishChecking'); | ||
2734 | }, | ||
2735 | onClick: handlerButtons | ||
2736 | } | ||
2737 | ] | ||
2738 | } | ||
2739 | ] | ||
2740 | } | ||
2741 | ] | ||
2742 | } | ||
2743 | ] | ||
2744 | } | ||
2745 | ] | ||
2746 | }; | ||
2747 | }); | ||
2748 | |||
2749 | var activeElement = null; | ||
2750 | |||
2751 | // Options dialog | ||
2752 | CKEDITOR.dialog.add('options', function(editor) { | ||
2753 | var dialog = null; | ||
2754 | var linkOnCheckbox = {}; | ||
2755 | var checkboxState = {}; | ||
2756 | var ospString = null; | ||
2757 | var OptionsTextError = null; | ||
2758 | var cmd = null; | ||
2759 | |||
2760 | var set_osp = []; | ||
2761 | var dictionaryState = { | ||
2762 | 'udn': appTools.cookie.get('udn'), | ||
2763 | 'osp': appTools.cookie.get('osp') | ||
2764 | }; | ||
2765 | |||
2766 | var setHandlerOptions = function() { | ||
2767 | var osp = appTools.cookie.get('osp'), | ||
2768 | strToArr = osp.split(""); | ||
2769 | |||
2770 | checkboxState['IgnoreAllCapsWords'] = strToArr[0]; | ||
2771 | checkboxState['IgnoreWordsNumbers'] = strToArr[1]; | ||
2772 | checkboxState['IgnoreMixedCaseWords'] = strToArr[2]; | ||
2773 | checkboxState['IgnoreDomainNames'] = strToArr[3]; | ||
2774 | }; | ||
2775 | |||
2776 | var sendDicOptions = function(event) { | ||
2777 | event = event || window.event; | ||
2778 | cmd = this.getElement().getAttribute("title-cmd"); | ||
2779 | var osp = []; | ||
2780 | |||
2781 | osp[0] = checkboxState['IgnoreAllCapsWords']; | ||
2782 | osp[1] = checkboxState['IgnoreWordsNumbers']; | ||
2783 | osp[2] = checkboxState['IgnoreMixedCaseWords']; | ||
2784 | osp[3] = checkboxState['IgnoreDomainNames']; | ||
2785 | |||
2786 | osp = osp.toString().replace(/,/g, ""); | ||
2787 | |||
2788 | |||
2789 | appTools.cookie.set('osp', osp); | ||
2790 | appTools.cookie.set('udnCmd', cmd ? cmd : 'ignore'); | ||
2791 | if (cmd == "delete") { | ||
2792 | |||
2793 | appTools.postMessage.send({ | ||
2794 | 'id': 'options_dic_send' | ||
2795 | }); | ||
2796 | } else { | ||
2797 | var udn = ''; | ||
2798 | if(nameNode.getValue() !== ''){ | ||
2799 | udn = nameNode.getValue(); | ||
2800 | } | ||
2801 | appTools.cookie.set('udn', udn); | ||
2802 | appTools.postMessage.send({ | ||
2803 | 'id': 'options_dic_send' | ||
2804 | }); | ||
2805 | } | ||
2806 | |||
2807 | }; | ||
2808 | |||
2809 | |||
2810 | var sendAllOptions = function() { | ||
2811 | var osp = []; | ||
2812 | |||
2813 | osp[0] = checkboxState['IgnoreAllCapsWords']; | ||
2814 | osp[1] = checkboxState['IgnoreWordsNumbers']; | ||
2815 | osp[2] = checkboxState['IgnoreMixedCaseWords']; | ||
2816 | osp[3] = checkboxState['IgnoreDomainNames']; | ||
2817 | |||
2818 | osp = osp.toString().replace(/,/g, ""); | ||
2819 | |||
2820 | appTools.cookie.set('osp', osp); | ||
2821 | |||
2822 | appTools.postMessage.send({ | ||
2823 | 'id': 'options_checkbox_send' | ||
2824 | }); | ||
2825 | |||
2826 | |||
2827 | }; | ||
2828 | |||
2829 | var cameOptions = function() { | ||
2830 | OptionsTextError.getElement().setHtml(NS.LocalizationComing['error']); | ||
2831 | OptionsTextError.getElement().show(); | ||
2832 | }; | ||
2833 | |||
2834 | return { | ||
2835 | title: NS.LocalizationComing['Options'], | ||
2836 | minWidth: 430, | ||
2837 | minHeight: 130, | ||
2838 | resizable: CKEDITOR.DIALOG_RESIZE_NONE, | ||
2839 | contents: [ | ||
2840 | { | ||
2841 | id: 'OptionsTab', | ||
2842 | label: 'Options', | ||
2843 | accessKey: 'O', | ||
2844 | elements: [ | ||
2845 | { | ||
2846 | type: 'hbox', | ||
2847 | id: 'options_error', | ||
2848 | children: [ | ||
2849 | { | ||
2850 | type: 'html', | ||
2851 | style: "display: block;text-align: center;white-space: normal!important; font-size: 12px;color:red", | ||
2852 | html: '<div></div>', | ||
2853 | onShow: function() { | ||
2854 | OptionsTextError = this; | ||
2855 | } | ||
2856 | } | ||
2857 | ] | ||
2858 | }, | ||
2859 | { | ||
2860 | type: 'vbox', | ||
2861 | id: 'Options_content', | ||
2862 | children: [ | ||
2863 | { | ||
2864 | type: 'hbox', | ||
2865 | id: 'Options_manager', | ||
2866 | widths: ['52%', '48%'], | ||
2867 | children: [ | ||
2868 | { | ||
2869 | type: 'fieldset', | ||
2870 | label: 'Spell Checking Options', | ||
2871 | style: 'border: none;margin-top: 13px;padding: 10px 0 10px 10px', | ||
2872 | onShow: function() { | ||
2873 | this.getInputElement().$.children[0].innerHTML = NS.LocalizationComing['SpellCheckingOptions']; | ||
2874 | }, | ||
2875 | children: [ | ||
2876 | { | ||
2877 | type: 'vbox', | ||
2878 | id: 'Options_checkbox', | ||
2879 | children: [ | ||
2880 | { | ||
2881 | type: 'checkbox', | ||
2882 | id: 'IgnoreAllCapsWords', | ||
2883 | label: 'Ignore All-Caps Words', | ||
2884 | labelStyle: 'margin-left: 5px; font: 12px/16px arial, sans-serif;display: inline-block;white-space: normal;', | ||
2885 | style: "float:left; min-height: 16px;", | ||
2886 | 'default': '', | ||
2887 | onClick: function() { | ||
2888 | checkboxState[this.id] = (!this.getValue()) ? 0 : 1; | ||
2889 | } | ||
2890 | }, | ||
2891 | { | ||
2892 | type: 'checkbox', | ||
2893 | id: 'IgnoreWordsNumbers', | ||
2894 | label: 'Ignore Words with Numbers', | ||
2895 | labelStyle: 'margin-left: 5px; font: 12px/16px arial, sans-serif;display: inline-block;white-space: normal;', | ||
2896 | style: "float:left; min-height: 16px;", | ||
2897 | 'default': '', | ||
2898 | onClick: function() { | ||
2899 | checkboxState[this.id] = (!this.getValue()) ? 0 : 1; | ||
2900 | } | ||
2901 | }, | ||
2902 | { | ||
2903 | type: 'checkbox', | ||
2904 | id: 'IgnoreMixedCaseWords', | ||
2905 | label: 'Ignore Mixed-Case Words', | ||
2906 | labelStyle: 'margin-left: 5px; font: 12px/16px arial, sans-serif;display: inline-block;white-space: normal;', | ||
2907 | style: "float:left; min-height: 16px;", | ||
2908 | 'default': '', | ||
2909 | onClick: function() { | ||
2910 | checkboxState[this.id] = (!this.getValue()) ? 0 : 1; | ||
2911 | } | ||
2912 | }, | ||
2913 | { | ||
2914 | type: 'checkbox', | ||
2915 | id: 'IgnoreDomainNames', | ||
2916 | label: 'Ignore Domain Names', | ||
2917 | labelStyle: 'margin-left: 5px; font: 12px/16px arial, sans-serif;display: inline-block;white-space: normal;', | ||
2918 | style: "float:left; min-height: 16px;", | ||
2919 | 'default': '', | ||
2920 | onClick: function() { | ||
2921 | checkboxState[this.id] = (!this.getValue()) ? 0 : 1; | ||
2922 | } | ||
2923 | } | ||
2924 | ] | ||
2925 | } | ||
2926 | ] | ||
2927 | }, | ||
2928 | { | ||
2929 | type: 'vbox', | ||
2930 | id: 'Options_DictionaryName', | ||
2931 | children: [ | ||
2932 | { | ||
2933 | type: 'text', | ||
2934 | id: 'DictionaryName', | ||
2935 | style: 'margin-bottom: 10px', | ||
2936 | label: 'Dictionary Name:', | ||
2937 | labelLayout: 'vertical', | ||
2938 | labelStyle: 'font: 12px/25px arial, sans-serif;', | ||
2939 | 'default': '', | ||
2940 | onLoad: function() { | ||
2941 | nameNode = this; | ||
2942 | var udn = NS.userDictionaryName ? NS.userDictionaryName : appTools.cookie.get('udn') && undefined ? ' ' : this.getValue(); | ||
2943 | this.setValue(udn); | ||
2944 | }, | ||
2945 | onShow: function() { | ||
2946 | nameNode = this; | ||
2947 | var udn = !appTools.cookie.get('udn') ? this.getValue() : appTools.cookie.get('udn'); | ||
2948 | this.setValue(udn); | ||
2949 | this.setLabel(NS.LocalizationComing['DictionaryName']); | ||
2950 | }, | ||
2951 | onHide: function() { | ||
2952 | this.reset(); | ||
2953 | } | ||
2954 | }, | ||
2955 | { | ||
2956 | type: 'hbox', | ||
2957 | id: 'Options_buttons', | ||
2958 | children: [ | ||
2959 | { | ||
2960 | type: 'vbox', | ||
2961 | id: 'Options_leftCol_col', | ||
2962 | widths: ['50%', '50%'], | ||
2963 | children: [ | ||
2964 | { | ||
2965 | type: 'button', | ||
2966 | id: 'create', | ||
2967 | label: 'Create', | ||
2968 | title: 'Create', | ||
2969 | style: 'width: 100%;', | ||
2970 | onLoad: function() { | ||
2971 | this.getElement().setAttribute("title-cmd", this.id); | ||
2972 | }, | ||
2973 | onShow: function() { | ||
2974 | var el = this.getElement().getFirst() || this.getElement(); | ||
2975 | |||
2976 | el.setText(NS.LocalizationComing['Create']); | ||
2977 | }, | ||
2978 | onClick: sendDicOptions | ||
2979 | }, | ||
2980 | { | ||
2981 | type: 'button', | ||
2982 | id: 'restore', | ||
2983 | label: 'Restore', | ||
2984 | title: 'Restore', | ||
2985 | style: 'width: 100%;', | ||
2986 | onLoad: function() { | ||
2987 | this.getElement().setAttribute("title-cmd", this.id); | ||
2988 | }, | ||
2989 | onShow: function() { | ||
2990 | var el = this.getElement().getFirst() || this.getElement(); | ||
2991 | |||
2992 | el.setText(NS.LocalizationComing['Restore']); | ||
2993 | }, | ||
2994 | onClick: sendDicOptions | ||
2995 | } | ||
2996 | ] | ||
2997 | }, | ||
2998 | { | ||
2999 | type: 'vbox', | ||
3000 | id: 'Options_rightCol_col', | ||
3001 | widths: ['50%', '50%'], | ||
3002 | children: [ | ||
3003 | { | ||
3004 | type: 'button', | ||
3005 | id: 'rename', | ||
3006 | label: 'Rename', | ||
3007 | title: 'Rename', | ||
3008 | style: 'width: 100%;', | ||
3009 | onLoad: function() { | ||
3010 | this.getElement().setAttribute("title-cmd", this.id); | ||
3011 | }, | ||
3012 | onShow: function() { | ||
3013 | var el = this.getElement().getFirst() || this.getElement(); | ||
3014 | |||
3015 | el.setText(NS.LocalizationComing['Rename']); | ||
3016 | }, | ||
3017 | onClick: sendDicOptions | ||
3018 | }, | ||
3019 | { | ||
3020 | type: 'button', | ||
3021 | id: 'delete', | ||
3022 | label: 'Remove', | ||
3023 | title: 'Remove', | ||
3024 | style: 'width: 100%;', | ||
3025 | onLoad: function() { | ||
3026 | this.getElement().setAttribute("title-cmd", this.id); | ||
3027 | }, | ||
3028 | onShow: function() { | ||
3029 | var el = this.getElement().getFirst() || this.getElement(); | ||
3030 | |||
3031 | el.setText(NS.LocalizationComing['Remove']); | ||
3032 | }, | ||
3033 | onClick: sendDicOptions | ||
3034 | } | ||
3035 | ] | ||
3036 | } | ||
3037 | ] | ||
3038 | } | ||
3039 | ] | ||
3040 | } | ||
3041 | ] | ||
3042 | }, | ||
3043 | { | ||
3044 | type: 'hbox', | ||
3045 | id: 'Options_text', | ||
3046 | children: [ | ||
3047 | { | ||
3048 | type: 'html', | ||
3049 | style: "text-align: justify;margin-top: 15px;white-space: normal!important; font-size: 12px;color:#777;", | ||
3050 | html: "<div>" + NS.LocalizationComing['OptionsTextIntro'] + "</div>", | ||
3051 | onShow: function() { | ||
3052 | this.getElement().setText(NS.LocalizationComing['OptionsTextIntro']); | ||
3053 | } | ||
3054 | } | ||
3055 | ] | ||
3056 | } | ||
3057 | ] | ||
3058 | } | ||
3059 | ] | ||
3060 | } | ||
3061 | ], | ||
3062 | buttons: [CKEDITOR.dialog.okButton, CKEDITOR.dialog.cancelButton], | ||
3063 | onOk: function() { | ||
3064 | sendAllOptions(); | ||
3065 | OptionsTextError.getElement().hide(); | ||
3066 | OptionsTextError.getElement().setHtml(' '); | ||
3067 | }, | ||
3068 | onLoad: function() { | ||
3069 | dialog = this; | ||
3070 | // appTools.postMessage.init(cameOptions); | ||
3071 | |||
3072 | linkOnCheckbox['IgnoreAllCapsWords'] = dialog.getContentElement('OptionsTab', 'IgnoreAllCapsWords'); | ||
3073 | linkOnCheckbox['IgnoreWordsNumbers'] = dialog.getContentElement('OptionsTab', 'IgnoreWordsNumbers'); | ||
3074 | linkOnCheckbox['IgnoreMixedCaseWords'] = dialog.getContentElement('OptionsTab', 'IgnoreMixedCaseWords'); | ||
3075 | linkOnCheckbox['IgnoreDomainNames'] = dialog.getContentElement('OptionsTab', 'IgnoreDomainNames'); | ||
3076 | |||
3077 | }, | ||
3078 | onShow: function() { | ||
3079 | appTools.postMessage.init(cameOptions); | ||
3080 | setHandlerOptions(); | ||
3081 | |||
3082 | (!parseInt(checkboxState['IgnoreAllCapsWords'], 10)) ? linkOnCheckbox['IgnoreAllCapsWords'].setValue('', false) : linkOnCheckbox['IgnoreAllCapsWords'].setValue('checked', false); | ||
3083 | (!parseInt(checkboxState['IgnoreWordsNumbers'], 10)) ? linkOnCheckbox['IgnoreWordsNumbers'].setValue('', false) : linkOnCheckbox['IgnoreWordsNumbers'].setValue('checked', false); | ||
3084 | (!parseInt(checkboxState['IgnoreMixedCaseWords'], 10)) ? linkOnCheckbox['IgnoreMixedCaseWords'].setValue('', false) : linkOnCheckbox['IgnoreMixedCaseWords'].setValue('checked', false); | ||
3085 | (!parseInt(checkboxState['IgnoreDomainNames'], 10)) ? linkOnCheckbox['IgnoreDomainNames'].setValue('', false) : linkOnCheckbox['IgnoreDomainNames'].setValue('checked', false); | ||
3086 | |||
3087 | checkboxState['IgnoreAllCapsWords'] = (!linkOnCheckbox['IgnoreAllCapsWords'].getValue()) ? 0 : 1; | ||
3088 | checkboxState['IgnoreWordsNumbers'] = (!linkOnCheckbox['IgnoreWordsNumbers'].getValue()) ? 0 : 1; | ||
3089 | checkboxState['IgnoreMixedCaseWords'] = (!linkOnCheckbox['IgnoreMixedCaseWords'].getValue()) ? 0 : 1; | ||
3090 | checkboxState['IgnoreDomainNames'] = (!linkOnCheckbox['IgnoreDomainNames'].getValue()) ? 0 : 1; | ||
3091 | |||
3092 | linkOnCheckbox['IgnoreAllCapsWords'].getElement().$.lastChild.innerHTML = NS.LocalizationComing['IgnoreAllCapsWords']; | ||
3093 | linkOnCheckbox['IgnoreWordsNumbers'].getElement().$.lastChild.innerHTML = NS.LocalizationComing['IgnoreWordsWithNumbers']; | ||
3094 | linkOnCheckbox['IgnoreMixedCaseWords'].getElement().$.lastChild.innerHTML = NS.LocalizationComing['IgnoreMixedCaseWords']; | ||
3095 | linkOnCheckbox['IgnoreDomainNames'].getElement().$.lastChild.innerHTML = NS.LocalizationComing['IgnoreDomainNames']; | ||
3096 | }, | ||
3097 | onHide: function() { | ||
3098 | appTools.postMessage.unbindHandler(cameOptions); | ||
3099 | if(activeElement) { | ||
3100 | try { | ||
3101 | activeElement.focus(); | ||
3102 | } catch(e) {} | ||
3103 | } | ||
3104 | } | ||
3105 | }; | ||
3106 | }); | ||
3107 | |||
3108 | // Expand the spell-check frame when dialog resized. (#6829) | ||
3109 | CKEDITOR.dialog.on( 'resize', function( evt ) { | ||
3110 | var data = evt.data, | ||
3111 | dialog = data.dialog, | ||
3112 | currentTabId = dialog._.currentTabId, | ||
3113 | tabID = NS.iframeNumber + '_' + currentTabId, | ||
3114 | iframe = CKEDITOR.document.getById(tabID); | ||
3115 | |||
3116 | if ( dialog._.name == 'checkspell' ) { | ||
3117 | if (NS.bnr) { | ||
3118 | iframe && iframe.setSize( 'height', data.height - '310' ); | ||
3119 | } else { | ||
3120 | iframe && iframe.setSize( 'height', data.height - '220' ); | ||
3121 | } | ||
3122 | |||
3123 | // add flag that indicate whether dialog has been resized by user | ||
3124 | if(dialog._.fromResizeEvent && !dialog._.resized) { | ||
3125 | dialog._.resized = true; | ||
3126 | } | ||
3127 | dialog._.fromResizeEvent = true; | ||
3128 | } | ||
3129 | }); | ||
3130 | |||
3131 | CKEDITOR.on('dialogDefinition', function(dialogDefinitionEvent) { | ||
3132 | |||
3133 | if(dialogDefinitionEvent.data.name === 'checkspell') { | ||
3134 | var dialogDefinition = dialogDefinitionEvent.data.definition; | ||
3135 | |||
3136 | NS.onLoadOverlay = new overlayBlock({ | ||
3137 | opacity: "1", | ||
3138 | background: "#fff", | ||
3139 | target: dialogDefinition.dialog.parts.tabs.getParent().$ | ||
3140 | }); | ||
3141 | |||
3142 | NS.onLoadOverlay.setEnable(); | ||
3143 | |||
3144 | dialogDefinition.dialog.on('cancel', function(cancelEvent) { | ||
3145 | dialogDefinition.dialog.getParentEditor().config.wsc_onClose.call(this.document.getWindow().getFrame()); | ||
3146 | NS.div_overlay.setDisable(); | ||
3147 | NS.onLoadOverlay.setDisable(); | ||
3148 | return false; | ||
3149 | }, this, null, -1); | ||
3150 | } | ||
3151 | }); | ||
3152 | })(); | ||
diff --git a/sources/plugins/wsc/dialogs/wsc_ie.js b/sources/plugins/wsc/dialogs/wsc_ie.js new file mode 100644 index 00000000..f47e507f --- /dev/null +++ b/sources/plugins/wsc/dialogs/wsc_ie.js | |||
@@ -0,0 +1,176 @@ | |||
1 | /** | ||
2 | * @license Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | * For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | |||
6 | CKEDITOR.dialog.add( 'checkspell', function( editor ) { | ||
7 | var number = CKEDITOR.tools.getNextNumber(), | ||
8 | iframeId = 'cke_frame_' + number, | ||
9 | textareaId = 'cke_data_' + number, | ||
10 | errorBoxId = 'cke_error_' + number, | ||
11 | interval, | ||
12 | protocol = document.location.protocol || 'http:', | ||
13 | errorMsg = editor.lang.wsc.notAvailable; | ||
14 | |||
15 | var pasteArea = | ||
16 | '<textarea' + | ||
17 | ' style="display: none"' + | ||
18 | ' id="' + textareaId + '"' + | ||
19 | ' rows="10"' + | ||
20 | ' cols="40">' + | ||
21 | ' </textarea><div' + | ||
22 | ' id="' + errorBoxId + '"' + | ||
23 | ' style="display:none;color:red;font-size:16px;font-weight:bold;padding-top:160px;text-align:center;z-index:11;">' + | ||
24 | '</div><iframe' + | ||
25 | ' src=""' + | ||
26 | ' style="width:100%;background-color:#f1f1e3;"' + | ||
27 | ' frameborder="0"' + | ||
28 | ' name="' + iframeId + '"' + | ||
29 | ' id="' + iframeId + '"' + | ||
30 | ' allowtransparency="1">' + | ||
31 | '</iframe>'; | ||
32 | |||
33 | var wscCoreUrl = editor.config.wsc_customLoaderScript || ( protocol + '//loader.webspellchecker.net/sproxy_fck/sproxy.php' + '?plugin=fck2' | ||
34 | + '&customerid=' + editor.config.wsc_customerId | ||
35 | + '&cmd=script&doc=wsc&schema=22' | ||
36 | ); | ||
37 | |||
38 | if ( editor.config.wsc_customLoaderScript ) { | ||
39 | errorMsg += '<p style="color:#000;font-size:11px;font-weight: normal;text-align:center;padding-top:10px">' + | ||
40 | editor.lang.wsc.errorLoading.replace( /%s/g, editor.config.wsc_customLoaderScript ) + '</p>'; | ||
41 | } | ||
42 | |||
43 | function burnSpelling( dialog, errorMsg ) { | ||
44 | var i = 0; | ||
45 | return function() { | ||
46 | if ( typeof( window.doSpell ) == 'function' ) { | ||
47 | //Call from window.setInteval expected at once. | ||
48 | if ( typeof( interval ) != 'undefined' ) | ||
49 | window.clearInterval( interval ); | ||
50 | |||
51 | initAndSpell( dialog ); | ||
52 | } else if ( i++ == 180 ) // Timeout: 180 * 250ms = 45s. | ||
53 | window._cancelOnError( errorMsg ); | ||
54 | }; | ||
55 | } | ||
56 | |||
57 | window._cancelOnError = function( m ) { | ||
58 | if ( typeof( window.WSC_Error ) == 'undefined' ) { | ||
59 | CKEDITOR.document.getById( iframeId ).setStyle( 'display', 'none' ); | ||
60 | var errorBox = CKEDITOR.document.getById( errorBoxId ); | ||
61 | errorBox.setStyle( 'display', 'block' ); | ||
62 | errorBox.setHtml( m || editor.lang.wsc.notAvailable ); | ||
63 | } | ||
64 | }; | ||
65 | |||
66 | function initAndSpell( dialog ) { | ||
67 | var LangComparer = new window._SP_FCK_LangCompare(), | ||
68 | // Language abbr standarts comparer. | ||
69 | pluginPath = CKEDITOR.getUrl( editor.plugins.wsc.path + 'dialogs/' ), | ||
70 | // Service paths corecting/preparing. | ||
71 | framesetPath = pluginPath + 'tmpFrameset.html'; | ||
72 | |||
73 | // global var is used in FCK specific core | ||
74 | // change on equal var used in fckplugin.js | ||
75 | window.gFCKPluginName = 'wsc'; | ||
76 | |||
77 | LangComparer.setDefaulLangCode( editor.config.defaultLanguage ); | ||
78 | |||
79 | window.doSpell({ | ||
80 | ctrl: textareaId, | ||
81 | |||
82 | lang: editor.config.wsc_lang || LangComparer.getSPLangCode( editor.langCode ), | ||
83 | intLang: editor.config.wsc_uiLang || LangComparer.getSPLangCode( editor.langCode ), | ||
84 | winType: iframeId, // If not defined app will run on winpopup. | ||
85 | |||
86 | // Callback binding section. | ||
87 | onCancel: function() { | ||
88 | dialog.hide(); | ||
89 | }, | ||
90 | onFinish: function( dT ) { | ||
91 | editor.focus(); | ||
92 | dialog.getParentEditor().setData( dT.value ); | ||
93 | dialog.hide(); | ||
94 | }, | ||
95 | |||
96 | // Some manipulations with client static pages. | ||
97 | staticFrame: framesetPath, | ||
98 | framesetPath: framesetPath, | ||
99 | iframePath: pluginPath + 'ciframe.html', | ||
100 | |||
101 | // Styles defining. | ||
102 | schemaURI: pluginPath + 'wsc.css', | ||
103 | |||
104 | userDictionaryName: editor.config.wsc_userDictionaryName, | ||
105 | customDictionaryName: editor.config.wsc_customDictionaryIds && editor.config.wsc_customDictionaryIds.split( "," ), | ||
106 | domainName: editor.config.wsc_domainName | ||
107 | |||
108 | }); | ||
109 | |||
110 | // Hide user message console (if application was loaded more then after timeout). | ||
111 | CKEDITOR.document.getById( errorBoxId ).setStyle( 'display', 'none' ); | ||
112 | CKEDITOR.document.getById( iframeId ).setStyle( 'display', 'block' ); | ||
113 | } | ||
114 | |||
115 | return { | ||
116 | title: editor.config.wsc_dialogTitle || editor.lang.wsc.title, | ||
117 | minWidth: 485, | ||
118 | minHeight: 380, | ||
119 | buttons: [ CKEDITOR.dialog.cancelButton ], | ||
120 | onShow: function() { | ||
121 | var contentArea = this.getContentElement( 'general', 'content' ).getElement(); | ||
122 | contentArea.setHtml( pasteArea ); | ||
123 | contentArea.getChild( 2 ).setStyle( 'height', this._.contentSize.height + 'px' ); | ||
124 | |||
125 | if ( typeof( window.doSpell ) != 'function' ) { | ||
126 | // Load script. | ||
127 | CKEDITOR.document.getHead().append( CKEDITOR.document.createElement( 'script', { | ||
128 | attributes: { | ||
129 | type: 'text/javascript', | ||
130 | src: wscCoreUrl | ||
131 | } | ||
132 | })); | ||
133 | } | ||
134 | |||
135 | var sData = editor.getData(); // Get the data to be checked. | ||
136 | |||
137 | CKEDITOR.document.getById( textareaId ).setValue( sData ); | ||
138 | |||
139 | interval = window.setInterval( burnSpelling( this, errorMsg ), 250 ); | ||
140 | }, | ||
141 | onHide: function() { | ||
142 | window.ooo = undefined; | ||
143 | window.int_framsetLoaded = undefined; | ||
144 | window.framesetLoaded = undefined; | ||
145 | window.is_window_opened = false; | ||
146 | }, | ||
147 | contents: [ | ||
148 | { | ||
149 | id: 'general', | ||
150 | label: editor.config.wsc_dialogTitle || editor.lang.wsc.title, | ||
151 | padding: 0, | ||
152 | elements: [ | ||
153 | { | ||
154 | type: 'html', | ||
155 | id: 'content', | ||
156 | html: '' | ||
157 | } | ||
158 | ] | ||
159 | } | ||
160 | ] | ||
161 | }; | ||
162 | }); | ||
163 | |||
164 | // Expand the spell-check frame when dialog resized. (#6829) | ||
165 | CKEDITOR.dialog.on( 'resize', function( evt ) { | ||
166 | var data = evt.data, | ||
167 | dialog = data.dialog; | ||
168 | |||
169 | if ( dialog._.name == 'checkspell' ) { | ||
170 | var content = dialog.getContentElement( 'general', 'content' ).getElement(), | ||
171 | iframe = content && content.getChild( 2 ); | ||
172 | |||
173 | iframe && iframe.setSize( 'height', data.height ); | ||
174 | iframe && iframe.setSize( 'width', data.width ); | ||
175 | } | ||
176 | }); | ||
diff --git a/sources/plugins/wsc/icons/hidpi/spellchecker.png b/sources/plugins/wsc/icons/hidpi/spellchecker.png new file mode 100644 index 00000000..58a9f4c1 --- /dev/null +++ b/sources/plugins/wsc/icons/hidpi/spellchecker.png | |||
Binary files differ | |||
diff --git a/sources/plugins/wsc/icons/spellchecker.png b/sources/plugins/wsc/icons/spellchecker.png new file mode 100644 index 00000000..2b50c5c6 --- /dev/null +++ b/sources/plugins/wsc/icons/spellchecker.png | |||
Binary files differ | |||
diff --git a/sources/plugins/wsc/lang/af.js b/sources/plugins/wsc/lang/af.js new file mode 100644 index 00000000..9caf6f7e --- /dev/null +++ b/sources/plugins/wsc/lang/af.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'af', { | ||
6 | btnIgnore: 'Ignoreer', | ||
7 | btnIgnoreAll: 'Ignoreer alles', | ||
8 | btnReplace: 'Vervang', | ||
9 | btnReplaceAll: 'vervang alles', | ||
10 | btnUndo: 'Ontdoen', | ||
11 | changeTo: 'Verander na', | ||
12 | errorLoading: 'Fout by inlaai van diens: %s.', | ||
13 | ieSpellDownload: 'Speltoetser is nie geïnstalleer nie. Wil u dit nou aflaai?', | ||
14 | manyChanges: 'Klaar met speltoets: %1 woorde verander', | ||
15 | noChanges: 'Klaar met speltoets: Geen woorde verander nie', | ||
16 | noMispell: 'Klaar met speltoets: Geen foute nie', | ||
17 | noSuggestions: '- Geen voorstel -', | ||
18 | notAvailable: 'Jammer, hierdie diens is nie nou beskikbaar nie.', | ||
19 | notInDic: 'Nie in woordeboek nie', | ||
20 | oneChange: 'Klaar met speltoets: Een woord verander', | ||
21 | progress: 'Spelling word getoets...', | ||
22 | title: 'Speltoetser', | ||
23 | toolbar: 'Speltoets' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/ar.js b/sources/plugins/wsc/lang/ar.js new file mode 100644 index 00000000..f152dc15 --- /dev/null +++ b/sources/plugins/wsc/lang/ar.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'ar', { | ||
6 | btnIgnore: 'تجاهل', | ||
7 | btnIgnoreAll: 'تجاهل الكل', | ||
8 | btnReplace: 'تغيير', | ||
9 | btnReplaceAll: 'تغيير الكل', | ||
10 | btnUndo: 'تراجع', | ||
11 | changeTo: 'التغيير إلى', | ||
12 | errorLoading: 'خطأ في تحميل تطبيق خدمة الاستضافة: %s.', | ||
13 | ieSpellDownload: 'المدقق الإملائي (الإنجليزي) غير مثبّت. هل تود تحميله الآن؟', | ||
14 | manyChanges: 'تم إكمال التدقيق الإملائي: تم تغيير %1 من كلمات', | ||
15 | noChanges: 'تم التدقيق الإملائي: لم يتم تغيير أي كلمة', | ||
16 | noMispell: 'تم التدقيق الإملائي: لم يتم العثور على أي أخطاء إملائية', | ||
17 | noSuggestions: '- لا توجد إقتراحات -', | ||
18 | notAvailable: 'عفواً، ولكن هذه الخدمة غير متاحة الان', | ||
19 | notInDic: 'ليست في القاموس', | ||
20 | oneChange: 'تم التدقيق الإملائي: تم تغيير كلمة واحدة فقط', | ||
21 | progress: 'جاري التدقيق الاملائى', | ||
22 | title: 'التدقيق الإملائي', | ||
23 | toolbar: 'تدقيق إملائي' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/bg.js b/sources/plugins/wsc/lang/bg.js new file mode 100644 index 00000000..e814a9f2 --- /dev/null +++ b/sources/plugins/wsc/lang/bg.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'bg', { | ||
6 | btnIgnore: 'Игнорирай', | ||
7 | btnIgnoreAll: 'Игнорирай всичко', | ||
8 | btnReplace: 'Препокриване', | ||
9 | btnReplaceAll: 'Препокрий всичко', | ||
10 | btnUndo: 'Възтанови', | ||
11 | changeTo: 'Промени на', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Spell checker not installed. Do you want to download it now?', | ||
14 | manyChanges: 'Spell check complete: %1 words changed', | ||
15 | noChanges: 'Spell check complete: No words changed', | ||
16 | noMispell: 'Spell check complete: No misspellings found', | ||
17 | noSuggestions: '- Няма препоръчани -', | ||
18 | notAvailable: 'Съжаляваме, но услугата не е достъпна за момента', | ||
19 | notInDic: 'Не е в речника', | ||
20 | oneChange: 'Spell check complete: One word changed', | ||
21 | progress: 'Проверява се правописа...', | ||
22 | title: 'Проверка на правопис', | ||
23 | toolbar: 'Проверка на правопис' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/bn.js b/sources/plugins/wsc/lang/bn.js new file mode 100644 index 00000000..03a38130 --- /dev/null +++ b/sources/plugins/wsc/lang/bn.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'bn', { | ||
6 | btnIgnore: 'ইগনোর কর', | ||
7 | btnIgnoreAll: 'সব ইগনোর কর', | ||
8 | btnReplace: 'বদলে দাও', | ||
9 | btnReplaceAll: 'সব বদলে দাও', | ||
10 | btnUndo: 'আন্ডু', | ||
11 | changeTo: 'এতে বদলাও', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'বানান পরীক্ষক ইনস্টল করা নেই। আপনি কি এখনই এটা ডাউনলোড করতে চান?', | ||
14 | manyChanges: 'বানান পরীক্ষা শেষ: %1 গুলো শব্দ বদলে গ্যাছে', | ||
15 | noChanges: 'বানান পরীক্ষা শেষ: কোন শব্দ পরিবর্তন করা হয়নি', | ||
16 | noMispell: 'বানান পরীক্ষা শেষ: কোন ভুল বানান পাওয়া যায়নি', | ||
17 | noSuggestions: '- কোন সাজেশন নেই -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'শব্দকোষে নেই', | ||
20 | oneChange: 'বানান পরীক্ষা শেষ: একটি মাত্র শব্দ পরিবর্তন করা হয়েছে', | ||
21 | progress: 'বানান পরীক্ষা চলছে...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'বানান চেক' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/bs.js b/sources/plugins/wsc/lang/bs.js new file mode 100644 index 00000000..b40859c8 --- /dev/null +++ b/sources/plugins/wsc/lang/bs.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'bs', { | ||
6 | btnIgnore: 'Ignore', | ||
7 | btnIgnoreAll: 'Ignore All', | ||
8 | btnReplace: 'Replace', | ||
9 | btnReplaceAll: 'Replace All', | ||
10 | btnUndo: 'Undo', | ||
11 | changeTo: 'Change to', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Spell checker not installed. Do you want to download it now?', | ||
14 | manyChanges: 'Spell check complete: %1 words changed', | ||
15 | noChanges: 'Spell check complete: No words changed', | ||
16 | noMispell: 'Spell check complete: No misspellings found', | ||
17 | noSuggestions: '- No suggestions -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Not in dictionary', | ||
20 | oneChange: 'Spell check complete: One word changed', | ||
21 | progress: 'Spell check in progress...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Check Spelling' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/ca.js b/sources/plugins/wsc/lang/ca.js new file mode 100644 index 00000000..857cfaa0 --- /dev/null +++ b/sources/plugins/wsc/lang/ca.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'ca', { | ||
6 | btnIgnore: 'Ignora', | ||
7 | btnIgnoreAll: 'Ignora-les totes', | ||
8 | btnReplace: 'Canvia', | ||
9 | btnReplaceAll: 'Canvia-les totes', | ||
10 | btnUndo: 'Desfés', | ||
11 | changeTo: 'Reemplaça amb', | ||
12 | errorLoading: 'Error carregant el servidor: %s.', | ||
13 | ieSpellDownload: 'Verificació ortogràfica no instal·lada. Voleu descarregar-ho ara?', | ||
14 | manyChanges: 'Verificació ortogràfica: s\'han canviat %1 paraules', | ||
15 | noChanges: 'Verificació ortogràfica: no s\'ha canviat cap paraula', | ||
16 | noMispell: 'Verificació ortogràfica acabada: no hi ha cap paraula mal escrita', | ||
17 | noSuggestions: 'Cap suggeriment', | ||
18 | notAvailable: 'El servei no es troba disponible ara.', | ||
19 | notInDic: 'No és al diccionari', | ||
20 | oneChange: 'Verificació ortogràfica: s\'ha canviat una paraula', | ||
21 | progress: 'Verificació ortogràfica en curs...', | ||
22 | title: 'Comprova l\'ortografia', | ||
23 | toolbar: 'Revisa l\'ortografia' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/cs.js b/sources/plugins/wsc/lang/cs.js new file mode 100644 index 00000000..fcda7f01 --- /dev/null +++ b/sources/plugins/wsc/lang/cs.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'cs', { | ||
6 | btnIgnore: 'Přeskočit', | ||
7 | btnIgnoreAll: 'Přeskakovat vše', | ||
8 | btnReplace: 'Zaměnit', | ||
9 | btnReplaceAll: 'Zaměňovat vše', | ||
10 | btnUndo: 'Zpět', | ||
11 | changeTo: 'Změnit na', | ||
12 | errorLoading: 'Chyba nahrávání služby aplikace z: %s.', | ||
13 | ieSpellDownload: 'Kontrola pravopisu není nainstalována. Chcete ji nyní stáhnout?', | ||
14 | manyChanges: 'Kontrola pravopisu dokončena: %1 slov změněno', | ||
15 | noChanges: 'Kontrola pravopisu dokončena: Beze změn', | ||
16 | noMispell: 'Kontrola pravopisu dokončena: Žádné pravopisné chyby nenalezeny', | ||
17 | noSuggestions: '- žádné návrhy -', | ||
18 | notAvailable: 'Omlouváme se, ale služba nyní není dostupná.', | ||
19 | notInDic: 'Není ve slovníku', | ||
20 | oneChange: 'Kontrola pravopisu dokončena: Jedno slovo změněno', | ||
21 | progress: 'Probíhá kontrola pravopisu...', | ||
22 | title: 'Kontrola pravopisu', | ||
23 | toolbar: 'Zkontrolovat pravopis' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/cy.js b/sources/plugins/wsc/lang/cy.js new file mode 100644 index 00000000..308de25c --- /dev/null +++ b/sources/plugins/wsc/lang/cy.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'cy', { | ||
6 | btnIgnore: 'Anwybyddu Un', | ||
7 | btnIgnoreAll: 'Anwybyddu Pob', | ||
8 | btnReplace: 'Amnewid Un', | ||
9 | btnReplaceAll: 'Amnewid Pob', | ||
10 | btnUndo: 'Dadwneud', | ||
11 | changeTo: 'Newid i', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Gwirydd sillafu heb ei arsefydlu. A ydych am ei lawrlwytho nawr?', | ||
14 | manyChanges: 'Gwirio sillafu wedi gorffen: Newidiwyd %1 gair', | ||
15 | noChanges: 'Gwirio sillafu wedi gorffen: Dim newidiadau', | ||
16 | noMispell: 'Gwirio sillafu wedi gorffen: Dim camsillaf.', | ||
17 | noSuggestions: '- Dim awgrymiadau -', | ||
18 | notAvailable: 'Nid yw\'r gwasanaeth hwn ar gael yn bresennol.', | ||
19 | notInDic: 'Nid i\'w gael yn y geiriadur', | ||
20 | oneChange: 'Gwirio sillafu wedi gorffen: Newidiwyd 1 gair', | ||
21 | progress: 'Gwirio sillafu yn ar y gweill...', | ||
22 | title: 'Gwirio Sillafu', | ||
23 | toolbar: 'Gwirio Sillafu' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/da.js b/sources/plugins/wsc/lang/da.js new file mode 100644 index 00000000..018984e6 --- /dev/null +++ b/sources/plugins/wsc/lang/da.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'da', { | ||
6 | btnIgnore: 'Ignorér', | ||
7 | btnIgnoreAll: 'Ignorér alle', | ||
8 | btnReplace: 'Erstat', | ||
9 | btnReplaceAll: 'Erstat alle', | ||
10 | btnUndo: 'Tilbage', | ||
11 | changeTo: 'Forslag', | ||
12 | errorLoading: 'Fejl ved indlæsning af host: %s.', | ||
13 | ieSpellDownload: 'Stavekontrol ikke installeret. Vil du installere den nu?', | ||
14 | manyChanges: 'Stavekontrol færdig: %1 ord ændret', | ||
15 | noChanges: 'Stavekontrol færdig: Ingen ord ændret', | ||
16 | noMispell: 'Stavekontrol færdig: Ingen fejl fundet', | ||
17 | noSuggestions: '(ingen forslag)', | ||
18 | notAvailable: 'Stavekontrol er desværre ikke tilgængelig.', | ||
19 | notInDic: 'Ikke i ordbogen', | ||
20 | oneChange: 'Stavekontrol færdig: Et ord ændret', | ||
21 | progress: 'Stavekontrollen arbejder...', | ||
22 | title: 'Stavekontrol', | ||
23 | toolbar: 'Stavekontrol' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/de.js b/sources/plugins/wsc/lang/de.js new file mode 100644 index 00000000..d8e541c5 --- /dev/null +++ b/sources/plugins/wsc/lang/de.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'de', { | ||
6 | btnIgnore: 'Ignorieren', | ||
7 | btnIgnoreAll: 'Alle Ignorieren', | ||
8 | btnReplace: 'Ersetzen', | ||
9 | btnReplaceAll: 'Alle Ersetzen', | ||
10 | btnUndo: 'Rückgängig', | ||
11 | changeTo: 'Ändern in', | ||
12 | errorLoading: 'Fehler beim laden des Dienstanbieters: %s.', | ||
13 | ieSpellDownload: 'Rechtschreibprüfung nicht installiert. Möchten Sie sie jetzt herunterladen?', | ||
14 | manyChanges: 'Rechtschreibprüfung abgeschlossen - %1 Wörter geändert', | ||
15 | noChanges: 'Rechtschreibprüfung abgeschlossen - keine Worte geändert', | ||
16 | noMispell: 'Rechtschreibprüfung abgeschlossen - keine Fehler gefunden', | ||
17 | noSuggestions: ' - keine Vorschläge - ', | ||
18 | notAvailable: 'Entschuldigung, aber dieser Dienst steht im Moment nicht zur Verfügung.', | ||
19 | notInDic: 'Nicht im Wörterbuch', | ||
20 | oneChange: 'Rechtschreibprüfung abgeschlossen - ein Wort geändert', | ||
21 | progress: 'Rechtschreibprüfung läuft...', | ||
22 | title: 'Rechtschreibprüfung', | ||
23 | toolbar: 'Rechtschreibprüfung' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/el.js b/sources/plugins/wsc/lang/el.js new file mode 100644 index 00000000..8bd15cb1 --- /dev/null +++ b/sources/plugins/wsc/lang/el.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'el', { | ||
6 | btnIgnore: 'Αγνόηση', | ||
7 | btnIgnoreAll: 'Αγνόηση όλων', | ||
8 | btnReplace: 'Αντικατάσταση', | ||
9 | btnReplaceAll: 'Αντικατάσταση όλων', | ||
10 | btnUndo: 'Αναίρεση', | ||
11 | changeTo: 'Αλλαγή σε', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Δεν υπάρχει εγκατεστημένος ορθογράφος. Θέλετε να τον κατεβάσετε τώρα;', | ||
14 | manyChanges: 'Ο ορθογραφικός έλεγχος ολοκληρώθηκε: Άλλαξαν %1 λέξεις', | ||
15 | noChanges: 'Ο ορθογραφικός έλεγχος ολοκληρώθηκε: Δεν άλλαξαν λέξεις', | ||
16 | noMispell: 'Ο ορθογραφικός έλεγχος ολοκληρώθηκε: Δεν βρέθηκαν λάθη', | ||
17 | noSuggestions: '- Δεν υπάρχουν προτάσεις -', | ||
18 | notAvailable: 'Η υπηρεσία δεν είναι διαθέσιμη αυτήν την στιγμή.', | ||
19 | notInDic: 'Δεν υπάρχει στο λεξικό', | ||
20 | oneChange: 'Ο ορθογραφικός έλεγχος ολοκληρώθηκε: Άλλαξε μια λέξη', | ||
21 | progress: 'Γίνεται ορθογραφικός έλεγχος...', | ||
22 | title: 'Ορθογραφικός Έλεγχος', | ||
23 | toolbar: 'Ορθογραφικός Έλεγχος' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/en-au.js b/sources/plugins/wsc/lang/en-au.js new file mode 100644 index 00000000..e03a9848 --- /dev/null +++ b/sources/plugins/wsc/lang/en-au.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'en-au', { | ||
6 | btnIgnore: 'Ignore', | ||
7 | btnIgnoreAll: 'Ignore All', | ||
8 | btnReplace: 'Replace', | ||
9 | btnReplaceAll: 'Replace All', | ||
10 | btnUndo: 'Undo', | ||
11 | changeTo: 'Change to', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Spell checker not installed. Do you want to download it now?', | ||
14 | manyChanges: 'Spell check complete: %1 words changed', | ||
15 | noChanges: 'Spell check complete: No words changed', | ||
16 | noMispell: 'Spell check complete: No misspellings found', | ||
17 | noSuggestions: '- No suggestions -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Not in dictionary', | ||
20 | oneChange: 'Spell check complete: One word changed', | ||
21 | progress: 'Spell check in progress...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Check Spelling' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/en-ca.js b/sources/plugins/wsc/lang/en-ca.js new file mode 100644 index 00000000..312d285c --- /dev/null +++ b/sources/plugins/wsc/lang/en-ca.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'en-ca', { | ||
6 | btnIgnore: 'Ignore', | ||
7 | btnIgnoreAll: 'Ignore All', | ||
8 | btnReplace: 'Replace', | ||
9 | btnReplaceAll: 'Replace All', | ||
10 | btnUndo: 'Undo', | ||
11 | changeTo: 'Change to', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Spell checker not installed. Do you want to download it now?', | ||
14 | manyChanges: 'Spell check complete: %1 words changed', | ||
15 | noChanges: 'Spell check complete: No words changed', | ||
16 | noMispell: 'Spell check complete: No misspellings found', | ||
17 | noSuggestions: '- No suggestions -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Not in dictionary', | ||
20 | oneChange: 'Spell check complete: One word changed', | ||
21 | progress: 'Spell check in progress...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Check Spelling' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/en-gb.js b/sources/plugins/wsc/lang/en-gb.js new file mode 100644 index 00000000..0f33b994 --- /dev/null +++ b/sources/plugins/wsc/lang/en-gb.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'en-gb', { | ||
6 | btnIgnore: 'Ignore', | ||
7 | btnIgnoreAll: 'Ignore All', | ||
8 | btnReplace: 'Replace', | ||
9 | btnReplaceAll: 'Replace All', | ||
10 | btnUndo: 'Undo', | ||
11 | changeTo: 'Change to', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Spell checker not installed. Do you want to download it now?', | ||
14 | manyChanges: 'Spell check complete: %1 words changed', | ||
15 | noChanges: 'Spell check complete: No words changed', | ||
16 | noMispell: 'Spell check complete: No misspellings found', | ||
17 | noSuggestions: '- No suggestions -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Not in dictionary', | ||
20 | oneChange: 'Spell check complete: One word changed', | ||
21 | progress: 'Spell check in progress...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Check Spelling' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/en.js b/sources/plugins/wsc/lang/en.js new file mode 100644 index 00000000..99b4bebf --- /dev/null +++ b/sources/plugins/wsc/lang/en.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'en', { | ||
6 | btnIgnore: 'Ignore', | ||
7 | btnIgnoreAll: 'Ignore All', | ||
8 | btnReplace: 'Replace', | ||
9 | btnReplaceAll: 'Replace All', | ||
10 | btnUndo: 'Undo', | ||
11 | changeTo: 'Change to', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Spell checker not installed. Do you want to download it now?', | ||
14 | manyChanges: 'Spell check complete: %1 words changed', | ||
15 | noChanges: 'Spell check complete: No words changed', | ||
16 | noMispell: 'Spell check complete: No misspellings found', | ||
17 | noSuggestions: '- No suggestions -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Not in dictionary', | ||
20 | oneChange: 'Spell check complete: One word changed', | ||
21 | progress: 'Spell check in progress...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Check Spelling' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/eo.js b/sources/plugins/wsc/lang/eo.js new file mode 100644 index 00000000..399e59ac --- /dev/null +++ b/sources/plugins/wsc/lang/eo.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'eo', { | ||
6 | btnIgnore: 'Ignori', | ||
7 | btnIgnoreAll: 'Ignori Ĉion', | ||
8 | btnReplace: 'Anstataŭigi', | ||
9 | btnReplaceAll: 'Anstataŭigi Ĉion', | ||
10 | btnUndo: 'Malfari', | ||
11 | changeTo: 'Ŝanĝi al', | ||
12 | errorLoading: 'Eraro en la servoelŝuto el la gastiga komputiko: %s.', | ||
13 | ieSpellDownload: 'Ortografikontrolilo ne instalita. Ĉu vi volas elŝuti ĝin nun?', | ||
14 | manyChanges: 'Ortografikontrolado finita: %1 vortoj korektitaj', | ||
15 | noChanges: 'Ortografikontrolado finita: neniu vorto korektita', | ||
16 | noMispell: 'Ortografikontrolado finita: neniu eraro trovita', | ||
17 | noSuggestions: '- Neniu propono -', | ||
18 | notAvailable: 'Bedaŭrinde la servo ne funkcias nuntempe.', | ||
19 | notInDic: 'Ne trovita en la vortaro', | ||
20 | oneChange: 'Ortografikontrolado finita: unu vorto korektita', | ||
21 | progress: 'La ortografio estas kontrolata...', | ||
22 | title: 'Kontroli la ortografion', | ||
23 | toolbar: 'Kontroli la ortografion' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/es.js b/sources/plugins/wsc/lang/es.js new file mode 100644 index 00000000..0284150d --- /dev/null +++ b/sources/plugins/wsc/lang/es.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'es', { | ||
6 | btnIgnore: 'Ignorar', | ||
7 | btnIgnoreAll: 'Ignorar Todo', | ||
8 | btnReplace: 'Reemplazar', | ||
9 | btnReplaceAll: 'Reemplazar Todo', | ||
10 | btnUndo: 'Deshacer', | ||
11 | changeTo: 'Cambiar a', | ||
12 | errorLoading: 'Error cargando la aplicación del servidor: %s.', | ||
13 | ieSpellDownload: 'Módulo de Control de Ortografía no instalado.\r\n¿Desea descargarlo ahora?', | ||
14 | manyChanges: 'Control finalizado: se ha cambiado %1 palabras', | ||
15 | noChanges: 'Control finalizado: no se ha cambiado ninguna palabra', | ||
16 | noMispell: 'Control finalizado: no se encontraron errores', | ||
17 | noSuggestions: '- No hay sugerencias -', | ||
18 | notAvailable: 'Lo sentimos pero el servicio no está disponible.', | ||
19 | notInDic: 'No se encuentra en el Diccionario', | ||
20 | oneChange: 'Control finalizado: se ha cambiado una palabra', | ||
21 | progress: 'Control de Ortografía en progreso...', | ||
22 | title: 'Comprobar ortografía', | ||
23 | toolbar: 'Ortografía' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/et.js b/sources/plugins/wsc/lang/et.js new file mode 100644 index 00000000..7e198459 --- /dev/null +++ b/sources/plugins/wsc/lang/et.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'et', { | ||
6 | btnIgnore: 'Ignoreeri', | ||
7 | btnIgnoreAll: 'Ignoreeri kõiki', | ||
8 | btnReplace: 'Asenda', | ||
9 | btnReplaceAll: 'Asenda kõik', | ||
10 | btnUndo: 'Võta tagasi', | ||
11 | changeTo: 'Muuda', | ||
12 | errorLoading: 'Viga rakenduse teenushosti laadimisel: %s.', | ||
13 | ieSpellDownload: 'Õigekirja kontrollija ei ole paigaldatud. Soovid sa selle alla laadida?', | ||
14 | manyChanges: 'Õigekirja kontroll sooritatud: %1 sõna muudetud', | ||
15 | noChanges: 'Õigekirja kontroll sooritatud: ühtegi sõna ei muudetud', | ||
16 | noMispell: 'Õigekirja kontroll sooritatud: õigekirjuvigu ei leitud', | ||
17 | noSuggestions: '- Soovitused puuduvad -', | ||
18 | notAvailable: 'Kahjuks ei ole teenus praegu saadaval.', | ||
19 | notInDic: 'Puudub sõnastikust', | ||
20 | oneChange: 'Õigekirja kontroll sooritatud: üks sõna muudeti', | ||
21 | progress: 'Toimub õigekirja kontroll...', | ||
22 | title: 'Õigekirjakontroll', | ||
23 | toolbar: 'Õigekirjakontroll' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/eu.js b/sources/plugins/wsc/lang/eu.js new file mode 100644 index 00000000..b079af03 --- /dev/null +++ b/sources/plugins/wsc/lang/eu.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'eu', { | ||
6 | btnIgnore: 'Ezikusi', | ||
7 | btnIgnoreAll: 'Denak Ezikusi', | ||
8 | btnReplace: 'Ordezkatu', | ||
9 | btnReplaceAll: 'Denak Ordezkatu', | ||
10 | btnUndo: 'Desegin', | ||
11 | changeTo: 'Honekin ordezkatu', | ||
12 | errorLoading: 'Errorea gertatu da aplikazioa zerbitzaritik kargatzean: %s.', | ||
13 | ieSpellDownload: 'Zuzentzaile ortografikoa ez dago instalatuta. Deskargatu nahi duzu?', | ||
14 | manyChanges: 'Zuzenketa ortografikoa bukatuta: %1 hitz aldatu dira', | ||
15 | noChanges: 'Zuzenketa ortografikoa bukatuta: Ez da ezer aldatu', | ||
16 | noMispell: 'Zuzenketa ortografikoa bukatuta: Akatsik ez', | ||
17 | noSuggestions: '- Iradokizunik ez -', | ||
18 | notAvailable: 'Barkatu baina momentu honetan zerbitzua ez dago erabilgarri.', | ||
19 | notInDic: 'Ez dago hiztegian', | ||
20 | oneChange: 'Zuzenketa ortografikoa bukatuta: Hitz bat aldatu da', | ||
21 | progress: 'Zuzenketa ortografikoa martxan...', | ||
22 | title: 'Ortografia zuzenketa', | ||
23 | toolbar: 'Ortografia' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/fa.js b/sources/plugins/wsc/lang/fa.js new file mode 100644 index 00000000..de7041bd --- /dev/null +++ b/sources/plugins/wsc/lang/fa.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'fa', { | ||
6 | btnIgnore: 'چشمپوشی', | ||
7 | btnIgnoreAll: 'چشمپوشی همه', | ||
8 | btnReplace: 'جایگزینی', | ||
9 | btnReplaceAll: 'جایگزینی همه', | ||
10 | btnUndo: 'واچینش', | ||
11 | changeTo: 'تغییر به', | ||
12 | errorLoading: 'خطا در بارگیری برنامه خدمات میزبان: %s.', | ||
13 | ieSpellDownload: 'بررسی کنندهٴ املا نصب نشده است. آیا میخواهید آن را هماکنون دریافت کنید؟', | ||
14 | manyChanges: 'بررسی املا انجام شد. %1 واژه تغییر یافت', | ||
15 | noChanges: 'بررسی املا انجام شد. هیچ واژهای تغییر نیافت', | ||
16 | noMispell: 'بررسی املا انجام شد. هیچ غلط املائی یافت نشد', | ||
17 | noSuggestions: '- پیشنهادی نیست -', | ||
18 | notAvailable: 'با عرض پوزش خدمات الان در دسترس نیستند.', | ||
19 | notInDic: 'در واژه~نامه یافت نشد', | ||
20 | oneChange: 'بررسی املا انجام شد. یک واژه تغییر یافت', | ||
21 | progress: 'بررسی املا در حال انجام...', | ||
22 | title: 'بررسی املا', | ||
23 | toolbar: 'بررسی املا' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/fi.js b/sources/plugins/wsc/lang/fi.js new file mode 100644 index 00000000..786404b9 --- /dev/null +++ b/sources/plugins/wsc/lang/fi.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'fi', { | ||
6 | btnIgnore: 'Jätä huomioimatta', | ||
7 | btnIgnoreAll: 'Jätä kaikki huomioimatta', | ||
8 | btnReplace: 'Korvaa', | ||
9 | btnReplaceAll: 'Korvaa kaikki', | ||
10 | btnUndo: 'Kumoa', | ||
11 | changeTo: 'Vaihda', | ||
12 | errorLoading: 'Virhe ladattaessa oikolukupalvelua isännältä: %s.', | ||
13 | ieSpellDownload: 'Oikeinkirjoituksen tarkistusta ei ole asennettu. Haluatko ladata sen nyt?', | ||
14 | manyChanges: 'Tarkistus valmis: %1 sanaa muutettiin', | ||
15 | noChanges: 'Tarkistus valmis: Yhtään sanaa ei muutettu', | ||
16 | noMispell: 'Tarkistus valmis: Ei virheitä', | ||
17 | noSuggestions: 'Ei ehdotuksia', | ||
18 | notAvailable: 'Valitettavasti oikoluku ei ole käytössä tällä hetkellä.', | ||
19 | notInDic: 'Ei sanakirjassa', | ||
20 | oneChange: 'Tarkistus valmis: Yksi sana muutettiin', | ||
21 | progress: 'Tarkistus käynnissä...', | ||
22 | title: 'Oikoluku', | ||
23 | toolbar: 'Tarkista oikeinkirjoitus' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/fo.js b/sources/plugins/wsc/lang/fo.js new file mode 100644 index 00000000..0cf829a8 --- /dev/null +++ b/sources/plugins/wsc/lang/fo.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'fo', { | ||
6 | btnIgnore: 'Forfjóna', | ||
7 | btnIgnoreAll: 'Forfjóna alt', | ||
8 | btnReplace: 'Yvirskriva', | ||
9 | btnReplaceAll: 'Yvirskriva alt', | ||
10 | btnUndo: 'Angra', | ||
11 | changeTo: 'Broyt til', | ||
12 | errorLoading: 'Feilur við innlesing av application service host: %s.', | ||
13 | ieSpellDownload: 'Rættstavarin er ikki tøkur í tekstviðgeranum. Vilt tú heinta hann nú?', | ||
14 | manyChanges: 'Rættstavarin liðugur: %1 orð broytt', | ||
15 | noChanges: 'Rættstavarin liðugur: Einki orð varð broytt', | ||
16 | noMispell: 'Rættstavarin liðugur: Eingin feilur funnin', | ||
17 | noSuggestions: '- Einki uppskot -', | ||
18 | notAvailable: 'Tíverri, ikki tøkt í løtuni.', | ||
19 | notInDic: 'Finst ikki í orðabókini', | ||
20 | oneChange: 'Rættstavarin liðugur: Eitt orð er broytt', | ||
21 | progress: 'Rættstavarin arbeiðir...', | ||
22 | title: 'Kanna stavseting', | ||
23 | toolbar: 'Kanna stavseting' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/fr-ca.js b/sources/plugins/wsc/lang/fr-ca.js new file mode 100644 index 00000000..37f84c8a --- /dev/null +++ b/sources/plugins/wsc/lang/fr-ca.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'fr-ca', { | ||
6 | btnIgnore: 'Ignorer', | ||
7 | btnIgnoreAll: 'Ignorer tout', | ||
8 | btnReplace: 'Remplacer', | ||
9 | btnReplaceAll: 'Remplacer tout', | ||
10 | btnUndo: 'Annuler', | ||
11 | changeTo: 'Changer en', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Le Correcteur d\'orthographe n\'est pas installé. Souhaitez-vous le télécharger maintenant?', | ||
14 | manyChanges: 'Vérification d\'orthographe terminée: %1 mots modifiés', | ||
15 | noChanges: 'Vérification d\'orthographe terminée: Pas de modifications', | ||
16 | noMispell: 'Vérification d\'orthographe terminée: pas d\'erreur trouvée', | ||
17 | noSuggestions: '- Pas de suggestion -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Pas dans le dictionnaire', | ||
20 | oneChange: 'Vérification d\'orthographe terminée: Un mot modifié', | ||
21 | progress: 'Vérification d\'orthographe en cours...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Orthographe' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/fr.js b/sources/plugins/wsc/lang/fr.js new file mode 100644 index 00000000..f442bd9d --- /dev/null +++ b/sources/plugins/wsc/lang/fr.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'fr', { | ||
6 | btnIgnore: 'Ignorer', | ||
7 | btnIgnoreAll: 'Ignorer tout', | ||
8 | btnReplace: 'Remplacer', | ||
9 | btnReplaceAll: 'Remplacer tout', | ||
10 | btnUndo: 'Annuler', | ||
11 | changeTo: 'Modifier pour', | ||
12 | errorLoading: 'Erreur du chargement du service depuis l\'hôte : %s.', | ||
13 | ieSpellDownload: 'La vérification d\'orthographe n\'est pas installée. Voulez-vous la télécharger maintenant?', | ||
14 | manyChanges: 'Vérification de l\'orthographe terminée : %1 mots corrigés.', | ||
15 | noChanges: 'Vérification de l\'orthographe terminée : Aucun mot corrigé.', | ||
16 | noMispell: 'Vérification de l\'orthographe terminée : aucune erreur trouvée.', | ||
17 | noSuggestions: '- Aucune suggestion -', | ||
18 | notAvailable: 'Désolé, le service est indisponible actuellement.', | ||
19 | notInDic: 'N\'existe pas dans le dictionnaire.', | ||
20 | oneChange: 'Vérification de l\'orthographe terminée : Un seul mot corrigé.', | ||
21 | progress: 'Vérification de l\'orthographe en cours...', | ||
22 | title: 'Vérifier l\'orthographe', | ||
23 | toolbar: 'Vérifier l\'orthographe' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/gl.js b/sources/plugins/wsc/lang/gl.js new file mode 100644 index 00000000..5da1ff7c --- /dev/null +++ b/sources/plugins/wsc/lang/gl.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'gl', { | ||
6 | btnIgnore: 'Ignorar', | ||
7 | btnIgnoreAll: 'Ignorar Todas', | ||
8 | btnReplace: 'Substituir', | ||
9 | btnReplaceAll: 'Substituir Todas', | ||
10 | btnUndo: 'Desfacer', | ||
11 | changeTo: 'Cambiar a', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'O corrector ortográfico non está instalado. ¿Quere descargalo agora?', | ||
14 | manyChanges: 'Corrección ortográfica rematada: %1 verbas substituidas', | ||
15 | noChanges: 'Corrección ortográfica rematada: Non se substituiu nengunha verba', | ||
16 | noMispell: 'Corrección ortográfica rematada: Non se atoparon erros', | ||
17 | noSuggestions: '- Sen candidatos -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Non está no diccionario', | ||
20 | oneChange: 'Corrección ortográfica rematada: Unha verba substituida', | ||
21 | progress: 'Corrección ortográfica en progreso...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Corrección Ortográfica' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/gu.js b/sources/plugins/wsc/lang/gu.js new file mode 100644 index 00000000..385d9f5b --- /dev/null +++ b/sources/plugins/wsc/lang/gu.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'gu', { | ||
6 | btnIgnore: 'ઇગ્નોર/અવગણના કરવી', | ||
7 | btnIgnoreAll: 'બધાની ઇગ્નોર/અવગણના કરવી', | ||
8 | btnReplace: 'બદલવું', | ||
9 | btnReplaceAll: 'બધા બદલી કરો', | ||
10 | btnUndo: 'અન્ડૂ', | ||
11 | changeTo: 'આનાથી બદલવું', | ||
12 | errorLoading: 'સર્વિસ એપ્લીકેશન લોડ નથી થ: %s.', | ||
13 | ieSpellDownload: 'સ્પેલ-ચેકર ઇન્સ્ટોલ નથી. શું તમે ડાઉનલોડ કરવા માંગો છો?', | ||
14 | manyChanges: 'શબ્દની જોડણી/સ્પેલ ચેક પૂર્ણ: %1 શબ્દ બદલયા છે', | ||
15 | noChanges: 'શબ્દની જોડણી/સ્પેલ ચેક પૂર્ણ: એકપણ શબ્દ બદલયો નથી', | ||
16 | noMispell: 'શબ્દની જોડણી/સ્પેલ ચેક પૂર્ણ: ખોટી જોડણી મળી નથી', | ||
17 | noSuggestions: '- કઇ સજેશન નથી -', | ||
18 | notAvailable: 'માફ કરશો, આ સુવિધા ઉપલબ્ધ નથી', | ||
19 | notInDic: 'શબ્દકોશમાં નથી', | ||
20 | oneChange: 'શબ્દની જોડણી/સ્પેલ ચેક પૂર્ણ: એક શબ્દ બદલયો છે', | ||
21 | progress: 'શબ્દની જોડણી/સ્પેલ ચેક ચાલુ છે...', | ||
22 | title: 'સ્પેલ ', | ||
23 | toolbar: 'જોડણી (સ્પેલિંગ) તપાસવી' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/he.js b/sources/plugins/wsc/lang/he.js new file mode 100644 index 00000000..4b78bde6 --- /dev/null +++ b/sources/plugins/wsc/lang/he.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'he', { | ||
6 | btnIgnore: 'התעלמות', | ||
7 | btnIgnoreAll: 'התעלמות מהכל', | ||
8 | btnReplace: 'החלפה', | ||
9 | btnReplaceAll: 'החלפת הכל', | ||
10 | btnUndo: 'החזרה', | ||
11 | changeTo: 'שינוי ל', | ||
12 | errorLoading: 'שגיאה בהעלאת השירות: %s.', | ||
13 | ieSpellDownload: 'בודק האיות לא מותקן, האם להורידו?', | ||
14 | manyChanges: 'בדיקות איות הסתיימה: %1 מילים שונו', | ||
15 | noChanges: 'בדיקות איות הסתיימה: לא שונתה אף מילה', | ||
16 | noMispell: 'בדיקות איות הסתיימה: לא נמצאו שגיאות כתיב', | ||
17 | noSuggestions: '- אין הצעות -', | ||
18 | notAvailable: 'לא נמצא שירות זמין.', | ||
19 | notInDic: 'לא נמצא במילון', | ||
20 | oneChange: 'בדיקות איות הסתיימה: שונתה מילה אחת', | ||
21 | progress: 'בודק האיות בתהליך בדיקה....', | ||
22 | title: 'בדיקת איות', | ||
23 | toolbar: 'בדיקת איות' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/hi.js b/sources/plugins/wsc/lang/hi.js new file mode 100644 index 00000000..bb1a4dbb --- /dev/null +++ b/sources/plugins/wsc/lang/hi.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'hi', { | ||
6 | btnIgnore: 'इग्नोर', | ||
7 | btnIgnoreAll: 'सभी इग्नोर करें', | ||
8 | btnReplace: 'रिप्लेस', | ||
9 | btnReplaceAll: 'सभी रिप्लेस करें', | ||
10 | btnUndo: 'अन्डू', | ||
11 | changeTo: 'इसमें बदलें', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'स्पॅल-चॅकर इन्स्टाल नहीं किया गया है। क्या आप इसे डाउनलोड करना चाहेंगे?', | ||
14 | manyChanges: 'वर्तनी की जाँच : %1 शब्द बदले गये', | ||
15 | noChanges: 'वर्तनी की जाँच :कोई शब्द नहीं बदला गया', | ||
16 | noMispell: 'वर्तनी की जाँच : कोई गलत वर्तनी (स्पॅलिंग) नहीं पाई गई', | ||
17 | noSuggestions: '- कोई सुझाव नहीं -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'शब्दकोश में नहीं', | ||
20 | oneChange: 'वर्तनी की जाँच : एक शब्द बदला गया', | ||
21 | progress: 'वर्तनी की जाँच (स्पॅल-चॅक) जारी है...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'वर्तनी (स्पेलिंग) जाँच' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/hr.js b/sources/plugins/wsc/lang/hr.js new file mode 100644 index 00000000..1094e079 --- /dev/null +++ b/sources/plugins/wsc/lang/hr.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'hr', { | ||
6 | btnIgnore: 'Zanemari', | ||
7 | btnIgnoreAll: 'Zanemari sve', | ||
8 | btnReplace: 'Zamijeni', | ||
9 | btnReplaceAll: 'Zamijeni sve', | ||
10 | btnUndo: 'Vrati', | ||
11 | changeTo: 'Promijeni u', | ||
12 | errorLoading: 'Greška učitavanja aplikacije: %s.', | ||
13 | ieSpellDownload: 'Provjera pravopisa nije instalirana. Želite li skinuti provjeru pravopisa?', | ||
14 | manyChanges: 'Provjera završena: Promijenjeno %1 riječi', | ||
15 | noChanges: 'Provjera završena: Nije napravljena promjena', | ||
16 | noMispell: 'Provjera završena: Nema grešaka', | ||
17 | noSuggestions: '-Nema preporuke-', | ||
18 | notAvailable: 'Žao nam je, ali usluga trenutno nije dostupna.', | ||
19 | notInDic: 'Nije u rječniku', | ||
20 | oneChange: 'Provjera završena: Jedna riječ promjenjena', | ||
21 | progress: 'Provjera u tijeku...', | ||
22 | title: 'Provjera pravopisa', | ||
23 | toolbar: 'Provjeri pravopis' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/hu.js b/sources/plugins/wsc/lang/hu.js new file mode 100644 index 00000000..9e442e75 --- /dev/null +++ b/sources/plugins/wsc/lang/hu.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'hu', { | ||
6 | btnIgnore: 'Kihagyja', | ||
7 | btnIgnoreAll: 'Mindet kihagyja', | ||
8 | btnReplace: 'Csere', | ||
9 | btnReplaceAll: 'Összes cseréje', | ||
10 | btnUndo: 'Visszavonás', | ||
11 | changeTo: 'Módosítás', | ||
12 | errorLoading: 'Hiba a szolgáltatás host betöltése közben: %s.', | ||
13 | ieSpellDownload: 'A helyesírás-ellenőrző nincs telepítve. Szeretné letölteni most?', | ||
14 | manyChanges: 'Helyesírás-ellenőrzés kész: %1 szó cserélve', | ||
15 | noChanges: 'Helyesírás-ellenőrzés kész: Nincs változtatott szó', | ||
16 | noMispell: 'Helyesírás-ellenőrzés kész: Nem találtam hibát', | ||
17 | noSuggestions: 'Nincs javaslat', | ||
18 | notAvailable: 'Sajnálom, de a szolgáltatás jelenleg nem elérhető.', | ||
19 | notInDic: 'Nincs a szótárban', | ||
20 | oneChange: 'Helyesírás-ellenőrzés kész: Egy szó cserélve', | ||
21 | progress: 'Helyesírás-ellenőrzés folyamatban...', | ||
22 | title: 'Helyesírás ellenörző', | ||
23 | toolbar: 'Helyesírás-ellenőrzés' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/is.js b/sources/plugins/wsc/lang/is.js new file mode 100644 index 00000000..96931692 --- /dev/null +++ b/sources/plugins/wsc/lang/is.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'is', { | ||
6 | btnIgnore: 'Hunsa', | ||
7 | btnIgnoreAll: 'Hunsa allt', | ||
8 | btnReplace: 'Skipta', | ||
9 | btnReplaceAll: 'Skipta öllu', | ||
10 | btnUndo: 'Til baka', | ||
11 | changeTo: 'Tillaga', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Villuleit ekki sett upp.<br>Viltu setja hana upp?', | ||
14 | manyChanges: 'Villuleit lokið: %1 orðum breytt', | ||
15 | noChanges: 'Villuleit lokið: Engu orði breytt', | ||
16 | noMispell: 'Villuleit lokið: Engin villa fannst', | ||
17 | noSuggestions: '- engar tillögur -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Ekki í orðabókinni', | ||
20 | oneChange: 'Villuleit lokið: Einu orði breytt', | ||
21 | progress: 'Villuleit í gangi...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Villuleit' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/it.js b/sources/plugins/wsc/lang/it.js new file mode 100644 index 00000000..6e28785e --- /dev/null +++ b/sources/plugins/wsc/lang/it.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'it', { | ||
6 | btnIgnore: 'Ignora', | ||
7 | btnIgnoreAll: 'Ignora tutto', | ||
8 | btnReplace: 'Cambia', | ||
9 | btnReplaceAll: 'Cambia tutto', | ||
10 | btnUndo: 'Annulla', | ||
11 | changeTo: 'Cambia in', | ||
12 | errorLoading: 'Errore nel caricamento dell\'host col servizio applicativo: %s.', | ||
13 | ieSpellDownload: 'Contollo ortografico non installato. Lo vuoi scaricare ora?', | ||
14 | manyChanges: 'Controllo ortografico completato: %1 parole cambiate', | ||
15 | noChanges: 'Controllo ortografico completato: nessuna parola cambiata', | ||
16 | noMispell: 'Controllo ortografico completato: nessun errore trovato', | ||
17 | noSuggestions: '- Nessun suggerimento -', | ||
18 | notAvailable: 'Il servizio non è momentaneamente disponibile.', | ||
19 | notInDic: 'Non nel dizionario', | ||
20 | oneChange: 'Controllo ortografico completato: 1 parola cambiata', | ||
21 | progress: 'Controllo ortografico in corso', | ||
22 | title: 'Controllo ortografico', | ||
23 | toolbar: 'Correttore ortografico' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/ja.js b/sources/plugins/wsc/lang/ja.js new file mode 100644 index 00000000..fe90d5e9 --- /dev/null +++ b/sources/plugins/wsc/lang/ja.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'ja', { | ||
6 | btnIgnore: '無視', | ||
7 | btnIgnoreAll: 'すべて無視', | ||
8 | btnReplace: '置換', | ||
9 | btnReplaceAll: 'すべて置換', | ||
10 | btnUndo: 'やり直し', | ||
11 | changeTo: '変更', | ||
12 | errorLoading: 'アプリケーションサービスホスト読込みエラー: %s.', | ||
13 | ieSpellDownload: 'スペルチェッカーがインストールされていません。今すぐダウンロードしますか?', | ||
14 | manyChanges: 'スペルチェック完了: %1 語句変更されました', | ||
15 | noChanges: 'スペルチェック完了: 語句は変更されませんでした', | ||
16 | noMispell: 'スペルチェック完了: スペルの誤りはありませんでした', | ||
17 | noSuggestions: '- 該当なし -', | ||
18 | notAvailable: '申し訳ありません、現在サービスを利用することができません', | ||
19 | notInDic: '辞書にありません', | ||
20 | oneChange: 'スペルチェック完了: 1語句変更されました', | ||
21 | progress: 'スペルチェック処理中...', | ||
22 | title: 'スペルチェック', | ||
23 | toolbar: 'スペルチェック' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/ka.js b/sources/plugins/wsc/lang/ka.js new file mode 100644 index 00000000..70cc4bed --- /dev/null +++ b/sources/plugins/wsc/lang/ka.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'ka', { | ||
6 | btnIgnore: 'უგულებელყოფა', | ||
7 | btnIgnoreAll: 'ყველას უგულებელყოფა', | ||
8 | btnReplace: 'შეცვლა', | ||
9 | btnReplaceAll: 'ყველას შეცვლა', | ||
10 | btnUndo: 'გაუქმება', | ||
11 | changeTo: 'შეცვლელი', | ||
12 | errorLoading: 'სერვისის გამოძახების შეცდომა: %s.', | ||
13 | ieSpellDownload: 'მართლწერის შემოწმება არაა დაინსტალირებული. ჩამოვქაჩოთ ინტერნეტიდან?', | ||
14 | manyChanges: 'მართლწერის შემოწმება: %1 სიტყვა შეიცვალა', | ||
15 | noChanges: 'მართლწერის შემოწმება: არაფერი შეცვლილა', | ||
16 | noMispell: 'მართლწერის შემოწმება: შეცდომა არ მოიძებნა', | ||
17 | noSuggestions: '- არაა შემოთავაზება -', | ||
18 | notAvailable: 'უკაცრავად, ეს სერვისი ამჟამად მიუწვდომელია.', | ||
19 | notInDic: 'არაა ლექსიკონში', | ||
20 | oneChange: 'მართლწერის შემოწმება: ერთი სიტყვა შეიცვალა', | ||
21 | progress: 'მიმდინარეობს მართლწერის შემოწმება...', | ||
22 | title: 'მართლწერა', | ||
23 | toolbar: 'მართლწერა' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/km.js b/sources/plugins/wsc/lang/km.js new file mode 100644 index 00000000..26693a6d --- /dev/null +++ b/sources/plugins/wsc/lang/km.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'km', { | ||
6 | btnIgnore: 'មិនផ្លាស់ប្តូរ', | ||
7 | btnIgnoreAll: 'មិនផ្លាស់ប្តូរ ទាំងអស់', | ||
8 | btnReplace: 'ជំនួស', | ||
9 | btnReplaceAll: 'ជំនួសទាំងអស់', | ||
10 | btnUndo: 'សារឡើងវិញ', | ||
11 | changeTo: 'ផ្លាស់ប្តូរទៅ', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'ពុំមានកម្មវិធីពិនិត្យអក្ខរាវិរុទ្ធ ។ តើចង់ទាញយកពីណា?', | ||
14 | manyChanges: 'ការពិនិត្យអក្ខរាវិរុទ្ធបានចប់: %1 ពាក្យបានផ្លាស់ប្តូរ', | ||
15 | noChanges: 'ការពិនិត្យអក្ខរាវិរុទ្ធបានចប់: ពុំមានផ្លាស់ប្តូរ', | ||
16 | noMispell: 'ការពិនិត្យអក្ខរាវិរុទ្ធបានចប់: គ្មានកំហុស', | ||
17 | noSuggestions: '- គ្មានសំណើរ -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'គ្មានក្នុងវចនានុក្រម', | ||
20 | oneChange: 'ការពិនិត្យអក្ខរាវិរុទ្ធបានចប់: ពាក្យមួយត្រូចបានផ្លាស់ប្តូរ', | ||
21 | progress: 'កំពុងពិនិត្យអក្ខរាវិរុទ្ធ...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'ពិនិត្យអក្ខរាវិរុទ្ធ' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/ko.js b/sources/plugins/wsc/lang/ko.js new file mode 100644 index 00000000..e71340d5 --- /dev/null +++ b/sources/plugins/wsc/lang/ko.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'ko', { | ||
6 | btnIgnore: '건너뜀', | ||
7 | btnIgnoreAll: '모두 건너뜀', | ||
8 | btnReplace: '변경', | ||
9 | btnReplaceAll: '모두 변경', | ||
10 | btnUndo: '취소', | ||
11 | changeTo: '변경할 단어', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: '철자 검사기가 철치되지 않았습니다. 지금 다운로드하시겠습니까?', | ||
14 | manyChanges: '철자검사 완료: %1 단어가 변경되었습니다.', | ||
15 | noChanges: '철자검사 완료: 변경된 단어가 없습니다.', | ||
16 | noMispell: '철자검사 완료: 잘못된 철자가 없습니다.', | ||
17 | noSuggestions: '- 추천단어 없음 -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: '사전에 없는 단어', | ||
20 | oneChange: '철자검사 완료: 단어가 변경되었습니다.', | ||
21 | progress: '철자검사를 진행중입니다...', | ||
22 | title: 'Spell Check', | ||
23 | toolbar: '철자검사' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/ku.js b/sources/plugins/wsc/lang/ku.js new file mode 100644 index 00000000..a69cdc01 --- /dev/null +++ b/sources/plugins/wsc/lang/ku.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'ku', { | ||
6 | btnIgnore: 'پشتگوێ کردن', | ||
7 | btnIgnoreAll: 'پشتگوێکردنی ههمووی', | ||
8 | btnReplace: 'لهبریدانن', | ||
9 | btnReplaceAll: 'لهبریدانانی ههمووی', | ||
10 | btnUndo: 'پووچکردنهوه', | ||
11 | changeTo: 'گۆڕینی بۆ', | ||
12 | errorLoading: 'ههڵه لههێنانی داخوازینامهی خانهخۆێی ڕاژه: %s.', | ||
13 | ieSpellDownload: 'پشکنینی ڕێنووس دانهمزراوه. دهتهوێت ئێستا دایبگریت?', | ||
14 | manyChanges: 'پشکنینی ڕێنووس کۆتای هات: لهسهدا %1 ی وشهکان گۆڕدرا', | ||
15 | noChanges: 'پشکنینی ڕێنووس کۆتای هات: هیچ وشهیهك نۆگۆڕدرا', | ||
16 | noMispell: 'پشکنینی ڕێنووس کۆتای هات: هیچ ههڵهیهکی ڕێنووس نهدۆزراوه', | ||
17 | noSuggestions: '- هیچ پێشنیارێك -', | ||
18 | notAvailable: 'ببووره، لهمکاتهدا ڕاژهکه لهبهردهستا نیه.', | ||
19 | notInDic: 'لهفهرههنگ دانیه', | ||
20 | oneChange: 'پشکنینی ڕێنووس کۆتای هات: یهك وشه گۆڕدرا', | ||
21 | progress: 'پشکنینی ڕێنووس لهبهردهوامبوون دایه...', | ||
22 | title: 'پشکنینی ڕێنووس', | ||
23 | toolbar: 'پشکنینی ڕێنووس' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/lt.js b/sources/plugins/wsc/lang/lt.js new file mode 100644 index 00000000..ce87d11e --- /dev/null +++ b/sources/plugins/wsc/lang/lt.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'lt', { | ||
6 | btnIgnore: 'Ignoruoti', | ||
7 | btnIgnoreAll: 'Ignoruoti visus', | ||
8 | btnReplace: 'Pakeisti', | ||
9 | btnReplaceAll: 'Pakeisti visus', | ||
10 | btnUndo: 'Atšaukti', | ||
11 | changeTo: 'Pakeisti į', | ||
12 | errorLoading: 'Klaida įkraunant servisą: %s.', | ||
13 | ieSpellDownload: 'Rašybos tikrinimas neinstaliuotas. Ar Jūs norite jį dabar atsisiųsti?', | ||
14 | manyChanges: 'Rašybos tikrinimas baigtas: Pakeista %1 žodžių', | ||
15 | noChanges: 'Rašybos tikrinimas baigtas: Nėra pakeistų žodžių', | ||
16 | noMispell: 'Rašybos tikrinimas baigtas: Nerasta rašybos klaidų', | ||
17 | noSuggestions: '- Nėra pasiūlymų -', | ||
18 | notAvailable: 'Atleiskite, šiuo metu servisas neprieinamas.', | ||
19 | notInDic: 'Žodyne nerastas', | ||
20 | oneChange: 'Rašybos tikrinimas baigtas: Vienas žodis pakeistas', | ||
21 | progress: 'Vyksta rašybos tikrinimas...', | ||
22 | title: 'Tikrinti klaidas', | ||
23 | toolbar: 'Rašybos tikrinimas' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/lv.js b/sources/plugins/wsc/lang/lv.js new file mode 100644 index 00000000..4084468b --- /dev/null +++ b/sources/plugins/wsc/lang/lv.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'lv', { | ||
6 | btnIgnore: 'Ignorēt', | ||
7 | btnIgnoreAll: 'Ignorēt visu', | ||
8 | btnReplace: 'Aizvietot', | ||
9 | btnReplaceAll: 'Aizvietot visu', | ||
10 | btnUndo: 'Atcelt', | ||
11 | changeTo: 'Nomainīt uz', | ||
12 | errorLoading: 'Kļūda ielādējot aplikācijas servisa adresi: %s.', | ||
13 | ieSpellDownload: 'Pareizrakstības pārbaudītājs nav pievienots. Vai vēlaties to lejupielādēt tagad?', | ||
14 | manyChanges: 'Pareizrakstības pārbaude pabeigta: %1 vārdi tika mainīti', | ||
15 | noChanges: 'Pareizrakstības pārbaude pabeigta: nekas netika labots', | ||
16 | noMispell: 'Pareizrakstības pārbaude pabeigta: kļūdas netika atrastas', | ||
17 | noSuggestions: '- Nav ieteikumu -', | ||
18 | notAvailable: 'Atvainojiet, bet serviss šobrīd nav pieejams.', | ||
19 | notInDic: 'Netika atrasts vārdnīcā', | ||
20 | oneChange: 'Pareizrakstības pārbaude pabeigta: 1 vārds izmainīts', | ||
21 | progress: 'Notiek pareizrakstības pārbaude...', | ||
22 | title: 'Pārbaudīt gramatiku', | ||
23 | toolbar: 'Pareizrakstības pārbaude' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/mk.js b/sources/plugins/wsc/lang/mk.js new file mode 100644 index 00000000..f2145814 --- /dev/null +++ b/sources/plugins/wsc/lang/mk.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'mk', { | ||
6 | btnIgnore: 'Ignore', | ||
7 | btnIgnoreAll: 'Ignore All', | ||
8 | btnReplace: 'Replace', | ||
9 | btnReplaceAll: 'Replace All', | ||
10 | btnUndo: 'Undo', | ||
11 | changeTo: 'Change to', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Spell checker not installed. Do you want to download it now?', | ||
14 | manyChanges: 'Spell check complete: %1 words changed', | ||
15 | noChanges: 'Spell check complete: No words changed', | ||
16 | noMispell: 'Spell check complete: No misspellings found', | ||
17 | noSuggestions: '- No suggestions -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Not in dictionary', | ||
20 | oneChange: 'Spell check complete: One word changed', | ||
21 | progress: 'Spell check in progress...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Check Spelling' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/mn.js b/sources/plugins/wsc/lang/mn.js new file mode 100644 index 00000000..f61f9e15 --- /dev/null +++ b/sources/plugins/wsc/lang/mn.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'mn', { | ||
6 | btnIgnore: 'Зөвшөөрөх', | ||
7 | btnIgnoreAll: 'Бүгдийг зөвшөөрөх', | ||
8 | btnReplace: 'Солих', | ||
9 | btnReplaceAll: 'Бүгдийг Дарж бичих', | ||
10 | btnUndo: 'Буцаах', | ||
11 | changeTo: 'Өөрчлөх', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Дүрэм шалгагч суугаагүй байна. Татаж авахыг хүсч байна уу?', | ||
14 | manyChanges: 'Дүрэм шалгаад дууссан: %1 үг өөрчлөгдсөн', | ||
15 | noChanges: 'Дүрэм шалгаад дууссан: үг өөрчлөгдөөгүй', | ||
16 | noMispell: 'Дүрэм шалгаад дууссан: Алдаа олдсонгүй', | ||
17 | noSuggestions: '- Тайлбаргүй -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Толь бичиггүй', | ||
20 | oneChange: 'Дүрэм шалгаад дууссан: 1 үг өөрчлөгдсөн', | ||
21 | progress: 'Дүрэм шалгаж байгаа үйл явц...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Үгийн дүрэх шалгах' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/ms.js b/sources/plugins/wsc/lang/ms.js new file mode 100644 index 00000000..a45a0346 --- /dev/null +++ b/sources/plugins/wsc/lang/ms.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'ms', { | ||
6 | btnIgnore: 'Biar', | ||
7 | btnIgnoreAll: 'Biarkan semua', | ||
8 | btnReplace: 'Ganti', | ||
9 | btnReplaceAll: 'Gantikan Semua', | ||
10 | btnUndo: 'Batalkan', | ||
11 | changeTo: 'Tukarkan kepada', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Pemeriksa ejaan tidak dipasang. Adakah anda mahu muat turun sekarang?', | ||
14 | manyChanges: 'Pemeriksaan ejaan siap: %1 perkataan diubah', | ||
15 | noChanges: 'Pemeriksaan ejaan siap: Tiada perkataan diubah', | ||
16 | noMispell: 'Pemeriksaan ejaan siap: Tiada salah ejaan', | ||
17 | noSuggestions: '- Tiada cadangan -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Tidak terdapat didalam kamus', | ||
20 | oneChange: 'Pemeriksaan ejaan siap: Satu perkataan telah diubah', | ||
21 | progress: 'Pemeriksaan ejaan sedang diproses...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Semak Ejaan' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/nb.js b/sources/plugins/wsc/lang/nb.js new file mode 100644 index 00000000..02a070a2 --- /dev/null +++ b/sources/plugins/wsc/lang/nb.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'nb', { | ||
6 | btnIgnore: 'Ignorer', | ||
7 | btnIgnoreAll: 'Ignorer alle', | ||
8 | btnReplace: 'Erstatt', | ||
9 | btnReplaceAll: 'Erstatt alle', | ||
10 | btnUndo: 'Angre', | ||
11 | changeTo: 'Endre til', | ||
12 | errorLoading: 'Feil under lasting av applikasjonstjenestetjener: %s.', | ||
13 | ieSpellDownload: 'Stavekontroll er ikke installert. Vil du laste den ned nå?', | ||
14 | manyChanges: 'Stavekontroll fullført: %1 ord endret', | ||
15 | noChanges: 'Stavekontroll fullført: ingen ord endret', | ||
16 | noMispell: 'Stavekontroll fullført: ingen feilstavinger funnet', | ||
17 | noSuggestions: '- Ingen forslag -', | ||
18 | notAvailable: 'Beklager, tjenesten er utilgjenglig nå.', | ||
19 | notInDic: 'Ikke i ordboken', | ||
20 | oneChange: 'Stavekontroll fullført: Ett ord endret', | ||
21 | progress: 'Stavekontroll pågår...', | ||
22 | title: 'Stavekontroll', | ||
23 | toolbar: 'Stavekontroll' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/nl.js b/sources/plugins/wsc/lang/nl.js new file mode 100644 index 00000000..742027dc --- /dev/null +++ b/sources/plugins/wsc/lang/nl.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'nl', { | ||
6 | btnIgnore: 'Negeren', | ||
7 | btnIgnoreAll: 'Alles negeren', | ||
8 | btnReplace: 'Vervangen', | ||
9 | btnReplaceAll: 'Alles vervangen', | ||
10 | btnUndo: 'Ongedaan maken', | ||
11 | changeTo: 'Wijzig in', | ||
12 | errorLoading: 'Er is een fout opgetreden bij het laden van de dienst: %s.', | ||
13 | ieSpellDownload: 'De spellingscontrole is niet geïnstalleerd. Wilt u deze nu downloaden?', | ||
14 | manyChanges: 'Klaar met spellingscontrole: %1 woorden aangepast', | ||
15 | noChanges: 'Klaar met spellingscontrole: geen woorden aangepast', | ||
16 | noMispell: 'Klaar met spellingscontrole: geen fouten gevonden', | ||
17 | noSuggestions: '- Geen suggesties -', | ||
18 | notAvailable: 'Excuses, deze dienst is momenteel niet beschikbaar.', | ||
19 | notInDic: 'Niet in het woordenboek', | ||
20 | oneChange: 'Klaar met spellingscontrole: één woord aangepast', | ||
21 | progress: 'Bezig met spellingscontrole...', | ||
22 | title: 'Spellingscontrole', | ||
23 | toolbar: 'Spellingscontrole' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/no.js b/sources/plugins/wsc/lang/no.js new file mode 100644 index 00000000..416f67a3 --- /dev/null +++ b/sources/plugins/wsc/lang/no.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'no', { | ||
6 | btnIgnore: 'Ignorer', | ||
7 | btnIgnoreAll: 'Ignorer alle', | ||
8 | btnReplace: 'Erstatt', | ||
9 | btnReplaceAll: 'Erstatt alle', | ||
10 | btnUndo: 'Angre', | ||
11 | changeTo: 'Endre til', | ||
12 | errorLoading: 'Feil under lasting av applikasjonstjenestetjener: %s.', | ||
13 | ieSpellDownload: 'Stavekontroll er ikke installert. Vil du laste den ned nå?', | ||
14 | manyChanges: 'Stavekontroll fullført: %1 ord endret', | ||
15 | noChanges: 'Stavekontroll fullført: ingen ord endret', | ||
16 | noMispell: 'Stavekontroll fullført: ingen feilstavinger funnet', | ||
17 | noSuggestions: '- Ingen forslag -', | ||
18 | notAvailable: 'Beklager, tjenesten er utilgjenglig nå.', | ||
19 | notInDic: 'Ikke i ordboken', | ||
20 | oneChange: 'Stavekontroll fullført: Ett ord endret', | ||
21 | progress: 'Stavekontroll pågår...', | ||
22 | title: 'Stavekontroll', | ||
23 | toolbar: 'Stavekontroll' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/pl.js b/sources/plugins/wsc/lang/pl.js new file mode 100644 index 00000000..0f40934e --- /dev/null +++ b/sources/plugins/wsc/lang/pl.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'pl', { | ||
6 | btnIgnore: 'Ignoruj', | ||
7 | btnIgnoreAll: 'Ignoruj wszystkie', | ||
8 | btnReplace: 'Zmień', | ||
9 | btnReplaceAll: 'Zmień wszystkie', | ||
10 | btnUndo: 'Cofnij', | ||
11 | changeTo: 'Zmień na', | ||
12 | errorLoading: 'Błąd wczytywania hosta aplikacji usługi: %s.', | ||
13 | ieSpellDownload: 'Słownik nie jest zainstalowany. Czy chcesz go pobrać?', | ||
14 | manyChanges: 'Sprawdzanie zakończone: zmieniono %l słów', | ||
15 | noChanges: 'Sprawdzanie zakończone: nie zmieniono żadnego słowa', | ||
16 | noMispell: 'Sprawdzanie zakończone: nie znaleziono błędów', | ||
17 | noSuggestions: '- Brak sugestii -', | ||
18 | notAvailable: 'Przepraszamy, ale usługa jest obecnie niedostępna.', | ||
19 | notInDic: 'Słowa nie ma w słowniku', | ||
20 | oneChange: 'Sprawdzanie zakończone: zmieniono jedno słowo', | ||
21 | progress: 'Trwa sprawdzanie...', | ||
22 | title: 'Sprawdź pisownię', | ||
23 | toolbar: 'Sprawdź pisownię' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/pt-br.js b/sources/plugins/wsc/lang/pt-br.js new file mode 100644 index 00000000..d0469357 --- /dev/null +++ b/sources/plugins/wsc/lang/pt-br.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'pt-br', { | ||
6 | btnIgnore: 'Ignorar uma vez', | ||
7 | btnIgnoreAll: 'Ignorar Todas', | ||
8 | btnReplace: 'Alterar', | ||
9 | btnReplaceAll: 'Alterar Todas', | ||
10 | btnUndo: 'Desfazer', | ||
11 | changeTo: 'Alterar para', | ||
12 | errorLoading: 'Erro carregando servidor de aplicação: %s.', | ||
13 | ieSpellDownload: 'A verificação ortográfica não foi instalada. Você gostaria de realizar o download agora?', | ||
14 | manyChanges: 'Verificação ortográfica encerrada: %1 palavras foram alteradas', | ||
15 | noChanges: 'Verificação ortográfica encerrada: Não houve alterações', | ||
16 | noMispell: 'Verificação encerrada: Não foram encontrados erros de ortografia', | ||
17 | noSuggestions: '-sem sugestões de ortografia-', | ||
18 | notAvailable: 'Desculpe, o serviço não está disponível no momento.', | ||
19 | notInDic: 'Não encontrada', | ||
20 | oneChange: 'Verificação ortográfica encerrada: Uma palavra foi alterada', | ||
21 | progress: 'Verificação ortográfica em andamento...', | ||
22 | title: 'Corretor Ortográfico', | ||
23 | toolbar: 'Verificar Ortografia' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/pt.js b/sources/plugins/wsc/lang/pt.js new file mode 100644 index 00000000..744fd28c --- /dev/null +++ b/sources/plugins/wsc/lang/pt.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'pt', { | ||
6 | btnIgnore: 'Ignorar', | ||
7 | btnIgnoreAll: 'Ignorar Tudo', | ||
8 | btnReplace: 'Substituir', | ||
9 | btnReplaceAll: 'Substituir Tudo', | ||
10 | btnUndo: 'Anular', | ||
11 | changeTo: 'Mudar para', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: ' Verificação ortográfica não instalada. Quer descarregar agora?', | ||
14 | manyChanges: 'Verificação ortográfica completa: %1 palavras alteradas', | ||
15 | noChanges: 'Verificação ortográfica completa: não houve alteração de palavras', | ||
16 | noMispell: 'Verificação ortográfica completa: não foram encontrados erros', | ||
17 | noSuggestions: '- Sem sugestões -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Não está num directório', | ||
20 | oneChange: 'Verificação ortográfica completa: uma palavra alterada', | ||
21 | progress: 'Verificação ortográfica em progresso…', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Verificação Ortográfica' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/ro.js b/sources/plugins/wsc/lang/ro.js new file mode 100644 index 00000000..c4b40e04 --- /dev/null +++ b/sources/plugins/wsc/lang/ro.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'ro', { | ||
6 | btnIgnore: 'Ignoră', | ||
7 | btnIgnoreAll: 'Ignoră toate', | ||
8 | btnReplace: 'Înlocuieşte', | ||
9 | btnReplaceAll: 'Înlocuieşte tot', | ||
10 | btnUndo: 'Starea anterioară (undo)', | ||
11 | changeTo: 'Schimbă în', | ||
12 | errorLoading: 'Eroare în lansarea aplicației service host %s.', | ||
13 | ieSpellDownload: 'Unealta pentru verificat textul (Spell checker) neinstalată. Doriţi să o descărcaţi acum?', | ||
14 | manyChanges: 'Verificarea textului terminată: 1% cuvinte modificate', | ||
15 | noChanges: 'Verificarea textului terminată: Niciun cuvânt modificat', | ||
16 | noMispell: 'Verificarea textului terminată: Nicio greşeală găsită', | ||
17 | noSuggestions: '- Fără sugestii -', | ||
18 | notAvailable: 'Scuzați, dar serviciul nu este disponibil momentan.', | ||
19 | notInDic: 'Nu e în dicţionar', | ||
20 | oneChange: 'Verificarea textului terminată: Un cuvânt modificat', | ||
21 | progress: 'Verificarea textului în desfăşurare...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Verifică scrierea textului' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/ru.js b/sources/plugins/wsc/lang/ru.js new file mode 100644 index 00000000..d73f3018 --- /dev/null +++ b/sources/plugins/wsc/lang/ru.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'ru', { | ||
6 | btnIgnore: 'Пропустить', | ||
7 | btnIgnoreAll: 'Пропустить всё', | ||
8 | btnReplace: 'Заменить', | ||
9 | btnReplaceAll: 'Заменить всё', | ||
10 | btnUndo: 'Отменить', | ||
11 | changeTo: 'Изменить на', | ||
12 | errorLoading: 'Произошла ошибка при подключении к серверу проверки орфографии: %s.', | ||
13 | ieSpellDownload: 'Модуль проверки орфографии не установлен. Хотите скачать его?', | ||
14 | manyChanges: 'Проверка орфографии завершена. Изменено слов: %1', | ||
15 | noChanges: 'Проверка орфографии завершена. Не изменено ни одного слова', | ||
16 | noMispell: 'Проверка орфографии завершена. Ошибок не найдено', | ||
17 | noSuggestions: '- Варианты отсутствуют -', | ||
18 | notAvailable: 'Извините, но в данный момент сервис недоступен.', | ||
19 | notInDic: 'Отсутствует в словаре', | ||
20 | oneChange: 'Проверка орфографии завершена. Изменено одно слово', | ||
21 | progress: 'Орфография проверяется...', | ||
22 | title: 'Проверка орфографии', | ||
23 | toolbar: 'Проверить орфографию' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/sk.js b/sources/plugins/wsc/lang/sk.js new file mode 100644 index 00000000..9c2ce037 --- /dev/null +++ b/sources/plugins/wsc/lang/sk.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'sk', { | ||
6 | btnIgnore: 'Ignorovať', | ||
7 | btnIgnoreAll: 'Ignorovať všetko', | ||
8 | btnReplace: 'Prepísat', | ||
9 | btnReplaceAll: 'Prepísat všetko', | ||
10 | btnUndo: 'Späť', | ||
11 | changeTo: 'Zmeniť na', | ||
12 | errorLoading: 'Chyba pri načítaní slovníka z adresy: %s.', | ||
13 | ieSpellDownload: 'Kontrola pravopisu nie je naištalovaná. Chcete ju teraz stiahnuť?', | ||
14 | manyChanges: 'Kontrola pravopisu dokončená: Bolo zmenených %1 slov', | ||
15 | noChanges: 'Kontrola pravopisu dokončená: Neboli zmenené žiadne slová', | ||
16 | noMispell: 'Kontrola pravopisu dokončená: Neboli nájdené žiadne chyby pravopisu', | ||
17 | noSuggestions: '- Žiadny návrh -', | ||
18 | notAvailable: 'Prepáčte, ale služba je momentálne nedostupná.', | ||
19 | notInDic: 'Nie je v slovníku', | ||
20 | oneChange: 'Kontrola pravopisu dokončená: Bolo zmenené jedno slovo', | ||
21 | progress: 'Prebieha kontrola pravopisu...', | ||
22 | title: 'Skontrolovať pravopis', | ||
23 | toolbar: 'Kontrola pravopisu' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/sl.js b/sources/plugins/wsc/lang/sl.js new file mode 100644 index 00000000..ba871234 --- /dev/null +++ b/sources/plugins/wsc/lang/sl.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'sl', { | ||
6 | btnIgnore: 'Prezri', | ||
7 | btnIgnoreAll: 'Prezri vse', | ||
8 | btnReplace: 'Zamenjaj', | ||
9 | btnReplaceAll: 'Zamenjaj vse', | ||
10 | btnUndo: 'Razveljavi', | ||
11 | changeTo: 'Spremeni v', | ||
12 | errorLoading: 'Napaka pri nalaganju storitve programa na naslovu %s.', | ||
13 | ieSpellDownload: 'Črkovalnik ni nameščen. Ali ga želite prenesti sedaj?', | ||
14 | manyChanges: 'Črkovanje je končano: Spremenjenih je bilo %1 besed', | ||
15 | noChanges: 'Črkovanje je končano: Nobena beseda ni bila spremenjena', | ||
16 | noMispell: 'Črkovanje je končano: Brez napak', | ||
17 | noSuggestions: '- Ni predlogov -', | ||
18 | notAvailable: 'Oprostite, storitev trenutno ni dosegljiva.', | ||
19 | notInDic: 'Ni v slovarju', | ||
20 | oneChange: 'Črkovanje je končano: Spremenjena je bila ena beseda', | ||
21 | progress: 'Preverjanje črkovanja se izvaja...', | ||
22 | title: 'Črkovalnik', | ||
23 | toolbar: 'Preveri črkovanje' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/sr-latn.js b/sources/plugins/wsc/lang/sr-latn.js new file mode 100644 index 00000000..f9585cc7 --- /dev/null +++ b/sources/plugins/wsc/lang/sr-latn.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'sr-latn', { | ||
6 | btnIgnore: 'Ignoriši', | ||
7 | btnIgnoreAll: 'Ignoriši sve', | ||
8 | btnReplace: 'Zameni', | ||
9 | btnReplaceAll: 'Zameni sve', | ||
10 | btnUndo: 'Vrati akciju', | ||
11 | changeTo: 'Izmeni', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Provera spelovanja nije instalirana. Da li želite da je skinete sa Interneta?', | ||
14 | manyChanges: 'Provera spelovanja završena: %1 reč(i) je izmenjeno', | ||
15 | noChanges: 'Provera spelovanja završena: Nije izmenjena nijedna rec', | ||
16 | noMispell: 'Provera spelovanja završena: greške nisu pronadene', | ||
17 | noSuggestions: '- Bez sugestija -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Nije u rečniku', | ||
20 | oneChange: 'Provera spelovanja završena: Izmenjena je jedna reč', | ||
21 | progress: 'Provera spelovanja u toku...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Proveri spelovanje' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/sr.js b/sources/plugins/wsc/lang/sr.js new file mode 100644 index 00000000..9c4cb7f2 --- /dev/null +++ b/sources/plugins/wsc/lang/sr.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'sr', { | ||
6 | btnIgnore: 'Игнориши', | ||
7 | btnIgnoreAll: 'Игнориши све', | ||
8 | btnReplace: 'Замени', | ||
9 | btnReplaceAll: 'Замени све', | ||
10 | btnUndo: 'Врати акцију', | ||
11 | changeTo: 'Измени', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'Провера спеловања није инсталирана. Да ли желите да је скинете са Интернета?', | ||
14 | manyChanges: 'Провера спеловања завршена: %1 реч(и) је измењено', | ||
15 | noChanges: 'Провера спеловања завршена: Није измењена ниједна реч', | ||
16 | noMispell: 'Провера спеловања завршена: грешке нису пронађене', | ||
17 | noSuggestions: '- Без сугестија -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'Није у речнику', | ||
20 | oneChange: 'Провера спеловања завршена: Измењена је једна реч', | ||
21 | progress: 'Провера спеловања у току...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'Провери спеловање' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/sv.js b/sources/plugins/wsc/lang/sv.js new file mode 100644 index 00000000..32e11e80 --- /dev/null +++ b/sources/plugins/wsc/lang/sv.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'sv', { | ||
6 | btnIgnore: 'Ignorera', | ||
7 | btnIgnoreAll: 'Ignorera alla', | ||
8 | btnReplace: 'Ersätt', | ||
9 | btnReplaceAll: 'Ersätt alla', | ||
10 | btnUndo: 'Ångra', | ||
11 | changeTo: 'Ändra till', | ||
12 | errorLoading: 'Tjänsten är ej tillgänglig: %s.', | ||
13 | ieSpellDownload: 'Stavningskontrollen är ej installerad. Vill du göra det nu?', | ||
14 | manyChanges: 'Stavningskontroll slutförd: %1 ord rättades.', | ||
15 | noChanges: 'Stavningskontroll slutförd: Inga ord rättades.', | ||
16 | noMispell: 'Stavningskontroll slutförd: Inga stavfel påträffades.', | ||
17 | noSuggestions: '- Förslag saknas -', | ||
18 | notAvailable: 'Tyvärr är tjänsten ej tillgänglig nu', | ||
19 | notInDic: 'Saknas i ordlistan', | ||
20 | oneChange: 'Stavningskontroll slutförd: Ett ord rättades.', | ||
21 | progress: 'Stavningskontroll pågår...', | ||
22 | title: 'Kontrollera stavning', | ||
23 | toolbar: 'Stavningskontroll' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/th.js b/sources/plugins/wsc/lang/th.js new file mode 100644 index 00000000..6e09e6cc --- /dev/null +++ b/sources/plugins/wsc/lang/th.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'th', { | ||
6 | btnIgnore: 'ยกเว้น', | ||
7 | btnIgnoreAll: 'ยกเว้นทั้งหมด', | ||
8 | btnReplace: 'แทนที่', | ||
9 | btnReplaceAll: 'แทนที่ทั้งหมด', | ||
10 | btnUndo: 'ยกเลิก', | ||
11 | changeTo: 'แก้ไขเป็น', | ||
12 | errorLoading: 'Error loading application service host: %s.', | ||
13 | ieSpellDownload: 'ไม่ได้ติดตั้งระบบตรวจสอบคำสะกด. ต้องการติดตั้งไหมครับ?', | ||
14 | manyChanges: 'ตรวจสอบคำสะกดเสร็จสิ้น:: แก้ไข %1 คำ', | ||
15 | noChanges: 'ตรวจสอบคำสะกดเสร็จสิ้น: ไม่มีการแก้คำใดๆ', | ||
16 | noMispell: 'ตรวจสอบคำสะกดเสร็จสิ้น: ไม่พบคำสะกดผิด', | ||
17 | noSuggestions: '- ไม่มีคำแนะนำใดๆ -', | ||
18 | notAvailable: 'Sorry, but service is unavailable now.', | ||
19 | notInDic: 'ไม่พบในดิกชันนารี', | ||
20 | oneChange: 'ตรวจสอบคำสะกดเสร็จสิ้น: แก้ไข1คำ', | ||
21 | progress: 'กำลังตรวจสอบคำสะกด...', | ||
22 | title: 'Spell Checker', | ||
23 | toolbar: 'ตรวจการสะกดคำ' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/tr.js b/sources/plugins/wsc/lang/tr.js new file mode 100644 index 00000000..f400035c --- /dev/null +++ b/sources/plugins/wsc/lang/tr.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'tr', { | ||
6 | btnIgnore: 'Yoksay', | ||
7 | btnIgnoreAll: 'Tümünü Yoksay', | ||
8 | btnReplace: 'Değiştir', | ||
9 | btnReplaceAll: 'Tümünü Değiştir', | ||
10 | btnUndo: 'Geri Al', | ||
11 | changeTo: 'Şuna değiştir:', | ||
12 | errorLoading: 'Uygulamada yüklerken hata oluştu: %s.', | ||
13 | ieSpellDownload: 'Yazım denetimi yüklenmemiş. Şimdi yüklemek ister misiniz?', | ||
14 | manyChanges: 'Yazım denetimi tamamlandı: %1 kelime değiştirildi', | ||
15 | noChanges: 'Yazım denetimi tamamlandı: Hiçbir kelime değiştirilmedi', | ||
16 | noMispell: 'Yazım denetimi tamamlandı: Yanlış yazıma rastlanmadı', | ||
17 | noSuggestions: '- Öneri Yok -', | ||
18 | notAvailable: 'Üzügünüz, bu servis şuanda hizmet dışıdır.', | ||
19 | notInDic: 'Sözlükte Yok', | ||
20 | oneChange: 'Yazım denetimi tamamlandı: Bir kelime değiştirildi', | ||
21 | progress: 'Yazım denetimi işlemde...', | ||
22 | title: 'Yazımı Denetle', | ||
23 | toolbar: 'Yazım Denetimi' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/ug.js b/sources/plugins/wsc/lang/ug.js new file mode 100644 index 00000000..273621e1 --- /dev/null +++ b/sources/plugins/wsc/lang/ug.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'ug', { | ||
6 | btnIgnore: 'پەرۋا قىلما', | ||
7 | btnIgnoreAll: 'ھەممىگە پەرۋا قىلما', | ||
8 | btnReplace: 'ئالماشتۇر', | ||
9 | btnReplaceAll: 'ھەممىنى ئالماشتۇر', | ||
10 | btnUndo: 'يېنىۋال', | ||
11 | changeTo: 'ئۆزگەرت', | ||
12 | errorLoading: 'لازىملىق مۇلازىمېتىرنى يۈكلىگەندە خاتالىق كۆرۈلدى: %s.', | ||
13 | ieSpellDownload: 'ئىملا تەكشۈرۈش قىستۇرمىسى تېخى ئورنىتىلمىغان، ھازىرلا چۈشۈرەمسىز؟', | ||
14 | manyChanges: 'ئىملا تەكشۈرۈش تامام: %1 سۆزنى ئۆزگەرتتى', | ||
15 | noChanges: 'ئىملا تەكشۈرۈش تامام: ھېچقانداق سۆزنى ئۆزگەرتمىدى', | ||
16 | noMispell: 'ئىملا تەكشۈرۈش تامام: ئىملا خاتالىقى بايقالمىدى', | ||
17 | noSuggestions: '-تەكلىپ يوق-', | ||
18 | notAvailable: 'كەچۈرۈڭ، مۇلازىمېتىرنى ۋاقتىنچە ئىشلەتكىلى بولمايدۇ', | ||
19 | notInDic: 'لۇغەتتە يوق', | ||
20 | oneChange: 'ئىملا تەكشۈرۈش تامام: بىر سۆزنى ئۆزگەرتتى', | ||
21 | progress: 'ئىملا تەكشۈرۈۋاتىدۇ…', | ||
22 | title: 'ئىملا تەكشۈر', | ||
23 | toolbar: 'ئىملا تەكشۈر' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/uk.js b/sources/plugins/wsc/lang/uk.js new file mode 100644 index 00000000..a813bff1 --- /dev/null +++ b/sources/plugins/wsc/lang/uk.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'uk', { | ||
6 | btnIgnore: 'Пропустити', | ||
7 | btnIgnoreAll: 'Пропустити все', | ||
8 | btnReplace: 'Замінити', | ||
9 | btnReplaceAll: 'Замінити все', | ||
10 | btnUndo: 'Назад', | ||
11 | changeTo: 'Замінити на', | ||
12 | errorLoading: 'Помилка завантаження : %s.', | ||
13 | ieSpellDownload: 'Модуль перевірки орфографії не встановлено. Бажаєте завантажити його зараз?', | ||
14 | manyChanges: 'Перевірку орфографії завершено: 1% слів(ова) змінено', | ||
15 | noChanges: 'Перевірку орфографії завершено: жодне слово не змінено', | ||
16 | noMispell: 'Перевірку орфографії завершено: помилок не знайдено', | ||
17 | noSuggestions: '- немає варіантів -', | ||
18 | notAvailable: 'Вибачте, але сервіс наразі недоступний.', | ||
19 | notInDic: 'Немає в словнику', | ||
20 | oneChange: 'Перевірку орфографії завершено: змінено одне слово', | ||
21 | progress: 'Виконується перевірка орфографії...', | ||
22 | title: 'Перевірка орфографії', | ||
23 | toolbar: 'Перевірити орфографію' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/vi.js b/sources/plugins/wsc/lang/vi.js new file mode 100644 index 00000000..bba8969c --- /dev/null +++ b/sources/plugins/wsc/lang/vi.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'vi', { | ||
6 | btnIgnore: 'Bỏ qua', | ||
7 | btnIgnoreAll: 'Bỏ qua tất cả', | ||
8 | btnReplace: 'Thay thế', | ||
9 | btnReplaceAll: 'Thay thế tất cả', | ||
10 | btnUndo: 'Phục hồi lại', | ||
11 | changeTo: 'Chuyển thành', | ||
12 | errorLoading: 'Lỗi khi đang nạp dịch vụ ứng dụng: %s.', | ||
13 | ieSpellDownload: 'Chức năng kiểm tra chính tả chưa được cài đặt. Bạn có muốn tải về ngay bây giờ?', | ||
14 | manyChanges: 'Hoàn tất kiểm tra chính tả: %1 từ đã được thay đổi', | ||
15 | noChanges: 'Hoàn tất kiểm tra chính tả: Không có từ nào được thay đổi', | ||
16 | noMispell: 'Hoàn tất kiểm tra chính tả: Không có lỗi chính tả', | ||
17 | noSuggestions: '- Không đưa ra gợi ý về từ -', | ||
18 | notAvailable: 'Xin lỗi, dịch vụ này hiện tại không có.', | ||
19 | notInDic: 'Không có trong từ điển', | ||
20 | oneChange: 'Hoàn tất kiểm tra chính tả: Một từ đã được thay đổi', | ||
21 | progress: 'Đang tiến hành kiểm tra chính tả...', | ||
22 | title: 'Kiểm tra chính tả', | ||
23 | toolbar: 'Kiểm tra chính tả' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/zh-cn.js b/sources/plugins/wsc/lang/zh-cn.js new file mode 100644 index 00000000..a2987b84 --- /dev/null +++ b/sources/plugins/wsc/lang/zh-cn.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'zh-cn', { | ||
6 | btnIgnore: '忽略', | ||
7 | btnIgnoreAll: '全部忽略', | ||
8 | btnReplace: '替换', | ||
9 | btnReplaceAll: '全部替换', | ||
10 | btnUndo: '撤消', | ||
11 | changeTo: '更改为', | ||
12 | errorLoading: '加载应该服务主机时出错: %s.', | ||
13 | ieSpellDownload: '拼写检查插件还没安装, 您是否想现在就下载?', | ||
14 | manyChanges: '拼写检查完成: 更改了 %1 个单词', | ||
15 | noChanges: '拼写检查完成: 没有更改任何单词', | ||
16 | noMispell: '拼写检查完成: 没有发现拼写错误', | ||
17 | noSuggestions: '- 没有建议 -', | ||
18 | notAvailable: '抱歉, 服务目前暂不可用', | ||
19 | notInDic: '没有在字典里', | ||
20 | oneChange: '拼写检查完成: 更改了一个单词', | ||
21 | progress: '正在进行拼写检查...', | ||
22 | title: '拼写检查', | ||
23 | toolbar: '拼写检查' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/lang/zh.js b/sources/plugins/wsc/lang/zh.js new file mode 100644 index 00000000..a3aa83d7 --- /dev/null +++ b/sources/plugins/wsc/lang/zh.js | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.html or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'wsc', 'zh', { | ||
6 | btnIgnore: '忽略', | ||
7 | btnIgnoreAll: '全部忽略', | ||
8 | btnReplace: '取代', | ||
9 | btnReplaceAll: '全部取代', | ||
10 | btnUndo: '復原', | ||
11 | changeTo: '更改為', | ||
12 | errorLoading: '無法聯系侍服器: %s.', | ||
13 | ieSpellDownload: '尚未安裝拼字檢查元件。您是否想要現在下載?', | ||
14 | manyChanges: '拼字檢查完成:更改了 %1 個單字', | ||
15 | noChanges: '拼字檢查完成:未更改任何單字', | ||
16 | noMispell: '拼字檢查完成:未發現拼字錯誤', | ||
17 | noSuggestions: '- 無建議值 -', | ||
18 | notAvailable: '抱歉,服務目前暫不可用', | ||
19 | notInDic: '不在字典中', | ||
20 | oneChange: '拼字檢查完成:更改了 1 個單字', | ||
21 | progress: '進行拼字檢查中…', | ||
22 | title: '拼字檢查', | ||
23 | toolbar: '拼字檢查' | ||
24 | }); | ||
diff --git a/sources/plugins/wsc/plugin.js b/sources/plugins/wsc/plugin.js new file mode 100644 index 00000000..ba443706 --- /dev/null +++ b/sources/plugins/wsc/plugin.js | |||
@@ -0,0 +1,142 @@ | |||
1 | // Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
2 | // For licensing, see LICENSE.md or http://ckeditor.com/license | ||
3 | |||
4 | CKEDITOR.plugins.add( 'wsc', { | ||
5 | requires: 'dialog', | ||
6 | lang: 'af,ar,bg,bn,bs,ca,cs,cy,da,de,el,en-au,en-ca,en-gb,en,eo,es,et,eu,fa,fi,fo,fr-ca,fr,gl,gu,he,hi,hr,hu,is,it,ja,ka,km,ko,lt,lv,mk,mn,ms,nb,nl,no,pl,pt-br,pt,ro,ru,sk,sl,sr-latn,sr,sv,th,tr,ug,uk,vi,zh-cn,zh', // %REMOVE_LINE_CORE% | ||
7 | icons: 'spellchecker', // %REMOVE_LINE_CORE% | ||
8 | hidpi: true, // %REMOVE_LINE_CORE% | ||
9 | parseApi: function(editor) { | ||
10 | editor.config.wsc_onFinish = (typeof editor.config.wsc_onFinish === 'function') ? editor.config.wsc_onFinish : function() {}; | ||
11 | editor.config.wsc_onClose = (typeof editor.config.wsc_onClose === 'function') ? editor.config.wsc_onClose : function() {}; | ||
12 | }, | ||
13 | parseConfig: function(editor) { | ||
14 | editor.config.wsc_customerId = editor.config.wsc_customerId || CKEDITOR.config.wsc_customerId || '1:ua3xw1-2XyGJ3-GWruD3-6OFNT1-oXcuB1-nR6Bp4-hgQHc-EcYng3-sdRXG3-NOfFk'; | ||
15 | editor.config.wsc_customDictionaryIds = editor.config.wsc_customDictionaryIds || CKEDITOR.config.wsc_customDictionaryIds || ''; | ||
16 | editor.config.wsc_userDictionaryName = editor.config.wsc_userDictionaryName || CKEDITOR.config.wsc_userDictionaryName || ''; | ||
17 | editor.config.wsc_customLoaderScript = editor.config.wsc_customLoaderScript || CKEDITOR.config.wsc_customLoaderScript; | ||
18 | |||
19 | CKEDITOR.config.wsc_cmd = editor.config.wsc_cmd || CKEDITOR.config.wsc_cmd || 'spell'; // spell, thes or grammar. default tab | ||
20 | CKEDITOR.config.wsc_version="v4.3.0-master-d769233"; | ||
21 | CKEDITOR.config.wsc_removeGlobalVariable = true; | ||
22 | }, | ||
23 | init: function( editor ) { | ||
24 | var commandName = 'checkspell'; | ||
25 | |||
26 | var strNormalDialog = 'dialogs/wsc.js', | ||
27 | strIeDialog = 'dialogs/wsc_ie.js', | ||
28 | strDialog, | ||
29 | self = this, | ||
30 | env = CKEDITOR.env; | ||
31 | |||
32 | self.parseConfig(editor); | ||
33 | self.parseApi(editor); | ||
34 | var command = editor.addCommand( commandName, new CKEDITOR.dialogCommand( commandName ) ); | ||
35 | |||
36 | // SpellChecker doesn't work in Opera, with custom domain, IE Compatibility Mode and IE (8 & 9) Quirks Mode | ||
37 | command.modes = { wysiwyg: ( !CKEDITOR.env.opera && !CKEDITOR.env.air && document.domain == window.location.hostname && | ||
38 | !( env.ie && ( env.version < 8 || env.quirks ) ) ) }; | ||
39 | |||
40 | if(typeof editor.plugins.scayt == 'undefined'){ | ||
41 | editor.ui.addButton && editor.ui.addButton( 'SpellChecker', { | ||
42 | label: editor.lang.wsc.toolbar, | ||
43 | click: function(editor) { | ||
44 | var inlineMode = (editor.elementMode == CKEDITOR.ELEMENT_MODE_INLINE), | ||
45 | text = inlineMode ? editor.container.getText() : editor.document.getBody().getText(); | ||
46 | |||
47 | text = text.replace(/\s/g, ''); | ||
48 | |||
49 | if(text) { | ||
50 | editor.execCommand('checkspell'); | ||
51 | } else { | ||
52 | alert('Nothing to check!'); | ||
53 | } | ||
54 | }, | ||
55 | toolbar: 'spellchecker,10' | ||
56 | }); | ||
57 | } | ||
58 | |||
59 | |||
60 | if ( CKEDITOR.env.ie && CKEDITOR.env.version <= 7 ){ | ||
61 | strDialog = strIeDialog; | ||
62 | } else { | ||
63 | if (!window.postMessage) { | ||
64 | strDialog = strIeDialog; | ||
65 | } else { | ||
66 | strDialog = strNormalDialog; | ||
67 | } | ||
68 | } | ||
69 | CKEDITOR.dialog.add( commandName, this.path + strDialog ); | ||
70 | } | ||
71 | |||
72 | }); | ||
73 | |||
74 | /** | ||
75 | * The parameter sets the customer ID for WSC. It is used for hosted users only. It is required for migration from free | ||
76 | * to trial or paid versions. | ||
77 | * | ||
78 | * config.wsc_customerId = 'encrypted-customer-id'; | ||
79 | * | ||
80 | * @cfg {String} [wsc_customerId='1:ua3xw1-2XyGJ3-GWruD3-6OFNT1-oXcuB1-nR6Bp4-hgQHc-EcYng3-sdRXG3-NOfFk'] | ||
81 | * @member CKEDITOR.config | ||
82 | */ | ||
83 | |||
84 | /** | ||
85 | * It links WSC to custom dictionaries. It should be a string with dictionary IDs | ||
86 | * separated by commas (`','`). Available only for the licensed version. | ||
87 | * | ||
88 | * Further details at [http://wiki.webspellchecker.net/doku.php?id=installationandconfiguration:customdictionaries:licensed](http://wiki.webspellchecker.net/doku.php?id=installationandconfiguration:customdictionaries:licensed) | ||
89 | * | ||
90 | * config.wsc_customDictionaryIds = '1,3001'; | ||
91 | * | ||
92 | * @cfg {String} [wsc_customDictionaryIds=''] | ||
93 | * @member CKEDITOR.config | ||
94 | */ | ||
95 | |||
96 | /** | ||
97 | * It activates a user dictionary for WSC. The user dictionary name should be used. Available only for the licensed version. | ||
98 | * | ||
99 | * config.wsc_userDictionaryName = 'MyUserDictionaryName'; | ||
100 | * | ||
101 | * @cfg {String} [wsc_userDictionaryName=''] | ||
102 | * @member CKEDITOR.config | ||
103 | */ | ||
104 | |||
105 | /** | ||
106 | * The parameter sets the URL to WSC file. It is required to the licensed version of WSC application. | ||
107 | * | ||
108 | * Further details available at [http://wiki.webspellchecker.net/doku.php?id=migration:hosredfreetolicensedck](http://wiki.webspellchecker.net/doku.php?id=migration:hosredfreetolicensedck) | ||
109 | * | ||
110 | * config.wsc_customLoaderScript = "http://my-host/spellcheck/lf/22/js/wsc_fck2plugin.js"; | ||
111 | * | ||
112 | * @cfg {String} [wsc_customLoaderScript=''] | ||
113 | * @member CKEDITOR.config | ||
114 | */ | ||
115 | |||
116 | /** | ||
117 | * The parameter sets the default spellchecking language for WSC. | ||
118 | * Possible values are: | ||
119 | * `'en_US'`, `'en_GB'`, `'pt_BR'`, `'da_DK'`, | ||
120 | * `'nl_NL'`, `'en_CA'`, `'fi_FI'`, `'fr_FR'`, | ||
121 | * `'fr_CA'`, `'de_DE'`, `'el_GR'`, `'it_IT'`, | ||
122 | * `'nb_NO'`, `'pt_PT'`, `'es_ES'`, `'sv_SE'`. | ||
123 | * | ||
124 | * Further details available at [http://wiki.webspellchecker.net/doku.php?id=installationandconfiguration:supportedlanguages](http://wiki.webspellchecker.net/doku.php?id=installationandconfiguration:supportedlanguages) | ||
125 | * | ||
126 | * config.wsc_lang = 'de_DE'; | ||
127 | * | ||
128 | * @cfg {String} [wsc_lang='en_US'] | ||
129 | * @member CKEDITOR.config | ||
130 | */ | ||
131 | |||
132 | /** | ||
133 | * The parameter sets the active tab, when the WSC dialog is opened. | ||
134 | * Possible values are: | ||
135 | * `'spell'`, `'thes'`, `'grammar'`. | ||
136 | * | ||
137 | * // Sets active tab thesaurus. | ||
138 | * config.wsc_cmd = 'thes'; | ||
139 | * | ||
140 | * @cfg {String} [wsc_cmd='spell'] | ||
141 | * @member CKEDITOR.config | ||
142 | */ | ||