Skip to content

Commit

Permalink
Revert "[Delete] Stop the page refreshing"
Browse files Browse the repository at this point in the history
This reverts commit 05d6507.
  • Loading branch information
vmcj committed Aug 1, 2023
1 parent 325e57a commit 9d6cae4
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions webapp/public/js/domjudge.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ function reloadPage()
function initReload(refreshtime)
{
// interval is in seconds
//setTimeout(function() { reloadPage(); }, refreshtime * 1000);
setTimeout(function() { reloadPage(); }, refreshtime * 1000);
}

function collapse(x)
Expand Down Expand Up @@ -443,7 +443,7 @@ function processAjaxResponse(jqXHR, data) {
return;
}

/*var $refreshTarget = $('[data-ajax-refresh-target]');
var $refreshTarget = $('[data-ajax-refresh-target]');
var $data = $(data);
// When using the static scoreboard, we need to find the children of the [data-ajax-refresh-target]
var $dataRefreshTarget = $data.find('[data-ajax-refresh-target]');
Expand All @@ -456,11 +456,10 @@ function processAjaxResponse(jqXHR, data) {
$refreshTarget.html($data);
if ($refreshTarget.data('ajax-refresh-after')) {
window[$refreshTarget.data('ajax-refresh-after')]();
}*/
}
}
}

/*
var refreshHandler = null;
var refreshEnabled = false;
function enableRefresh($url, $after, usingAjax) {
Expand Down Expand Up @@ -499,7 +498,7 @@ function enableRefresh($url, $after, usingAjax) {
localStorage.setItem('scrollTop', $(window).scrollTop());
}, 100)
});
}*/
}

function disableRefresh(usingAjax) {
if (!refreshEnabled) {
Expand Down

0 comments on commit 9d6cae4

Please sign in to comment.