Bug 334622

Summary: MPRIS plasmoid appears many times.
Product: [Plasma] plasmashell Reporter: Alex Fiestas <afiestas>
Component: System TrayAssignee: Sebastian Kügler <sebas>
Status: RESOLVED FIXED    
Severity: normal CC: me, mklapetek, notmart
Priority: NOR    
Version: master   
Target Milestone: 1.0   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed In:

Description Alex Fiestas 2014-05-11 21:20:08 UTC
http://wstaw.org/m/2014/05/11/decorator1.png

Reproducible: Always
Comment 1 Marco Martin 2014-05-12 09:23:34 UTC
how to reproduce? i have only one
Comment 2 Vishesh Handa 2014-05-12 13:58:48 UTC
I can reproduce this reliably with VLC media player. Launch VLC for some file, quickly close it and launch it again. Each time you do this you will get another MPRIS plasmoid.
Comment 3 Martin Klapetek 2014-05-13 11:25:17 UTC
Do you have "one instance only" enabled in vlc? Their mpris support is quite...unusual.
Comment 4 Marco Martin 2014-05-13 12:21:19 UTC
Git commit 58490813dc775fc78934b6948a7f5a12efd2d3f6 by Marco Martin.
Committed on 13/05/2014 at 12:19.
Pushed by mart into branch 'master'.

slightly defer plasmoid init

since when the plasmoid is gettng created other events may be processed,
slightly defer it's init() so that if a malformed mpris implementation
(hello VLC) adds the plasmoid to tasks immediately, so we can ensure
that every plasmoid gets onle and only one instance

M  +1    -1    applets/systemtray/plugin/protocols/plasmoid/plasmoidtask.cpp

http://commits.kde.org/plasma-workspace/58490813dc775fc78934b6948a7f5a12efd2d3f6
Comment 5 Marco Martin 2014-05-13 12:22:10 UTC
it was reproducible with vlc.
now it should try harder to check if there are no duplicates in the systray