Bug 427790 - Lack of exit button
Summary: Lack of exit button
Status: RESOLVED DUPLICATE of bug 423497
Alias: None
Product: kdeconnect
Classification: Applications
Component: android-application (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Albert Vaca Cintora
URL:
Keywords:
: 414754 428030 (view as bug list)
Depends on:
Blocks:
 
Reported: 2020-10-16 07:22 UTC by Avamander
Modified: 2022-10-05 06:54 UTC (History)
6 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Avamander 2020-10-16 07:22:34 UTC
SUMMARY
The app doesn't have a button to kill itself and all its services

STEPS TO REPRODUCE
1. Open it
2. Only way to permanently close and get rid of the notification is to force close it

OBSERVED RESULT
There's no exit button

EXPECTED RESULT
There's an exit button

SOFTWARE/OS VERSIONS
Android: 10
Comment 1 Nate Graham 2020-10-16 14:11:41 UTC
What do you mean "force close it"? Quitting it the normal way doesn't work?
Comment 2 Avamander 2020-10-16 15:06:30 UTC
It keeps the notification when just swiped away from recents.
Comment 3 Bug Janitor Service 2020-10-31 04:33:37 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 4 Christoph Feck 2020-11-05 03:11:32 UTC
Requested information was added with comment 2; changing status for inspection.
Comment 5 Nicolas Fella 2020-11-11 20:24:57 UTC
*** Bug 428030 has been marked as a duplicate of this bug. ***
Comment 6 Daniel Tang 2021-02-06 13:20:08 UTC
This is a bad idea because it would complicate and confuse both the user and developers.

Android apps should not have an explicit exit button: https://stackoverflow.com/a/6014098/10477326 . This is according to general Android UI principles. See other apps like Google Fit and AccuBattery. The force close button would indeed play the role of the exit button if you really need to close the app. There should be exactly one easy and obvious way for users to do things, and this is it. Additionally, on mobile devices, applications should be able to close themselves, but rather follow the operating system's patterns (such as dismissal from recents or force stop) for doing that
Comment 7 Daniel Tang 2021-02-06 13:23:38 UTC
*** Bug 414754 has been marked as a duplicate of this bug. ***
Comment 8 Avamander 2021-02-06 13:58:25 UTC
That sentence would be correct if KDE Connect didn't have a service. Simply swiping away from Recents shouldn't kill the service, but an explicit exit should.
Comment 9 Daniel Tang 2021-02-06 16:46:53 UTC
> didn't have a service

That sentence explicitly mentions apps with services.

> See other apps like Google Fit and AccuBattery
Comment 10 Avamander 2021-02-06 16:47:49 UTC
Yeah, it mentions and it's wrong in those cases...
Comment 11 Daniel Tang 2021-02-06 17:00:53 UTC
I can see several ways to get this implemented though.

The most direct way, adding an exit action on the notification, isn't a good idea. There is a limit to the number of actions that Android will allow before ignoring the rest.

As an aside, I thinking about a debug screen. In that screen (I'm thinking of something like Facebook's internal settings), there could be menu items like "force crash" or "jvm exit". Although that would be some kind of button, I don't think it would be any more convenient than the force quit button so this won't be the main solution.

To design a more comprehensive solution, I though of Termius, whose notifications are only active when there is an active connection. This also reminds me of KDE's WiFi settings. In those settings, there is a "connect automatically with priority" thing, similar to other OS's connect automatically checkbox. Unlike Termius, KDE Connect also receives incoming connections, so a separate toggle would be necessary for that. It is fortunate that plans already exist in the code, with this named as "discovery mode". So basically this solution would involve 3 changes:

- Implement discovery mode (option to reject unknown devices when pairing is not open)
- Add a "connect automatically" toggle for each device. When it's unchecked, disconnect if connected, and reject further connection attempt
- Dismiss the notification and stop the background service if discovery mode is disabled and "connect automatically" is disabled for all devices. This could be considered an optimization that naturally follows from the fact that we will never have connections to any device if both the previous two options are disabled

What do you think of this?
Comment 12 Avamander 2021-02-08 11:48:34 UTC
More fine-grained discovery settings would be nice. But in my case, I just want to close the app and the service irrelevant to the usual configuration or usage.
Comment 13 Daniel Tang 2021-02-08 12:36:21 UTC
> I just want to close the app

How about a further "Disconnect from all devices" button on the settings screen that does the 3 things, causing the app and service to exit?
Comment 14 Mathieu 2021-03-03 00:50:50 UTC
I would really like this feature. I would suggest to do it the way Syncthing does it, with an "Exit" option on the slider. This can be seen on the screenshot displayed https://play.google.com/store/apps/details?id=com.nutomic.syncthingandroid

This terminates the service, the app can then be "swiped away".
Comment 15 Frank Steinmetzger 2022-01-10 10:44:47 UTC
(In reply to Daniel Tang from comment #13)
> > I just want to close the app

I have the same problem as the OP. I use kdeconnect very sporadically, usually to transfer one or a few files, nothing more (although I appreciate all the other possibilities it provides). But because of the notification issue, I usually go to Total Commander instead and do it The Old Way via sftp, even though that requires me to input a password. It’s just too much hassle to afterwards go into settings, wait for the app list to load, scroll dooooown, find the app and kill it. I, too, like the way Syncthing implemented it with its “Exit” menu item. In contrast, its “competitor” Nextcloud Sync Client has the same issue as kdeconnect: there is no exit function and it has a permanent notification. Which is why I usually avoid it, because usually I just need one file from my nextcoud—not a permanent sync.

> How about a further "Disconnect from all devices" button on the settings
> screen that does the 3 things, causing the app and service to exit?

That doesn’t sound so bad. But did you mean the screen behind the cogwheel, or the menu that can be slided in from the left? I think a “Disconnect all” would suffice and as soon as there is no active connection, the notification can go away. Of course this would mean it no longer listens to incoming connection requests. Hm... I understand your desire to not make it too complicated for non-techie users, so a toggle “Listen for incoming connections” is maybe too overengineered. I’m afraid I’m a bit old-school for the modern Android-approach on UI things. :)

Please don’t get me wrong. I think a service that auto-discovers and -connects is a reasonable and useful feature. But only if you want it. If not, then it’s in your way. Another aspect to consider for an always-running service: it consumes power for CPU and network, possibly needlessly. Also, when I am in a different network, I might not want to broadcast search requests for other kdeconnect instances as soon as I load the app.

I just had a look at kdeconnect on my phone and connected it to my KDE machine. And I currently cannot see any disconnect option there, neither on the Android end nor on the KDE desktop. The only “option” I had was to shut down the WiFi on a participant. But this left the app UI in a strange state. I might write another ticket about that.
Comment 16 2wxsy58236r3 2022-10-05 06:54:34 UTC

*** This bug has been marked as a duplicate of bug 423497 ***