From 27a71946340970fb1f5f1f4e49d2c16ca359be6d Mon Sep 17 00:00:00 2001 From: Jakub Steiner Date: Thu, 30 Jul 2015 20:28:10 +0200 Subject: [PATCH] spinner: use a 60fps spinner - sync with gtk+ and provide a fluid spinner https://bugzilla.gnome.org/show_bug.cgi?id=753064 --- data/theme/gnome-shell-sass | 2 +- data/theme/process-working.svg | 2421 +++++++++++++++++++++++++++++++- js/gdm/authPrompt.js | 2 +- js/ui/animation.js | 2 +- js/ui/modalDialog.js | 2 +- js/ui/panel.js | 2 +- js/ui/status/network.js | 2 +- 7 files changed, 2353 insertions(+), 80 deletions(-) diff --git a/data/theme/gnome-shell-sass b/data/theme/gnome-shell-sass index 23e0bc1e7..e0e74382f 160000 --- a/data/theme/gnome-shell-sass +++ b/data/theme/gnome-shell-sass @@ -1 +1 @@ -Subproject commit 23e0bc1e71d0cd84d580916638ec5755f2f2d4e1 +Subproject commit e0e74382f166e596f1c8af4765404bfb65db76a2 diff --git a/data/theme/process-working.svg b/data/theme/process-working.svg index 43ffccad3..920a67d2d 100644 --- a/data/theme/process-working.svg +++ b/data/theme/process-working.svg @@ -12,9 +12,9 @@ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" id="svg5369" version="1.1" - inkscape:version="0.48.5 r10040" - width="96" - height="48" + inkscape:version="0.91 r13725" + width="512" + height="32" sodipodi:docname="process-working.svg" style="display:inline"> image/svg+xml - + @@ -596,7 +596,7 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + snapvisiblegridlinesonly="true" + empcolor="#0000ff" + empopacity="0.47843137" /> diff --git a/js/gdm/authPrompt.js b/js/gdm/authPrompt.js index b57b00bb7..2b79701fc 100644 --- a/js/gdm/authPrompt.js +++ b/js/gdm/authPrompt.js @@ -14,7 +14,7 @@ const ShellEntry = imports.ui.shellEntry; const Tweener = imports.ui.tweener; const UserWidget = imports.ui.userWidget; -const DEFAULT_BUTTON_WELL_ICON_SIZE = 24; +const DEFAULT_BUTTON_WELL_ICON_SIZE = 16; const DEFAULT_BUTTON_WELL_ANIMATION_DELAY = 1.0; const DEFAULT_BUTTON_WELL_ANIMATION_TIME = 0.3; diff --git a/js/ui/animation.js b/js/ui/animation.js index 736b3d72d..08f8f7e15 100644 --- a/js/ui/animation.js +++ b/js/ui/animation.js @@ -7,7 +7,7 @@ const St = imports.gi.St; const Signals = imports.signals; const Atk = imports.gi.Atk; -const ANIMATED_ICON_UPDATE_TIMEOUT = 100; +const ANIMATED_ICON_UPDATE_TIMEOUT = 14; const Animation = new Lang.Class({ Name: 'Animation', diff --git a/js/ui/modalDialog.js b/js/ui/modalDialog.js index d36bc9182..4d461e607 100644 --- a/js/ui/modalDialog.js +++ b/js/ui/modalDialog.js @@ -23,7 +23,7 @@ const Tweener = imports.ui.tweener; const OPEN_AND_CLOSE_TIME = 0.1; const FADE_OUT_DIALOG_TIME = 1.0; -const WORK_SPINNER_ICON_SIZE = 24; +const WORK_SPINNER_ICON_SIZE = 16; const WORK_SPINNER_ANIMATION_DELAY = 1.0; const WORK_SPINNER_ANIMATION_TIME = 0.3; diff --git a/js/ui/panel.js b/js/ui/panel.js index ec85fc651..5b9d308b2 100644 --- a/js/ui/panel.js +++ b/js/ui/panel.js @@ -30,7 +30,7 @@ const APP_MENU_ICON_MARGIN = 0; const BUTTON_DND_ACTIVATION_TIMEOUT = 250; -const SPINNER_ANIMATION_TIME = 0.2; +const SPINNER_ANIMATION_TIME = 1.0; // To make sure the panel corners blend nicely with the panel, // we draw background and borders the same way, e.g. drawing diff --git a/js/ui/status/network.js b/js/ui/status/network.js index 35b459b32..af5582721 100644 --- a/js/ui/status/network.js +++ b/js/ui/status/network.js @@ -877,7 +877,7 @@ const NMWirelessDialog = new Lang.Class({ y_align: Clutter.ActorAlign.CENTER }); let file = Gio.File.new_for_uri('resource:///org/gnome/shell/theme/process-working.svg'); - this._noNetworksSpinner = new Animation.AnimatedIcon(file, 24, 24); + this._noNetworksSpinner = new Animation.AnimatedIcon(file, 16, 16); this._noNetworksBox.add_actor(this._noNetworksSpinner.actor); this._noNetworksBox.add_actor(new St.Label({ style_class: 'no-networks-label', text: _("No Networks") }));