Overview
Comment: | [fx] textarea control + small code refactoring |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | fx | webext2 |
Files: | files | file ages | folders |
SHA3-256: |
40e9aa097d93a0e86353d91396d5e074 |
User & Date: | olr on 2017-08-22 08:02:47 |
Other Links: | branch diff | manifest | tags |
Context
2017-08-22
| ||
09:34 | [fx] recheck paragraph after applying suggestion check-in: 5bfb5a6c67 user: olr tags: fx, webext2 | |
08:02 | [fx] textarea control + small code refactoring check-in: 40e9aa097d user: olr tags: fx, webext2 | |
2017-08-16
| ||
18:27 | [fx] object to control textarea check-in: 9002c7508c user: olr tags: fx, webext2 | |
Changes
Modified gc_lang/fr/webext/content_scripts/content_modifier.js from [1ff5fd0533] to [4e0ba04476].
︙ | |||
49 50 51 52 53 54 55 | 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 | - + + + - + + + + | } } function createWrapperToolbar (xTextArea) { try { let xToolbar = createNode("div", {className: "grammalecte_wrapper_toolbar"}); let xConjButton = createNode("div", {className: "grammalecte_wrapper_button", textContent: "Conjuguer"}); |
︙ |
Modified gc_lang/fr/webext/content_scripts/gc_content.js from [869a446e62] to [da49634b64].
︙ | |||
12 13 14 15 16 17 18 | 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 | - + - + - + | oGCPanelContent.ignoreError(xElem.id); } else if (xElem.id.startsWith("grammalecte_check")) { oGCPanelContent.recheckParagraph(xElem.id.slice(17)); } else if (xElem.id.startsWith("grammalecte_hide")) { document.getElementById(xElem.id).parentNode.parentNode.style.display = "none"; } else if (xElem.tagName === "U" && xElem.id.startsWith("grammalecte_err") && xElem.className !== "corrected" && xElem.className !== "ignored") { |
︙ | |||
52 53 54 55 56 57 58 | 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 | - - + + + + + + + + + | aIgnoredErrors: new Set(), init: function () { this.xContentNode = createNode("div", {id: "grammalecte_gc_panel_content"}); this.xParagraphList = createNode("div", {id: "grammalecte_paragraph_list"}); this.xContentNode.appendChild(this.xParagraphList); this.xContentNode.addEventListener("click", onGrammalecteGCPanelClick, false); |
︙ | |||
93 94 95 96 97 98 99 100 101 | 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 | + - + + + | } }, recheckParagraph: function (sParagraphNum) { //startWaitIcon(); let sParagraphId = "grammalecte_paragraph" + sParagraphNum; let xParagraph = document.getElementById(sParagraphId); let sText = this.getPurgedTextOfParagraph(xParagraph.textContent); xPort.postMessage({ sCommand: "parseAndSpellcheck1", |
︙ | |||
183 184 185 186 187 188 189 | 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 | - + - + | let sErrorId = document.getElementById(sNodeSuggId).dataset.error_id; //let sParaNum = sErrorId.slice(0, sErrorId.indexOf("-")); console.log("grammalecte_err"+sErrorId); let xNodeErr = document.getElementById("grammalecte_err" + sErrorId); xNodeErr.textContent = document.getElementById(sNodeSuggId).textContent; xNodeErr.className = "corrected"; xNodeErr.removeAttribute("style"); |
︙ | |||
240 241 242 243 244 245 246 | 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 | - + | } stopWaitIcon(); } } |
︙ | |||
368 369 370 371 372 373 374 | 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 | + - + - + - + - - - + + + + + + - - - + + + + + - + - - + - - - - - - - - - - - - + + + + + + + + + + + + - - - + - - - + - - - + + - - + - - - - - + + + + - - - - + + - | catch (e) { showError(e); } } } oGCPanelContent.oTAC = { |
Modified gc_lang/fr/webext/gce_worker.js from [cda351c05e] to [cd9b8f9d6b].
︙ | |||
188 189 190 191 192 193 194 | 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 | - + | } function parseAndSpellcheck (sText, sCountry, bDebug, bContext, dInfo={}) { let n = 0; for (let sParagraph of text.getParagraph(sText)) { let aGrammErr = gc_engine.parse(sParagraph, sCountry, bDebug, bContext); let aSpellErr = oTokenizer.getSpellingErrors(sParagraph, oDict); |
︙ |