Bug 488364 - RDP connection produces two system tray icons, but only the first one works
Summary: RDP connection produces two system tray icons, but only the first one works
Status: RESOLVED FIXED
Alias: None
Product: xdg-desktop-portal-kde
Classification: Plasma
Component: general (other bugs)
Version First Reported In: git-master
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords: usability
Depends on:
Blocks:
 
Reported: 2024-06-11 15:44 UTC by Nate Graham
Modified: 2024-06-13 14:34 UTC (History)
5 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In: 6.1.0
Sentry Crash Report:


Attachments
Too many tray icons! (108.12 KB, image/png)
2024-06-11 17:09 UTC, Nate Graham
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nate Graham 2024-06-11 15:44:06 UTC
Setup is:
- Server: Linux Laptop running git master everything and a KRDP server
- Client: Windows 10 PC running the Remote Desktop Connection app

STEPS TO REPRODUCE
1. Restart the desktop portal for good measure with `killall xdg-desktop-portal ; /usr/libexec/xdg-desktop-portal & systemctl restart --user plasma-xdg-desktop-portal-kde.service
1. Turn on RDP server via the Remote Desktop KCM
2. Open Remote Desktop Connection on the other machine
3. Enter the IP address of the server and click "Connect"
4. Click the "Share" button to allow the connection

At this point, a system tray item appears to notify you about the connection. This is expected.

5. Enter credentials in the client and click OK/connect

At this point, a second identical system tray item appears!

The second tray item appears to be pointless; if I right-click on it and choose "End", nothing happens. This only works if I do it on the first tray item.
Comment 1 Nate Graham 2024-06-11 17:09:08 UTC
Created attachment 170380 [details]
Too many tray icons!
Comment 2 Bug Janitor Service 2024-06-12 11:22:24 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/krdp/-/merge_requests/36
Comment 3 Arjen Hiemstra 2024-06-13 09:42:59 UTC
Git commit 090d741331b84462530b9d307d31a482cfd68973 by Arjen Hiemstra.
Committed on 12/06/2024 at 11:12.
Pushed by ahiemstra into branch 'master'.

server: Properly cleanup SessionWrapper objects

Since we're storing the connection as a QPointer comparing the destroyed
connection to the stored connection doesn't work since the QPointer is
already cleared at the point the connection has been destroyed. We don't
really want to track the connection anyway, we want to track the
wrapper. So make the wrapper emit a signal on connection loss that we
use to cleanup the wrapper.
Related: bug 488367

M  +15   -14   server/SessionController.cpp
M  +0    -1    server/SessionController.h

https://invent.kde.org/plasma/krdp/-/commit/090d741331b84462530b9d307d31a482cfd68973
Comment 4 Arjen Hiemstra 2024-06-13 09:46:46 UTC
Git commit 058e2bde9167103adbeb95303fd01cfa240e107e by Arjen Hiemstra.
Committed on 13/06/2024 at 09:44.
Pushed by ahiemstra into branch 'Plasma/6.1'.

server: Properly cleanup SessionWrapper objects

Since we're storing the connection as a QPointer comparing the destroyed
connection to the stored connection doesn't work since the QPointer is
already cleared at the point the connection has been destroyed. We don't
really want to track the connection anyway, we want to track the
wrapper. So make the wrapper emit a signal on connection loss that we
use to cleanup the wrapper.
Related: bug 488367
(cherry picked from commit 090d741331b84462530b9d307d31a482cfd68973)

M  +15   -14   server/SessionController.cpp
M  +0    -1    server/SessionController.h

https://invent.kde.org/plasma/krdp/-/commit/058e2bde9167103adbeb95303fd01cfa240e107e