mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-20 07:57:59 +01:00
Fix <C-[> passing and causing a history back event in command line mode. Fix reinitialization when not purging module globals.
This commit is contained in:
5
common/bootstrap.js
vendored
5
common/bootstrap.js
vendored
@@ -147,13 +147,14 @@ function init() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Services.obs.notifyObservers(null, "dactyl-rehash", null);
|
|
||||||
|
|
||||||
JSMLoader.load("resource://dactyl/base.jsm", global);
|
JSMLoader.load("resource://dactyl/base.jsm", global);
|
||||||
|
|
||||||
for each (let component in components)
|
for each (let component in components)
|
||||||
component.register();
|
component.register();
|
||||||
|
|
||||||
|
Services.obs.notifyObservers(null, "dactyl-rehash", null);
|
||||||
|
JSMLoader.load("resource://dactyl/base.jsm", global);
|
||||||
|
|
||||||
require(global, "services");
|
require(global, "services");
|
||||||
|
|
||||||
let manifestText = result.map(function (line) line.join(" ")).join("\n");
|
let manifestText = result.map(function (line) line.join(" ")).join("\n");
|
||||||
|
|||||||
@@ -935,10 +935,11 @@ var CommandLine = Module("commandline", {
|
|||||||
}
|
}
|
||||||
else if (event.type == "keypress") {
|
else if (event.type == "keypress") {
|
||||||
let key = events.toString(event);
|
let key = events.toString(event);
|
||||||
|
util.dump("keypress", key, Events.isEscape(event));
|
||||||
if (this._completions)
|
if (this._completions)
|
||||||
this._completions.previewClear();
|
this._completions.previewClear();
|
||||||
if (!this.currentExtendedMode)
|
if (!this.currentExtendedMode)
|
||||||
return;
|
return !Events.isEscape(event);
|
||||||
|
|
||||||
// user pressed <Enter> to carry out a command
|
// user pressed <Enter> to carry out a command
|
||||||
// user pressing <Esc> is handled in the global onEscape
|
// user pressing <Esc> is handled in the global onEscape
|
||||||
@@ -977,10 +978,8 @@ var CommandLine = Module("commandline", {
|
|||||||
modes.pop();
|
modes.pop();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
|
||||||
//this.resetCompletions();
|
|
||||||
}
|
|
||||||
// allow this event to be handled by the host app
|
// allow this event to be handled by the host app
|
||||||
|
return !Events.isEscape(event);
|
||||||
}
|
}
|
||||||
else if (event.type == "keyup") {
|
else if (event.type == "keyup") {
|
||||||
let key = events.toString(event);
|
let key = events.toString(event);
|
||||||
@@ -991,9 +990,7 @@ var CommandLine = Module("commandline", {
|
|||||||
catch (e) {
|
catch (e) {
|
||||||
dactyl.reportError(e, true);
|
dactyl.reportError(e, true);
|
||||||
}
|
}
|
||||||
finally {
|
|
||||||
return true;
|
return true;
|
||||||
}
|
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user