dash: Move labels beside the app icon upon hovering
Instead of using an St.Tooltip to show the app's name under the icon, manually position a new St.Label ourselves. Make sure to keep the label hidden when right-clicking so it doesn't get in the way of the popup menu. Only one tooltip/label will be displayed at a time. https://bugzilla.gnome.org/show_bug.cgi?id=666166
This commit is contained in:

committed by
Florian Müllner

parent
7b9c9b2f7d
commit
2b9561fcbb
@ -470,6 +470,7 @@ const AppWellIcon = new Lang.Class({
|
||||
Lang.bind(this,
|
||||
this._onStateChanged));
|
||||
this._onStateChanged();
|
||||
this.isMenuUp = false;
|
||||
},
|
||||
|
||||
_onDestroy: function() {
|
||||
@ -551,8 +552,8 @@ const AppWellIcon = new Lang.Class({
|
||||
this._menuManager.addMenu(this._menu);
|
||||
}
|
||||
|
||||
this.isMenuUp = true;
|
||||
this.actor.set_hover(true);
|
||||
this.actor.show_tooltip();
|
||||
this._menu.popup();
|
||||
|
||||
return false;
|
||||
@ -568,6 +569,7 @@ const AppWellIcon = new Lang.Class({
|
||||
|
||||
_onMenuPoppedDown: function() {
|
||||
this.actor.sync_hover();
|
||||
this.isMenuUp = false;
|
||||
},
|
||||
|
||||
_onActivate: function (event) {
|
||||
|
Reference in New Issue
Block a user