From 72fc0d5fbfd43f147dc85c46124d24e82a5823ad Mon Sep 17 00:00:00 2001 From: Ian Neal Date: Mon, 16 Jul 2012 15:10:54 +0100 Subject: [PATCH] Bug 638643 - Remove obsolete EditorToggleParagraphMarks from editor.js f=kaze r=neil (unbitrotting by Px) --- .../composer/content/EditorParagraphMarks.css | 16 ------------- editor/ui/composer/content/editor.js | 23 ------------------- editor/ui/jar.mn | 1 - 3 files changed, 40 deletions(-) delete mode 100644 editor/ui/composer/content/EditorParagraphMarks.css diff --git a/editor/ui/composer/content/EditorParagraphMarks.css b/editor/ui/composer/content/EditorParagraphMarks.css deleted file mode 100644 index c915ba29f0..0000000000 --- a/editor/ui/composer/content/EditorParagraphMarks.css +++ /dev/null @@ -1,16 +0,0 @@ -/* This Source Code Form is subject to the terms of the Mozilla Public - * License, v. 2.0. If a copy of the MPL was not distributed with this - * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ - -/* This adds the standard paragraph symbol - * after paragraphs (block container tags) -*/ - -p:after,br:after, -h1:after,h2:after,h3:after,h4:after,h5:after,h6:after, -address:after,blockquote:after,listing:after, -plaintext:after, xmp:after, pre:after, -li:after,dt:after,dd:after -{ - content: "\B6 "; -} diff --git a/editor/ui/composer/content/editor.js b/editor/ui/composer/content/editor.js index 50a712cd07..42b10a57a5 100644 --- a/editor/ui/composer/content/editor.js +++ b/editor/ui/composer/content/editor.js @@ -18,7 +18,6 @@ const kDisplayModeMenuIDs = ["viewNormalMode", "viewAllTagsMode", "viewSourceMod const kDisplayModeTabIDS = ["NormalModeButton", "TagModeButton", "SourceModeButton", "PreviewModeButton"]; const kNormalStyleSheet = "chrome://editor/content/EditorContent.css"; const kAllTagsStyleSheet = "chrome://editor/content/EditorAllTags.css"; -const kParagraphMarksStyleSheet = "chrome://editor/content/EditorParagraphMarks.css"; const kContentEditableStyleSheet = "resource://gre/res/contenteditable.css"; const kTextMimeType = "text/plain"; @@ -1831,28 +1830,6 @@ function SetDisplayMode(mode) return true; } -function EditorToggleParagraphMarks() -{ - var menuItem = document.getElementById("viewParagraphMarks"); - if (menuItem) - { - // Note that the 'type="checbox"' mechanism automatically - // toggles the "checked" state before the oncommand is called, - // so if "checked" is true now, it was just switched to that mode - var checked = menuItem.getAttribute("checked"); - try { - var editor = GetCurrentEditor(); - editor.QueryInterface(nsIEditorStyleSheets); - - if (checked == "true") - editor.addOverrideStyleSheet(kParagraphMarksStyleSheet); - else - editor.enableStyleSheet(kParagraphMarksStyleSheet, false); - } - catch(e) { return; } - } -} - function UpdateWindowTitle() { try { diff --git a/editor/ui/jar.mn b/editor/ui/jar.mn index 671e800d51..e5ce452c5e 100644 --- a/editor/ui/jar.mn +++ b/editor/ui/jar.mn @@ -89,7 +89,6 @@ comm.jar: content/editor/EditorContextMenu.js (composer/content/EditorContextMenu.js) content/editor/EditorContextMenuOverlay.xul (composer/content/EditorContextMenuOverlay.xul) content/editor/EditorAllTags.css (composer/content/EditorAllTags.css) - content/editor/EditorParagraphMarks.css (composer/content/EditorParagraphMarks.css) content/editor/editorOverlay.xul (composer/content/editorOverlay.xul) content/editor/editingOverlay.xul (composer/content/editingOverlay.xul) content/editor/composerOverlay.xul (composer/content/composerOverlay.xul)