mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-23 18:42:27 +01:00
- TEXTAREA support! Not working perfectly, but for a one-day-work i am impressed myself,
now just needing to add commands with MOTION like cw or d0. Visual mode works already quite well. - gi support - BUG: special keys like home/end in the location bar stoped working by this dramatic changes
This commit is contained in:
@@ -226,7 +226,7 @@ function CommandLine() //{{{
|
||||
this.echo = function(str, flags)
|
||||
{
|
||||
var focused = document.commandDispatcher.focusedElement;
|
||||
if (/*!echo_allowed && focused && */focused == command_widget.inputField)
|
||||
if (focused && focused == command_widget.inputField || focused == multiline_input_widget.inputField)
|
||||
return false;
|
||||
|
||||
if (typeof str != "string")
|
||||
@@ -249,7 +249,7 @@ function CommandLine() //{{{
|
||||
this.echoErr = function(str)
|
||||
{
|
||||
var focused = document.commandDispatcher.focusedElement;
|
||||
if (/*!echo_allowed && focused && */focused == command_widget.inputField)
|
||||
if (focused && focused == command_widget.inputField || focused == multiline_input_widget.inputField)
|
||||
return false;
|
||||
|
||||
setErrorStyle();
|
||||
@@ -296,6 +296,7 @@ function CommandLine() //{{{
|
||||
{
|
||||
multiline_input_widget.collapsed = true;
|
||||
multiline_output_widget.collapsed = true;
|
||||
completionlist.hide();
|
||||
|
||||
setPrompt(" "); // looks faster than an empty string as most prompts are 1 char long
|
||||
setCommand("");
|
||||
@@ -326,6 +327,9 @@ function CommandLine() //{{{
|
||||
}
|
||||
else if (event.type == "keypress")
|
||||
{
|
||||
if (!cur_extended_mode)
|
||||
return;
|
||||
|
||||
var key = vimperator.events.toString(event);
|
||||
|
||||
/* user pressed ENTER to carry out a command */
|
||||
@@ -550,7 +554,6 @@ function CommandLine() //{{{
|
||||
var key = vimperator.events.toString(event);
|
||||
if (vimperator.events.isAcceptKey(key))
|
||||
{
|
||||
//var lines = multiline_input_widget.value.substr(0, multiline_input_widget.selectionStart).split(/\n/);
|
||||
var text = multiline_input_widget.value.substr(0, multiline_input_widget.selectionStart);
|
||||
if (text.match(multiline_regexp))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user