diff --git a/common/content/bookmarks.js b/common/content/bookmarks.js index 8392c871..5665a9ee 100644 --- a/common/content/bookmarks.js +++ b/common/content/bookmarks.js @@ -34,17 +34,16 @@ const Bookmarks = Module("bookmarks", { add: function add(starOnly, title, url, keyword, tags, force) { try { let uri = util.createURI(url); - if (!force && bookmarks.isBookmarked(uri.spec)) { + if (force && bookmarks.isBookmarked(uri.spec)) // WTF? This seems wrong... --Kris - for (let bmark in bookmarkcache) { + for (let bmark in bookmarkcache) if (bmark[0] == uri.spec) { var id = bmark[5]; if (title) services.get("bookmarks").setItemTitle(id, title); break; } - } - } + if (id == undefined) id = services.get("bookmarks").insertBookmark( services.get("bookmarks")[starOnly ? "unfiledBookmarksFolder" : "bookmarksMenuFolder"], diff --git a/common/content/commands.js b/common/content/commands.js index ca179b67..4e091f19 100644 --- a/common/content/commands.js +++ b/common/content/commands.js @@ -914,6 +914,7 @@ const Commands = Module("commands", { // dynamically get completions as specified with the command's completer function let command = cmd && commands.get(cmd); if (!command) { + context.highlight(); context.highlight(0, cmd && cmd.length, "SPELLCHECK"); return; } diff --git a/common/content/hints.js b/common/content/hints.js index 4095eddd..87c6baa3 100644 --- a/common/content/hints.js +++ b/common/content/hints.js @@ -266,6 +266,7 @@ const Hints = Module("hints", { hint.span = baseNodeAbsolute.cloneNode(true); + rect = elem.getClientRects()[0] || rect; let leftPos = Math.max((rect.left + offsetX), offsetX); let topPos = Math.max((rect.top + offsetY), offsetY); diff --git a/common/modules/bookmarkcache.jsm b/common/modules/bookmarkcache.jsm index b443a7fe..bbcf690e 100644 --- a/common/modules/bookmarkcache.jsm +++ b/common/modules/bookmarkcache.jsm @@ -29,7 +29,7 @@ const BookmarkCache = Module("BookmarkCache", { bookmarks.addObserver(this, false); }, - __iterator__: function () (val for ([, val] in Iterator(this.bookmarks))), + __iterator__: function () (val for ([, val] in Iterator(bookmarkcache.bookmarks))), get bookmarks() Class.replaceProperty(this, "bookmarks", this.load()),