mirror of
https://github.com/Hopiu/RandomWallpaperGnome3.git
synced 2026-03-16 22:20:24 +00:00
fix panel icon inheritance
Bug report https://bugzilla.gnome.org/show_bug.cgi\?id\=688973
This commit is contained in:
parent
21496bb788
commit
b89d670eb3
2 changed files with 10 additions and 10 deletions
|
|
@ -230,11 +230,11 @@ var NewWallpaperElement = new Lang.Class({
|
|||
|
||||
var StatusElement = new Lang.Class({
|
||||
Name: 'StatusElement',
|
||||
Extends: St.Icon,
|
||||
|
||||
icon: null,
|
||||
|
||||
_init: function () {
|
||||
|
||||
this.parent({
|
||||
this.icon = new St.Icon({
|
||||
icon_name: 'preferences-desktop-wallpaper-symbolic',
|
||||
style_class: 'system-status-icon'
|
||||
});
|
||||
|
|
@ -243,11 +243,11 @@ var StatusElement = new Lang.Class({
|
|||
|
||||
this.loadingTweenIn = {
|
||||
opacity: 20,
|
||||
time: 1,
|
||||
time: 2,
|
||||
transition: 'easeInOutSine',
|
||||
onComplete: function () {
|
||||
try {
|
||||
Tweener.addTween(_this, _this.loadingTweenOut);
|
||||
Tweener.addTween(_this.icon, _this.loadingTweenOut);
|
||||
} catch (e) {
|
||||
// swollow (not really important)
|
||||
}
|
||||
|
|
@ -261,7 +261,7 @@ var StatusElement = new Lang.Class({
|
|||
onComplete: function () {
|
||||
if (_this.isLoading) {
|
||||
try {
|
||||
Tweener.addTween(_this, _this.loadingTweenIn);
|
||||
Tweener.addTween(_this.icon, _this.loadingTweenIn);
|
||||
} catch (e) {
|
||||
// swollow (not really important)
|
||||
}
|
||||
|
|
@ -276,13 +276,13 @@ var StatusElement = new Lang.Class({
|
|||
|
||||
startLoading: function () {
|
||||
this.isLoading = true;
|
||||
Tweener.addTween(this, this.loadingTweenOut);
|
||||
Tweener.addTween(this.icon, this.loadingTweenOut);
|
||||
},
|
||||
|
||||
stopLoading: function () {
|
||||
this.isLoading = false;
|
||||
Tweener.removeTweens(this);
|
||||
this.opacity = 255;
|
||||
Tweener.removeTweens(this.icon);
|
||||
this.icon.opacity = 255;
|
||||
}
|
||||
|
||||
});
|
||||
|
|
|
|||
|
|
@ -84,7 +84,7 @@ var RandomWallpaperEntry = new Lang.Class({
|
|||
|
||||
// Panelmenu Icon
|
||||
this.statusIcon = new CustomElements.StatusElement();
|
||||
this.actor.add_child(this.statusIcon);
|
||||
this.actor.add_child(this.statusIcon.icon);
|
||||
|
||||
// new wallpaper button
|
||||
this.newWallpaperItem = new CustomElements.NewWallpaperElement();
|
||||
|
|
|
|||
Loading…
Reference in a new issue