summaryrefslogtreecommitdiff
path: root/common/content/commandline.js
diff options
context:
space:
mode:
authorKris Maglione <maglione.k@gmail.com>2010-11-04 14:06:00 -0400
committerKris Maglione <maglione.k@gmail.com>2010-11-04 14:06:00 -0400
commitffcc8c6916ce949a12675f2e4eb69e0f6b3a1544 (patch)
tree2c253ddad42138d2213fd8aada7ed684e06c50af /common/content/commandline.js
parentf89e548b12ed9444214528b9be87419b1763acdb (diff)
downloadpentadactyl-ffcc8c6916ce949a12675f2e4eb69e0f6b3a1544.tar.gz
Closes issue #121. Only an issue on Firefox 4b6.
Diffstat (limited to 'common/content/commandline.js')
-rw-r--r--common/content/commandline.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/common/content/commandline.js b/common/content/commandline.js
index a66f3c77..f5ed57b4 100644
--- a/common/content/commandline.js
+++ b/common/content/commandline.js
@@ -42,13 +42,14 @@ const CommandWidgets = Class("CommandWidgets", {
getElement: CommandWidgets.getEditor,
getGroup: function (value) this.activeGroup.commandline,
onChange: function (elem) {
- if (!elem.collapsed && elem.inputField != dactyl.focus) {
+ if (elem.inputField != dactyl.focus) {
elem.selectionStart = elem.value.length;
elem.selectionEnd = elem.value.length;
- elem.focus();
}
+ if (elem.collapsed)
+ elem.focus();
},
- onVisibility: function (elem, visible) visible && elem.inputField != dactyl.focus && elem.focus()
+ onVisibility: function (elem, visible) visible && elem.focus()
});
this.addElem({
name: "prompt",