diff options
author | Byron Jones <bjones@mozilla.com> | 2013-05-15 17:34:22 +0200 |
---|---|---|
committer | Byron Jones <bjones@mozilla.com> | 2013-05-15 17:34:22 +0200 |
commit | e7c1850247b48e8446c144d835fe6a4a1a67d9c3 (patch) | |
tree | cb53657ceea66d60f99525aed26a97299531ffa3 /extensions/Splinter/web | |
parent | b29e02fc461d92a33679a3d7d1407d14185cb7f5 (diff) | |
download | bugzilla-e7c1850247b48e8446c144d835fe6a4a1a67d9c3.tar.gz bugzilla-e7c1850247b48e8446c144d835fe6a4a1a67d9c3.tar.xz |
Bug 821889: Make it so that Splinter shouts loudly when a patch introduces Windows line endings
Diffstat (limited to 'extensions/Splinter/web')
-rw-r--r-- | extensions/Splinter/web/splinter.css | 2 | ||||
-rw-r--r-- | extensions/Splinter/web/splinter.js | 10 |
2 files changed, 8 insertions, 4 deletions
diff --git a/extensions/Splinter/web/splinter.css b/extensions/Splinter/web/splinter.css index e43dff8fa..7e27372b3 100644 --- a/extensions/Splinter/web/splinter.css +++ b/extensions/Splinter/web/splinter.css @@ -34,7 +34,7 @@ textarea:focus { margin-bottom: 1em; } -#attachObsolete { +#attachWarning { font-weight: bold; color: #c00000; } diff --git a/extensions/Splinter/web/splinter.js b/extensions/Splinter/web/splinter.js index a3220a158..b43ad0736 100644 --- a/extensions/Splinter/web/splinter.js +++ b/extensions/Splinter/web/splinter.js @@ -2620,9 +2620,13 @@ Splinter.init = function () { Dom.get("attachCreator").appendChild(document.createTextNode(Splinter.Bug._formatWho(Splinter.theAttachment.whoName, Splinter.theAttachment.whoEmail))); Dom.get("attachDate").innerHTML = Splinter.Utils.formatDate(Splinter.theAttachment.date); - if (Splinter.theAttachment.isObsolete) { - Dom.get("attachObsolete").innerHTML = 'OBSOLETE'; - } + var warnings = []; + if (Splinter.theAttachment.isObsolete) + warnings.push('OBSOLETE'); + if (Splinter.theAttachment.isCRLF) + warnings.push('WINDOWS PATCH'); + if (warnings.length > 0) + Dom.get("attachWarning").innerHTML = warnings.join(', '); Dom.setStyle('attachInfo', 'display', 'block'); Dom.setStyle('quickHelpShow', 'display', 'block'); |