Solid-device-automounter/kcm: show disconnected known device when disconnecting it
ClosedPublic

Authored by meven on Jan 30 2020, 10:44 AM.

Details

Summary

A user might find odd that when a known device in the UI is unmounted, it disappears.
Despite the fact that restarting the kcm would show it.

Test Plan

Open kcmshell5 device_automounter_kcm
Plug in a usb stick, set a setting for it and Apply
Unplug the stick

Before:
The disconnected usb stick does not appear
After:
The usb stick appears at the bottom of the disconnected section

Forget the stick in the UI and Apply
Plug in the usb stick
Unplug it

The usb stick is not visible (as before)

Diff Detail

Repository
R119 Plasma Desktop
Branch
arcpatch-D27024
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 23524
Build 23542: arc lint + arc unit
meven created this revision.Jan 30 2020, 10:44 AM
Restricted Application added a project: Plasma. · View Herald TranscriptJan 30 2020, 10:44 AM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
meven requested review of this revision.Jan 30 2020, 10:44 AM
meven added a reviewer: ervin.Feb 3 2020, 12:57 PM
ervin requested changes to this revision.Feb 12 2020, 1:23 PM
ervin added inline comments.
solid-device-automounter/kcm/DeviceModel.cpp
104

I think we need a further update of the comment, indeed it starts with "the device is not moved to"... but clearly not it is. I'd probably revert it with something like "We move the device for the disconnected section only if..." with then further explanations (some of the points mentioned can be kept). In its current form it's just more confusing

105

Missing space before {

This revision now requires changes to proceed.Feb 12 2020, 1:23 PM
meven updated this revision to Diff 75847.Feb 17 2020, 4:55 PM
meven marked 2 inline comments as done.

Add a missing space, improve comment as suggested

bport accepted this revision.Feb 20 2020, 8:43 AM
ervin accepted this revision.Feb 24 2020, 11:09 AM

I guess extra care will need to be taken with your other patch moving away from the singleton (dunno which one is based on which, I might review out of order).

This revision is now accepted and ready to land.Feb 24 2020, 11:09 AM
meven updated this revision to Diff 77361.Mar 10 2020, 4:08 PM

Rebase on master, and follow removal of singleton

meven updated this revision to Diff 77365.Mar 10 2020, 4:31 PM

Add the recently disconnected device at the end of the list of devices

meven updated this revision to Diff 77366.Mar 10 2020, 4:33 PM

Solid-device-automounter/kcm: correctly update automountOn

meven updated this revision to Diff 77367.Mar 10 2020, 4:34 PM

Remove bad commit

bport accepted this revision.Mar 10 2020, 4:42 PM
This revision was automatically updated to reflect the committed changes.