minor updates

This commit is contained in:
sawka
2023-02-03 16:26:56 -08:00
parent ab92fc5f29
commit d6e0c038e4
4 changed files with 6 additions and 6 deletions
+1 -1
View File
@@ -340,7 +340,7 @@ class LineCmd extends React.Component<{sw : ScreenWindow, line : LineType, width
let model = GlobalModel;
let termWrap = sw.getTermWrap(line.cmdid);
if (termWrap != null) {
termWrap.reloadTerminal(500);
termWrap.reload(500);
}
}
+1 -3
View File
@@ -557,7 +557,7 @@ class ScreenWindow {
if (line.contentheight != null && line.contentheight != -1) {
usedRows = line.contentheight;
}
let termContext = {sessionId: this.sessionId, screenId: this.screenId, windowId: this.windowId, cmdId: cmdId, lineNum: line.linenum};
let termContext = {sessionId: this.sessionId, screenId: this.screenId, windowId: this.windowId, cmdId: cmdId, lineId : line.lineid, lineNum: line.linenum};
termWrap = new TermWrap(elem, {
termContext: termContext,
usedRows: usedRows,
@@ -1761,8 +1761,6 @@ class Model {
let term = sw.getTermWrap(cmdId);
if (term != null) {
term.setIsRunning(cmdStatusIsRunning(newStatus));
term.updateUsedRows(true, "cmd-status");
// setTimeout(() => term.updateUsedRows(true), 500);
}
}
}
+3 -2
View File
@@ -109,7 +109,7 @@ class TermWrap {
if (opts.customKeyHandler != null) {
this.terminal.attachCustomKeyEventHandler((e) => opts.customKeyHandler(e, this));
}
this.reloadTerminal(0);
this.reload(0);
}
@boundMethod
@@ -244,7 +244,7 @@ class TermWrap {
return sprintf(GlobalModel.getBaseHostPort() + "/api/ptyout?sessionid=%s&cmdid=%s", termContext.sessionId, termContext.cmdId);
}
reloadTerminal(delayMs : number) {
reload(delayMs : number) {
if (this.terminal == null) {
return;
}
@@ -315,6 +315,7 @@ class TermWrap {
setIsRunning(isRunning : boolean) {
this.isRunning = isRunning;
this.updateUsedRows(true, "cmd-status");
}
}
+1
View File
@@ -338,6 +338,7 @@ type NormalTermContext = {
screenId : string,
windowId : string,
cmdId : string,
lineId : string,
lineNum : number,
};