More code review fixes
This commit is contained in:
parent
abaca6c8ef
commit
ec2f6af1d0
|
@ -509,7 +509,7 @@ exports.MenuModule = class MenuModule extends PluginModule {
|
||||||
|
|
||||||
this.optionalMoveToPosition(position);
|
this.optionalMoveToPosition(position);
|
||||||
|
|
||||||
return theme.displayThemedPause(this.client, position, cb);
|
return theme.displayThemedPause(this.client, {position}, cb);
|
||||||
}
|
}
|
||||||
|
|
||||||
promptForInput( { formName, formId, promptName, prevFormName, position } = {}, options, cb) {
|
promptForInput( { formName, formId, promptName, prevFormName, position } = {}, options, cb) {
|
||||||
|
|
|
@ -585,8 +585,8 @@ function displayThemedPrompt(name, client, options, cb) {
|
||||||
return callback(null, promptConfig, artInfo);
|
return callback(null, promptConfig, artInfo);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(options.row != null) {
|
if(!_.isNil(options) && !_.isNil(options.position) && !_.isNil(options.position.row)) {
|
||||||
artInfo.startRow = options.row;
|
artInfo.startRow = options.position.row;
|
||||||
if(client.term.termHeight > 0 && artInfo.startRow + artInfo.height > client.term.termHeight) {
|
if(client.term.termHeight > 0 && artInfo.startRow + artInfo.height > client.term.termHeight) {
|
||||||
// in this case, we will have scrolled
|
// in this case, we will have scrolled
|
||||||
artInfo.startRow = client.term.termHeight - artInfo.height;
|
artInfo.startRow = client.term.termHeight - artInfo.height;
|
||||||
|
|
|
@ -73,6 +73,12 @@
|
||||||
// during the connect process, but provides better autoconfiguration of utf-8
|
// during the connect process, but provides better autoconfiguration of utf-8
|
||||||
checkUtf8Encoding : true
|
checkUtf8Encoding : true
|
||||||
|
|
||||||
|
// Checking the ANSI home position also requires the use of cursor position reports, which are not
|
||||||
|
// supported on all terminals. Using this with a terminal that does not support cursor position reports
|
||||||
|
// results in a 3 second delay during the connect process, but works around positioning problems with
|
||||||
|
// non-standard terminals.
|
||||||
|
checkAnsiHomePosition: true
|
||||||
|
|
||||||
// other options here include cp437TermList and utf8TermList, see config_default.js for more information
|
// other options here include cp437TermList and utf8TermList, see config_default.js for more information
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue