After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 620782 - [dash] Add a fade effect when hovering over items
[dash] Add a fade effect when hovering over items
Status: RESOLVED FIXED
Product: gnome-shell
Classification: Core
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
Depends on:
Blocks:
 
 
Reported: 2010-06-06 22:42 UTC by Florian Müllner
Modified: 2010-06-08 18:49 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
[appWellIcon] Set correct style in constructor (1.10 KB, patch)
2010-06-06 22:42 UTC, Florian Müllner
needs-work Details | Review
[dash] Add a fade effect when hovering over items (1.80 KB, patch)
2010-06-06 22:42 UTC, Florian Müllner
committed Details | Review
[appWellIcon] Set correct style in constructor (2.06 KB, patch)
2010-06-08 17:46 UTC, Florian Müllner
committed Details | Review

Description Florian Müllner 2010-06-06 22:42:02 UTC
See patches. The second patch is a simple CSS modification based on the transitions in bug 619025 - it already comes with the McCann-Seal-of_Approval(tm), so I'd like to commit it after landing transitions.

The first patch works around a problem with transitions being applied erroneously when adding/removing items to/from the well.
Comment 1 Florian Müllner 2010-06-06 22:42:09 UTC
Created attachment 162894 [details] [review]
[appWellIcon] Set correct style in constructor

Currently, only the base style class is set in the constructor, the
style update according to the state of the represented app is deferred
until the actor is shown.
As existing icons are destroyed and recreated when the number of icons
changes, this behavior causes the icons of running apps to flicker if
CSS transitions are used.
Comment 2 Florian Müllner 2010-06-06 22:42:14 UTC
Created attachment 162895 [details] [review]
[dash] Add a fade effect when hovering over items

Use a subtle hover transition in order to avoid abrupt visual
changes.
Comment 3 Owen Taylor 2010-06-08 16:22:30 UTC
Review of attachment 162894 [details] [review]:

If we have to set the state on construction and we have no idea why we are delaying the connection, then we should just eliminate delayed connection and connect to notify::state in the constructor and get rid of _onShow(). The show/hide handling is just slightly anyways - _onHideDestroy needs to set this._stateChangedId to 0.
Comment 4 Owen Taylor 2010-06-08 16:30:07 UTC
Review of attachment 162895 [details] [review]:

Seems to work, makes things look slicker. (Possibly some cleanups could be done to add a common style class for everything that has the identical hover, but this only makes the duplication just a tiny bit worse.)
Comment 5 Florian Müllner 2010-06-08 17:46:04 UTC
Created attachment 163084 [details] [review]
[appWellIcon] Set correct style in constructor

Updated patch - I digged around in logs and I'm pretty sure that the _onShow/_onHide behavior is something I did in response to a comment from Colin. The basic idea is that it would be expensive to do style calculations if StWidget weren't smart enough to defer them anyway while the actor is unmapped. I doubt there is any other reason for that code, so yeah, let's just remove it ...
Comment 6 Owen Taylor 2010-06-08 18:41:36 UTC
Review of attachment 163084 [details] [review]:

Looks good
Comment 7 Florian Müllner 2010-06-08 18:48:52 UTC
Attachment 162895 [details] pushed as 466f661 - [dash] Add a fade effect when hovering over items
Attachment 163084 [details] pushed as dad80b3 - [appWellIcon] Set correct style in constructor