mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-03-10 04:25:44 +01:00
fixed :help for thunderbird
This commit is contained in:
@@ -1045,7 +1045,7 @@ vimperator.Commands = function () //{{{
|
|||||||
{
|
{
|
||||||
function jumpToTag(file, tag)
|
function jumpToTag(file, tag)
|
||||||
{
|
{
|
||||||
vimperator.open("chrome://vimperator/locale/" + file);
|
vimperator.open("chrome://" + vimperator.config.name.toLowerCase() + "/locale/" + file);
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
var elem = vimperator.buffer.getElement('@class="tag" and text()="' + tag + '"');
|
var elem = vimperator.buffer.getElement('@class="tag" and text()="' + tag + '"');
|
||||||
if (elem)
|
if (elem)
|
||||||
@@ -1057,7 +1057,7 @@ vimperator.Commands = function () //{{{
|
|||||||
|
|
||||||
if (!args)
|
if (!args)
|
||||||
{
|
{
|
||||||
vimperator.open("chrome://vimperator/locale/intro.html");
|
vimperator.open("chrome://" + vimperator.config.name.toLowerCase() + "/locale/intro.html");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -258,11 +258,9 @@ vimperator.util = { //{{{
|
|||||||
// if the string doesn't look like a valid URL (i.e. contains a space
|
// if the string doesn't look like a valid URL (i.e. contains a space
|
||||||
// or does not contain any of: .:/) try opening it with a search engine
|
// or does not contain any of: .:/) try opening it with a search engine
|
||||||
// or keyword bookmark
|
// or keyword bookmark
|
||||||
var matches;
|
if (vimperator.has("bookmarks") && (/\s/.test(urls[url]) || !/[.:\/]/.test(urls[url])))
|
||||||
if (/\s/.test(urls[url]) || !/[.:\/]/.test(urls[url]))
|
|
||||||
{
|
{
|
||||||
matches = urls[url].match(/^(\S+)(?:\s+(.+))?$/);
|
var matches = urls[url].match(/^(\S+)(?:\s+(.+))?$/);
|
||||||
|
|
||||||
var alias = matches[1];
|
var alias = matches[1];
|
||||||
var text = matches[2] || null;
|
var text = matches[2] || null;
|
||||||
|
|
||||||
@@ -274,7 +272,7 @@ vimperator.util = { //{{{
|
|||||||
|
|
||||||
// check if the first word is a search engine
|
// check if the first word is a search engine
|
||||||
var searchURL = vimperator.bookmarks.getSearchURL(text, alias);
|
var searchURL = vimperator.bookmarks.getSearchURL(text, alias);
|
||||||
if (searchURL/* && searchURL.length >= 1*/)
|
if (searchURL)
|
||||||
{
|
{
|
||||||
urls[url] = searchURL;
|
urls[url] = searchURL;
|
||||||
continue;
|
continue;
|
||||||
@@ -282,7 +280,7 @@ vimperator.util = { //{{{
|
|||||||
else // the first word was not a search engine, search for the whole string in the default engine
|
else // the first word was not a search engine, search for the whole string in the default engine
|
||||||
{
|
{
|
||||||
searchURL = vimperator.bookmarks.getSearchURL(urls[url], null);
|
searchURL = vimperator.bookmarks.getSearchURL(urls[url], null);
|
||||||
if (searchURL/* && searchURL.length >= 1*/)
|
if (searchURL)
|
||||||
{
|
{
|
||||||
urls[url] = searchURL;
|
urls[url] = searchURL;
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
Reference in New Issue
Block a user