mirror of
https://github.com/wavetermdev/backup.git
synced 2026-08-05 13:57:07 -07:00
minor updates
This commit is contained in:
+1
-1
@@ -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
@@ -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
@@ -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");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -338,6 +338,7 @@ type NormalTermContext = {
|
||||
screenId : string,
|
||||
windowId : string,
|
||||
cmdId : string,
|
||||
lineId : string,
|
||||
lineNum : number,
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user