diff --git a/content/completion.js b/content/completion.js
index 0b7f0a8a..a750ace9 100644
--- a/content/completion.js
+++ b/content/completion.js
@@ -207,12 +207,7 @@ vimperator.Completion = function() // {{{
[["options"], "Configuration options"]]; // TODO: hardcoded until we have proper 'pages'
g_substrings = [];
for (var command in vimperator.commands)
- {
- help_array.push([command.long_names.map(function($_) {
- return ":" + $_;
- }),
- command.short_help])
- }
+ help_array.push([command.long_names.map(function($_) { return ":" + $_; }), command.short_help]);
options = this.get_options_completions(filter, true);
help_array = help_array.concat(options.map(function($_) {
return [
@@ -221,7 +216,7 @@ vimperator.Completion = function() // {{{
];
}));
for (var map in vimperator.mappings)
- help_array.push([map.names, map.short_help])
+ help_array.push([map.names, map.short_help]);
if (!filter) return help_array.map(function($_) {
return [$_[0][0], $_[1]]; // unfiltered, use the first command
@@ -233,7 +228,7 @@ vimperator.Completion = function() // {{{
get_command_completions: function(filter) //{{{
{
g_substrings = [];
- var completions = []
+ var completions = [];
if (!filter)
{
for (var command in vimperator.commands)
@@ -262,7 +257,7 @@ vimperator.Completion = function() // {{{
{
if (prefix && option.type != "boolean")
continue;
- options.push([option.names, option.short_help])
+ options.push([option.names, option.short_help]);
}
return options;
}
@@ -274,7 +269,7 @@ vimperator.Completion = function() // {{{
{
if (prefix && option.type != "boolean")
continue;
- options.push([prefix + option.name, option.short_help])
+ options.push([prefix + option.name, option.short_help]);
}
return options;
}
@@ -442,7 +437,11 @@ vimperator.Completion = function() // {{{
" else {" +
" comp.push([[i], type]); }" +
"} comp;");
- } catch (e) { completions = []; };
+ }
+ catch (e)
+ {
+ completions = [];
+ }
return build_longest_starting_substring(completions, filter);
}, // }}}
diff --git a/content/events.js b/content/events.js
index 76f30a5b..4799ff98 100644
--- a/content/events.js
+++ b/content/events.js
@@ -40,7 +40,7 @@ vimperator.Events = function() //{{{
// any tab related events
var tabcontainer = getBrowser().tabContainer;
tabcontainer.addEventListener("TabMove", function(event) {
- vimperator.statusline.updateTabCount()
+ vimperator.statusline.updateTabCount();
vimperator.buffer.updateBufferList();
}, false);
tabcontainer.addEventListener("TabOpen", function(event) {
@@ -48,7 +48,7 @@ vimperator.Events = function() //{{{
vimperator.buffer.updateBufferList();
}, false);
tabcontainer.addEventListener("TabClose", function(event) {
- vimperator.statusline.updateTabCount()
+ vimperator.statusline.updateTabCount();
vimperator.buffer.updateBufferList();
}, false);
tabcontainer.addEventListener("TabSelect", function(event) {
@@ -156,7 +156,7 @@ vimperator.Events = function() //{{{
[ KeyEvent.DOM_VK_F21, ["F21"] ],
[ KeyEvent.DOM_VK_F22, ["F22"] ],
[ KeyEvent.DOM_VK_F23, ["F23"] ],
- [ KeyEvent.DOM_VK_F24, ["F24"] ],
+ [ KeyEvent.DOM_VK_F24, ["F24"] ]
];
function getKeyCode(str)
@@ -384,13 +384,13 @@ vimperator.Events = function() //{{{
switch (event.button)
{
case 0:
- key = "LeftMouse"
+ key = "LeftMouse";
break;
case 1:
- key = "MiddleMouse"
+ key = "MiddleMouse";
break;
case 2:
- key = "RightMouse"
+ key = "RightMouse";
break;
}
}
@@ -815,9 +815,9 @@ vimperator.Events = function() //{{{
},
// stub functions for the interfaces
- setJSStatus : function(status) { ; },
- setJSDefaultStatus : function(status) { ; },
- setDefaultStatus : function(status) { ; },
+ setJSStatus: function(status) { ; },
+ setJSDefaultStatus: function(status) { ; },
+ setDefaultStatus: function(status) { ; },
onLinkIconAvailable: function() { ; }
};
diff --git a/content/find.js b/content/find.js
index da30e914..a8252149 100644
--- a/content/find.js
+++ b/content/find.js
@@ -81,7 +81,7 @@ vimperator.Search = function() //{{{
links_only = false;
// strip links-only modifiers
- pattern = pattern.replace(/(\\)?\\[uU]/g, function($0, $1) { return $1 ? $0 : "" });
+ pattern = pattern.replace(/(\\)?\\[uU]/g, function($0, $1) { return $1 ? $0 : ""; });
// case sensitivity - \c wins if both modifiers specified
if (/\c/.test(pattern))
@@ -96,10 +96,10 @@ vimperator.Search = function() //{{{
case_sensitive = true;
// strip case-sensitive modifiers
- pattern = pattern.replace(/(\\)?\\[cC]/g, function($0, $1) { return $1 ? $0 : "" });
+ pattern = pattern.replace(/(\\)?\\[cC]/g, function($0, $1) { return $1 ? $0 : ""; });
// remove any modifer escape \
- pattern = pattern.replace(/\\(\\[cCuU])/g, '$1')
+ pattern = pattern.replace(/\\(\\[cCuU])/g, '$1');
search_string = pattern;
}
@@ -229,15 +229,15 @@ vimperator.Search = function() //{{{
if (!text)
text = last_search_string;
- gFindBar._setCaseSensitivity(case_sensitive)
+ gFindBar._setCaseSensitivity(case_sensitive);
gFindBar._highlightDoc("white", "black", text);
// TODO: seems fast enough for now...just
(function(win)
{
for (var i = 0; i < win.frames.length; i++)
- arguments.callee(win.frames[i])
- var spans = window.content.document.getElementsByClassName("__mozilla-findbar-search")
+ arguments.callee(win.frames[i]);
+ var spans = window.content.document.getElementsByClassName("__mozilla-findbar-search");
for (var i = 0; i < spans.length; i++)
spans[i].setAttribute("style", vimperator.options["hlsearchstyle"]);
})(window.content);
diff --git a/content/help.js b/content/help.js
index 45e054ac..a538b674 100644
--- a/content/help.js
+++ b/content/help.js
@@ -155,7 +155,7 @@ vimperator.help = function(section, easter) //{{{
' ' +
'' +
- '
Of course as a believer in free open source software, only make a donation if you really like Vimperator and the money doesn\'t hurt - otherwise just use it, recommend it and like it :)
'
+ 'Of course as a believer in free open source software, only make a donation if you really like Vimperator and the money doesn\'t hurt - otherwise just use it, recommend it and like it :)
';
var initialization = 'initializationInitialization ' +
'At startup Vimperator sources a user RC file, containing Ex commands, and any JavaScript files found in the plugin directory.
' +
@@ -178,7 +178,7 @@ vimperator.help = function(section, easter) //{{{
var mappings = 'mappingsMappings ' +
'The denotion of modifier keys is like in Vim, so C- means the Control key, M- the Meta key, A- the Alt key and S- the Shift key.
'+
- ''
+ '';
mappings += makeHelpString(vimperator.mappings, "", "", null);
mappings += '
';
if (section && section == 'holy-grail')
diff --git a/content/hints.js b/content/hints.js
index 87a94da7..6f39d9c0 100644
--- a/content/hints.js
+++ b/content/hints.js
@@ -74,7 +74,7 @@ vimperator.Hints = function() //{{{
elem.dispatchEvent(evt);
return true;
- };
+ }
function focusHint()
{
@@ -107,7 +107,7 @@ vimperator.Hints = function() //{{{
evt.initMouseEvent('mouseover', true, true, doc.defaultView, 1, x, y, 0, 0, 0, 0, 0, 0, 0, null);
elem.dispatchEvent(evt);
- };
+ }
function yankHint(text)
{
@@ -121,7 +121,7 @@ vimperator.Hints = function() //{{{
vimperator.copyToClipboard(loc);
vimperator.echo("Yanked " + loc, vimperator.commandline.FORCE_SINGLELINE);
- };
+ }
function saveHint(skip_prompt)
{
@@ -392,7 +392,7 @@ outer:
catch (e) { vimperator.log("Error hiding hints, probably wrong window"); }
reset();
- };
+ }
function processHints(followFirst)
{
@@ -453,7 +453,7 @@ outer:
}
return true;
- };
+ }
////////////////////////////////////////////////////////////////////////////////
////////////////////// PUBLIC SECTION //////////////////////////////////////////
diff --git a/content/mappings.js b/content/mappings.js
index 0c88f2fd..fda80c1c 100644
--- a/content/mappings.js
+++ b/content/mappings.js
@@ -147,7 +147,7 @@ vimperator.Mappings = function() //{{{
{
if (names[j] == cmd)
{
- names.splice(j, 1)
+ names.splice(j, 1);
if (names.length == 0)
maps.splice(i, 1);
@@ -269,7 +269,7 @@ vimperator.Mappings = function() //{{{
{
// for < only return a candidate if it doesn't seem like a mapping
if (cmd != "<" || !/^<.+>/.test(map.names[j]))
- matches.push(map)
+ matches.push(map);
}
}
}
@@ -293,7 +293,7 @@ vimperator.Mappings = function() //{{{
for (var j = 0; j < maps[i].names.length; j++)
{
list += "";
- list += " " + vimperator.util.escapeHTML(maps[i].names[j]) + " "
+ list += " " + vimperator.util.escapeHTML(maps[i].names[j]) + " ";
if (maps[i].rhs)
list += " " + vimperator.util.escapeHTML(maps[i].rhs) + " "
list += " ";
@@ -494,7 +494,7 @@ vimperator.Mappings = function() //{{{
}
));
addDefaultMap(new vimperator.Map([vimperator.modes.NORMAL], ["go"],
- function(arg) { vimperator.quickmarks.jumpTo(arg, vimperator.CURRENT_TAB) },
+ function(arg) { vimperator.quickmarks.jumpTo(arg, vimperator.CURRENT_TAB); },
{
short_help: "Jump to a QuickMark in the current tab",
usage: ["go{a-zA-Z0-9}"],
@@ -564,7 +564,7 @@ vimperator.Mappings = function() //{{{
// should probably reopen the closed tab when a 'deleted'
// alternate is selected
if (index == -1)
- vimperator.echoerr("E86: Buffer does not exist") // TODO: This should read "Buffer N does not exist"
+ vimperator.echoerr("E86: Buffer does not exist"); // TODO: This should read "Buffer N does not exist"
else
vimperator.tabs.select(index);
},
@@ -583,7 +583,7 @@ vimperator.Mappings = function() //{{{
return;
}
- vimperator.marks.add(arg)
+ vimperator.marks.add(arg);
},
{
short_help: "Set mark at the cursor position",
@@ -593,7 +593,7 @@ vimperator.Mappings = function() //{{{
}
));
addDefaultMap(new vimperator.Map([vimperator.modes.NORMAL], ["'", "`"],
- function(arg) { vimperator.marks.jumpTo(arg) },
+ function(arg) { vimperator.marks.jumpTo(arg); },
{
short_help: "Jump to the mark in the current buffer",
usage: ["'{a-zA-Z}"],
@@ -610,7 +610,7 @@ vimperator.Mappings = function() //{{{
return;
}
- vimperator.quickmarks.add(arg, vimperator.buffer.URL)
+ vimperator.quickmarks.add(arg, vimperator.buffer.URL);
},
{
short_help: "Add new QuickMark for current URL",
diff --git a/content/tabs.js b/content/tabs.js
index 33e38fb4..8016fb8a 100644
--- a/content/tabs.js
+++ b/content/tabs.js
@@ -256,7 +256,8 @@ vimperator.Tabs = function() //{{{
{
this.reload(getBrowser().mTabs[i], bypass_cache)
}
- catch (e) {
+ catch (e)
+ {
// FIXME: can we do anything useful here without stopping the
// other tabs from reloading?
}
diff --git a/content/ui.js b/content/ui.js
index ebe91ffb..8c73496f 100644
--- a/content/ui.js
+++ b/content/ui.js
@@ -93,7 +93,7 @@ vimperator.CommandLine = function() //{{{
// for the example command "open sometext| othertext" (| is the cursor pos):
var completion_start_index = 0; // will be 5 because we want to complete arguments for the :open command
- var completion_prefix = "" // will be: "open sometext"
+ var completion_prefix = ""; // will be: "open sometext"
var completion_postfix = ""; // will be: " othertext"
var wild_index = 0; // keep track how often we press in a row
@@ -673,7 +673,7 @@ vimperator.CommandLine = function() //{{{
if (vimperator.options["more"] && isScrollable() && !atEnd())
win.scrollByLines(1);
else
- close_window = true;; // don't propagate the event for accept keys
+ close_window = true; // don't propagate the event for accept keys
break;
// up a line
@@ -798,7 +798,7 @@ vimperator.CommandLine = function() //{{{
// close the window
case "q":
- close_window = true;;
+ close_window = true;
break;
// unmapped key
diff --git a/content/vimperator.js b/content/vimperator.js
index 59343aaa..4406e186 100644
--- a/content/vimperator.js
+++ b/content/vimperator.js
@@ -101,7 +101,7 @@ const vimperator = (function() //{{{
popup.height = box.height;
popup.width = box.width;
- popup.openPopup(win, "overlap", 0, 0, false, false)
+ popup.openPopup(win, "overlap", 0, 0, false, false);
setTimeout(function() { popup.hidePopup(); }, 50);
}
else
@@ -278,7 +278,7 @@ const vimperator = (function() //{{{
string += i + ": " + value + "\n";
}
}
- catch (e) { };
+ catch (e) { }
return string;
},
@@ -342,7 +342,7 @@ const vimperator = (function() //{{{
var wm = Components.classes["@mozilla.org/appshell/window-mediator;1"]
.getService(Components.interfaces.nsIWindowMediator);
whichwindow = wm.getMostRecentWindow("navigator:browser");
- whichwindow.loadURI(url, null, postdata)
+ whichwindow.loadURI(url, null, postdata);
break;
default:
@@ -609,8 +609,8 @@ const vimperator = (function() //{{{
vimperator.completion = new vimperator.Completion();
vimperator.log("All modules loaded", 3);
- vimperator.echo = function(str, flags) { vimperator.commandline.echo(str, vimperator.commandline.HL_NORMAL, flags); }
- vimperator.echoerr = function(str, flags) { vimperator.commandline.echo(str, vimperator.commandline.HL_ERRORMSG, flags); }
+ vimperator.echo = function(str, flags) { vimperator.commandline.echo(str, vimperator.commandline.HL_NORMAL, flags); };
+ vimperator.echoerr = function(str, flags) { vimperator.commandline.echo(str, vimperator.commandline.HL_ERRORMSG, flags); };
vimperator.globalVariables = {};
@@ -735,7 +735,7 @@ const vimperator = (function() //{{{
{
func.apply(window, args);
}
- }
+ };
}
if (!thread)