1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-01-05 23:04:13 +01:00

Get rid of some 'config.name' checks in the common tree. These should all, ideally, go.

This commit is contained in:
Kris Maglione
2009-03-22 02:25:05 -04:00
parent c35cca159f
commit cf57844986
7 changed files with 59 additions and 48 deletions

View File

@@ -1212,36 +1212,8 @@ function Events() //{{{
return;
}
if (config.name == "Muttator")
{
// we switch to -- MESSAGE -- mode for Muttator, when the main HTML widget gets focus
if (hasHTMLDocument(win) || elem instanceof HTMLAnchorElement)
{
if (config.isComposeWindow)
{
//liberator.dump("Compose editor got focus");
modes.set(modes.INSERT, modes.TEXTAREA);
}
else if (liberator.mode != modes.MESSAGE)
liberator.mode = modes.MESSAGE;
return;
}
}
if (config.name == "Xulmus")
{
// Switch to -- PLAYER -- mode for Songbird Media Player.
if (config.isPlayerWindow)
{
liberator.mode = modes.PLAYER;
}
else
{
liberator.mode = modes.NORMAL;
}
return;
}
if (config.focusChange())
return void config.focusChange(win);
urlbar = document.getElementById("urlbar");
if (elem == null && urlbar && urlbar.inputField == lastFocus)