mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-23 02:37:58 +01:00
minor formatting fixes
This commit is contained in:
@@ -375,7 +375,7 @@ vimperator.Editor = function () //{{{
|
||||
// vimperator.echoerr("External editor returned with exit code " + retcode);
|
||||
// }
|
||||
// else
|
||||
{
|
||||
// {
|
||||
try
|
||||
{
|
||||
var val = vimperator.io.readFile(tmpfile);
|
||||
@@ -386,7 +386,7 @@ vimperator.Editor = function () //{{{
|
||||
tmpBg = "red";
|
||||
vimperator.echoerr("Could not read from temporary file " + tmpfile.path + ": " + e.message);
|
||||
}
|
||||
}
|
||||
// }
|
||||
|
||||
// blink the textbox after returning
|
||||
var timeout = 100;
|
||||
|
||||
@@ -1086,9 +1086,9 @@ vimperator.Mappings = function () //{{{
|
||||
for (var i = 0; i < count; i++)
|
||||
{
|
||||
if (isDirectory(url))
|
||||
url = url.replace(/^(.*?:)(.*?)([^\/]+\/*)$/, "$1$2/")
|
||||
url = url.replace(/^(.*?:)(.*?)([^\/]+\/*)$/, "$1$2/");
|
||||
else
|
||||
url = url.replace(/^(.*?:)(.*?)(\/+[^\/]+)$/, "$1$2/")
|
||||
url = url.replace(/^(.*?:)(.*?)(\/+[^\/]+)$/, "$1$2/");
|
||||
}
|
||||
url = url.replace(/^(.*:\/+.*?)\/+$/, "$1/"); // get rid of more than 1 / at the end
|
||||
|
||||
|
||||
@@ -1206,11 +1206,16 @@ vimperator.StatusLine = function () //{{{
|
||||
|
||||
var bufferPositionStr = "";
|
||||
percent = Math.round(percent * 100);
|
||||
if (percent < 0) bufferPositionStr = "All";
|
||||
else if (percent == 0) bufferPositionStr = "Top";
|
||||
else if (percent < 10) bufferPositionStr = " " + percent + "%";
|
||||
else if (percent >= 100) bufferPositionStr = "Bot";
|
||||
else bufferPositionStr = percent + "%";
|
||||
if (percent < 0)
|
||||
bufferPositionStr = "All";
|
||||
else if (percent == 0)
|
||||
bufferPositionStr = "Top";
|
||||
else if (percent < 10)
|
||||
bufferPositionStr = " " + percent + "%";
|
||||
else if (percent >= 100)
|
||||
bufferPositionStr = "Bot";
|
||||
else
|
||||
bufferPositionStr = percent + "%";
|
||||
|
||||
bufferPositionWidget.value = bufferPositionStr;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user