From 3572f5fbdababce97bda919ab960cdc86d1554ae Mon Sep 17 00:00:00 2001 From: Sebastian Serth Date: Wed, 24 Nov 2021 09:16:06 +0100 Subject: [PATCH] Introduce REQUEST_TOOLTIP_DELAY --- app/assets/javascripts/editor/editor.js.erb | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/app/assets/javascripts/editor/editor.js.erb b/app/assets/javascripts/editor/editor.js.erb index 3b0a0281..d4015a48 100644 --- a/app/assets/javascripts/editor/editor.js.erb +++ b/app/assets/javascripts/editor/editor.js.erb @@ -17,6 +17,7 @@ var CodeOceanEditor = { //Request-For-Comments-Configuration REQUEST_FOR_COMMENTS_DELAY: 0, REQUEST_TOOLTIP_TIME: 5000, + REQUEST_TOOLTIP_DELAY: 10 * 60 * 1000, editors: [], editor_for_file: new Map(), @@ -444,10 +445,12 @@ var CodeOceanEditor = { setTimeout(function () { button.prop('disabled', false); - button.tooltip('show'); setTimeout(function () { - button.tooltip('hide'); - }, this.REQUEST_TOOLTIP_TIME); + button.tooltip('show'); + setTimeout(function () { + button.tooltip('hide'); + }, this.REQUEST_TOOLTIP_TIME); + }, this.REQUEST_TOOLTIP_DELAY) }.bind(this), this.REQUEST_FOR_COMMENTS_DELAY); },