pop-os / gnome-shell-extension-pop-suspend-button

GNOME Shell Extension Suspend-Button
GNU General Public License v2.0
2 stars 2 forks source link

Suspend Button in User Menu is a Pause Button #6

Open isantop opened 4 years ago

isantop commented 4 years ago

Distribution (run cat /etc/os-release): Pop!_OS 19.10

Related Application and/or Package Version (run apt policy $PACKAGE NAME): Suspend button in the menu

Issue/Bug Description: The icon on the suspend button is a pause button. This is highly confusing, as it looks like the button will pause playing media, instead it suspends the computer.

We previously changed this icon to a moon (system-suspend-symbolic), but this changed sometime either late in 19.04 or new in 19.10, and it displays the pause button again.

Steps to reproduce (if you know):

  1. Open menu
  2. Observe pause button
  3. Cry because the pause button you clicked to pause media playback turned off your computer.

Expected behavior: Suspend button icon is a moon.

Other Notes: Current screenshot:

Screenshot from 2019-12-16 12-28-22

isantop commented 4 years ago

Not sure in which repo this bug was introduced. Please move to the correct repo if appropriate.

isantop commented 4 years ago

It looks like Shell is requesting media-playback-pause-symbolic. It also looks like the extension is requesting system-suspend-symbolic, so something appears to be happening in the Shell that's overriding the changes here.

Icon requested in the extension: https://github.com/pop-os/gnome-shell-extension-pop-suspend-button/blob/master/extension.js#L135

isantop commented 4 years ago

Here is where the incorrect icon is being set by the Shell:

https://github.com/pop-os/gnome-shell/blob/bf1504b671f6fc4e8cef5dda7362a98f03f7b293/js/misc/systemActions.js#L110

isantop commented 4 years ago

@mmstick I changed the icon in GNOME Shell to system-suspend-symbolic, however, the button is still a pause button. Any ideas why it might not be updated correctly?

https://github.com/pop-os/gnome-shell/blob/suspend-button-icon/js/ui/status/system.js#L271

The only other occurrence of the pause icon is the mpris code, which should in fact be a pause icon