Update when scroll,stream flags are flipped

This commit is contained in:
gconsidine
2018-02-22 15:45:09 -05:00
committed by Jake McDermott
parent 5c3cf83d08
commit 60a43015e2
2 changed files with 12 additions and 8 deletions

View File

@@ -1,6 +1,4 @@
.at-Stdout { .at-Stdout {
font-family: monospace;
&-menuTop { &-menuTop {
color: @at-gray-848992; color: @at-gray-848992;
border: 1px solid @at-gray-b7; border: 1px solid @at-gray-b7;
@@ -123,6 +121,7 @@
} }
&-container { &-container {
font-family: monospace;
height: calc(~"100vh - 240px"); height: calc(~"100vh - 240px");
overflow-y: scroll; overflow-y: scroll;
font-size: 15px; font-size: 15px;

View File

@@ -115,6 +115,12 @@ function processWebSocketEvents (scope, data) {
vm.stream.isActive = false; vm.stream.isActive = false;
} }
if (!vm.scroll.isLocked) {
vm.scroll.isActive = false;
return;
}
if (vm.stream.count % resource.page.size === 0) { if (vm.stream.count % resource.page.size === 0) {
cache.push({ cache.push({
page: vm.stream.page page: vm.stream.page
@@ -153,12 +159,11 @@ function render (events) {
events = buffer.slice(0, buffer.length); events = buffer.slice(0, buffer.length);
buffer = []; buffer = [];
return render(events) return render(events);
.then(() => { } else {
vm.stream.isRendering = false; vm.stream.isRendering = false;
vm.scroll.isLocked = false; vm.scroll.isLocked = false;
vm.scroll.isActive = false; vm.scroll.isActive = false;
});
} }
} else { } else {
vm.stream.isRendering = false; vm.stream.isRendering = false;