Skip to content

Commit

Permalink
webdash: don't refresh task list in background
Browse files Browse the repository at this point in the history
  • Loading branch information
Alex Buchanan committed May 30, 2018
1 parent 9fc9c44 commit 97029bf
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 12 deletions.
8 changes: 8 additions & 0 deletions webdash/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -263,6 +263,14 @@ app.controller("TaskListController", function($rootScope, $scope, $http, $timeou
}, true)

function refresh(callback) {
// If tab/window is in the background, don't refresh.
if (document.hidden) {
if (callback) {
callback()
}
return
}

setUrlParams();
TaskService.OptimalList().then(function(response) {
$scope.$applyAsync(function() {
Expand Down
24 changes: 12 additions & 12 deletions webdash/web.go

Large diffs are not rendered by default.

0 comments on commit 97029bf

Please sign in to comment.