ikalnytskyi / gnome-shell-extension-icon-hider

Icon Hider is a gnome-shell extension for managing status area items.
Other
31 stars 11 forks source link

Respect auto hidden (context based) icons like "Lock Keys" #27

Open RubenSibon opened 7 years ago

RubenSibon commented 7 years ago

Extensions like Lock Keys and Apt Update Indicator have options to hide automatically when there is nothing relevant to show. This extension does not respect that behavior as it shows these icons regardless and if set to hide they never show up again even if the context arises (i.e. pressing the Caps Lock button for example). Is it possible to fix this? If you do not have the time I'd like to give it a shot myself, but I have no experience with Gnome Shell Extensions...

ikalnytskyi commented 7 years ago

@rubenjs7 thanks for the feedback. It would be really great if you can work on this. FWIW, you need to lookup onto these lines:

https://github.com/ikalnytskyi/gnome-shell-extension-icon-hider/blob/master/icon-hider%40kalnitsky.org/extension.js#L194-L197

We assume here that restoring icon means to make it visible, since we don't know an actual status of the icon. My suggestion is to somehow track the latest propagated icon status here

https://github.com/ikalnytskyi/gnome-shell-extension-icon-hider/blob/master/icon-hider%40kalnitsky.org/extension.js#L234-L236

and use this information when we restoring and make them unconditionally visible.

If I got some free time, I'll take a look.. but I can't promise. You help will be very appreciated.