[gnome-shell] workspace: Use globals for delays and animation times
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] workspace: Use globals for delays and animation times
- Date: Thu, 31 Jan 2019 17:47:08 +0000 (UTC)
commit 193e4ae31ea585fb3da2e2d0e0083c9c06eec01f
Author: verdre <verdre v0yd nl>
Date: Mon Nov 19 12:28:28 2018 +0100
workspace: Use globals for delays and animation times
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/346
js/ui/workspace.js | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/js/ui/workspace.js b/js/ui/workspace.js
index f3b557e7e..6e3be18a6 100644
--- a/js/ui/workspace.js
+++ b/js/ui/workspace.js
@@ -22,8 +22,11 @@ var WINDOW_DND_SIZE = 256;
var WINDOW_CLONE_MAXIMUM_SCALE = 1.0;
+var WINDOW_OVERLAY_IDLE_HIDE_TIMEOUT = 750;
var CLOSE_BUTTON_FADE_TIME = 0.1;
+var WINDOW_REPOSITIONING_DELAY = 750;
+
var DRAGGING_WINDOW_OPACITY = 100;
// When calculating a layout, we calculate the scale of windows and the percent
@@ -674,7 +677,7 @@ var WindowOverlay = class {
_onHideChrome() {
if (this._idleToggleCloseId == 0) {
- this._idleToggleCloseId = Mainloop.timeout_add(750, this._idleToggleCloseButton.bind(this));
+ this._idleToggleCloseId = Mainloop.timeout_add(WINDOW_OVERLAY_IDLE_HIDE_TIMEOUT,
this._idleToggleCloseButton.bind(this));
GLib.Source.set_name_by_id(this._idleToggleCloseId, '[gnome-shell] this._idleToggleCloseButton');
}
}
@@ -1477,7 +1480,7 @@ var Workspace = class {
this._cursorY = y;
this._currentLayout = null;
- this._repositionWindowsId = Mainloop.timeout_add(750,
+ this._repositionWindowsId = Mainloop.timeout_add(WINDOW_REPOSITIONING_DELAY,
this._delayedWindowRepositioning.bind(this));
GLib.Source.set_name_by_id(this._repositionWindowsId, '[gnome-shell]
this._delayedWindowRepositioning');
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]