diff --git a/chrome/content/vimperator/bookmarks.js b/chrome/content/vimperator/bookmarks.js index 75b9f5e3..7e12984a 100644 --- a/chrome/content/vimperator/bookmarks.js +++ b/chrome/content/vimperator/bookmarks.js @@ -722,15 +722,14 @@ function QuickMarks() //{{{ /////////////////////////////////////////////////////////////////////////////{{{ var qmarks = {}; - // load the saved quickmarks -- TODO: change to sqlite var saved_marks = Options.getPref("quickmarks", "").split("\n"); + // load the saved quickmarks -- TODO: change to sqlite for (var i = 0; i < saved_marks.length - 1; i += 2) { qmarks[saved_marks[i]] = saved_marks[i + 1]; } - // TODO: should we sort by a-zA-Z0-9 rather than 0-9A-Za-z? /////////////////////////////////////////////////////////////////////////////}}} ////////////////////// PUBLIC SECTION ////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////{{{ @@ -751,6 +750,11 @@ function QuickMarks() //{{{ } } + this.removeAll = function() + { + qmarks = {}; + } + this.jumpTo = function(qmark, where) { var url = qmarks[qmark]; diff --git a/chrome/content/vimperator/commands.js b/chrome/content/vimperator/commands.js index 3d8921c1..1983df55 100644 --- a/chrome/content/vimperator/commands.js +++ b/chrome/content/vimperator/commands.js @@ -445,7 +445,10 @@ function Commands() //{{{ return } - vimperator.quickmarks.remove(args); + if (special) + vimperator.quickmarks.removeAll(); + else + vimperator.quickmarks.remove(args); }, { usage: ["delqm[arks] {marks}", "delqm[arks]!"],