Google Chrome Flatpak tray icon issues in KDE

After installing Google Chrome from Bazaar, the tray icon for google chrome duplicates itself, with the original tray icon being able to spawn new chrome windows, but the active window not allowing for spawning of said windows. This slightly messes up my workflow in browser and doesn't appear to effect Firefox or Brave Flatpaks. I haven't tested Gnome, so I don't know if this is a bigger issue or not. Output of journalctl while opening Chrome is attached.
Solution:
I have found a fix. First, copy the .desktop file to your local applications folder. /var/lib/flatpak/app/com.google.Chrome/current/active/export/share/applications/com.google.Chrome.desktop ~/.local/share/applications/ Then edit the .desktop file in your favorite editor...
Jump to solution
35 Replies
nagito || Knight of Emilia
did you try closing/re opening or loggingin/out this seems simple
chaosmaou
chaosmaouOP2mo ago
Yes, issue still occurs even after a reboot or restart of chrome
nagito || Knight of Emilia
lemme get it & see
chaosmaou
chaosmaouOP2mo ago
If you clean install google chrome, the first time it runs it works correctly. Close it and reopen it to see the spawned tray icons. Not sure if its a permission issue or just a side effect of the chrome flatpak
nagito || Knight of Emilia
hmm i installed the flatpak & it does work seemingly always but i did notice something
chaosmaou
chaosmaouOP2mo ago
Hmm. This is on a clean install of Bazzite, strange? Maybe it is something to do with mesa? I am on an AMD gpu
nagito || Knight of Emilia
the icons do double up for a sec but one disappears after a bit
chaosmaou
chaosmaouOP2mo ago
I also signed in to my account, so maybe that also effects it.
nagito || Knight of Emilia
& the other does toggle the window i say toggle because minimize/unminimize is long to type
chaosmaou
chaosmaouOP2mo ago
Yeah its a very minor bug
nagito || Knight of Emilia
another observation the first icon from the left persumably the first thing that spawns is the icon that goes away eventually
chaosmaou
chaosmaouOP2mo ago
It does if you don't have it pinned to your tray I just noticed So maybe this is a kde bug with the task manager on the taskbar
nagito || Knight of Emilia
maybe pin the one that represents the Window
chaosmaou
chaosmaouOP2mo ago
That one won't give the option
nagito || Knight of Emilia
hmm strange
chaosmaou
chaosmaouOP2mo ago
No description
nagito || Knight of Emilia
same just tested
chaosmaou
chaosmaouOP2mo ago
the old icon shows new spawn options and pinning/unpinning, even though it doesn't show an active window
No description
nagito || Knight of Emilia
if i open the app launcher & drag the icon from there to pin it it works
chaosmaou
chaosmaouOP2mo ago
I just tried that and as soon as I click on the icon it still has two icons, strange...
nagito || Knight of Emilia
hmm yeah the new icon is the window hmm tried the same thing in brave another chromium based browser flatpak of course & it doesn't have double icons not when started nor when pinned this might just be chrome specific behavior might be trying to emulate the Windows 7 style where as i recall the pin is separate from the running instances behaves the same as it does here one icon opens it the other contains all the windows
chaosmaou
chaosmaouOP2mo ago
Strange thing is in arch/cachyos, installing chrome natively doesn't have this issue
nagito || Knight of Emilia
was about to ask about/test that
jacobchins
jacobchins2mo ago
Haven't had a chance to read the full thread yet, but wanted to jump in and say that I'm having the same issue. I've had the same issue for the last 3 months or so, on my OneXPlayer G1 running Stable Bazzite KDE. I can't not into desktop anymore but that's another issue in the discord I'm waiting to great about lol
chaosmaou
chaosmaouOP2mo ago
I haven't tried rpm-ostree to install chrome as I don't wanna risk breaking any future updates
nagito || Knight of Emilia
i just tried the Nix OS package which is the offiial deb version re packaged to work on Nix OS & it doesn't do thos weord thomg it works like you'd axpect no idea why flatpak chrome does this
chaosmaou
chaosmaouOP2mo ago
Very weird
nagito || Knight of Emilia
more pointless information tried it on cinnamon x11 & plasma x11 both don't have this problem it's ONLY the flatpak & ONLY on plasma wayland tried cinnamon on wayland but that's experimental so the flatpak crashes the desktop on my system at least the non flatpak package works on cinnamon wayland as well hmm that makes me think
chaosmaou
chaosmaouOP2mo ago
Looks like this is related to this issue: https://github.com/flathub/com.google.Chrome/issues/83
GitHub
com.google.Chrome.desktop - StartupWMClass · Issue #83 · flathub/...
Hi Is it possible to add "StartupWMClass=Google-chrome" to com.google.Chrome.desktop? Or is it left out for a good reason? I have a problem with duplicate icons on my dock if I don't ...
Solution
chaosmaou
chaosmaou2mo ago
I have found a fix. First, copy the .desktop file to your local applications folder. /var/lib/flatpak/app/com.google.Chrome/current/active/export/share/applications/com.google.Chrome.desktop ~/.local/share/applications/ Then edit the .desktop file in your favorite editor /var/home/chaosmaou/.local/share/applications/com.google.Chrome.desktop Add StartupWMClass=google-chrome underneath Name=Google Chrome under the [Desktop Entry] at the top of the file. You must also then update both Exec= lines for both normal and incognitio modes, adding --class=com.google.Chrome before com.google.Chrome near the end of both lines: Exec=/usr/bin/flatpak run --branch=stable --arch=x86_64 --command=/app/bin/chrome --class=com.google.Chrome com.google.Chrome Exec=/usr/bin/flatpak run --branch=stable --arch=x86_64 --command=/app/bin/chrome --class=com.google.Chrome com.google.Chrome --incognito Then save the file.
chaosmaou
chaosmaouOP2mo ago
Then make sure to unzip and repin chrome to the taskbar. I also did a full logout and login, which may not be required. Tray icon behaves normally now. I also just reported this to that open bug report that has been dead since 2023.
nagito || Knight of Emilia
nice though i got up today & started it only to notice it somehow fixed itself
chaosmaou
chaosmaouOP2mo ago
Even more strange
AuraFlarei
AuraFlarei2mo ago
I love when things break but when you come back later it just works again for some reason
chaosmaou
chaosmaouOP2mo ago
Yeah that is weird. The .desktop fixed worked for me though, so strange

Did you find this page helpful?