Enable (de)selecting all apps in notification filter
ClosedPublic

Authored by nicolasfella on Apr 17 2018, 1:20 PM.

Details

Summary

BUG: 393190

Add checkbox to (de)select all

Old proposal:

Test Plan

Deselect all, verify that no notification is coming from test app.
Select all, ...
Deselect all, select single app, ...

Diff Detail

Repository
R225 KDE Connect - Android application
Branch
selectall
Lint
No Linters Available
Unit
No Unit Test Coverage
nicolasfella created this revision.Apr 17 2018, 1:20 PM
Restricted Application added a project: KDE Connect. · View Herald TranscriptApr 17 2018, 1:20 PM
nicolasfella requested review of this revision.Apr 17 2018, 1:20 PM
nicolasfella edited the summary of this revision. (Show Details)Apr 17 2018, 1:23 PM
mtijink added inline comments.
src/org/kde/kdeconnect/Plugins/NotificationsPlugin/NotificationFilterActivity.java
217

Why in a thread? The previous code didn't do that.

nicolasfella added inline comments.Apr 17 2018, 4:49 PM
src/org/kde/kdeconnect/Plugins/NotificationsPlugin/NotificationFilterActivity.java
217

The database operation is quite expensive. Previously only one item at a time was updated so it was only very short. Now all items are updated at once resulting in a noticeable lag when done in the UI thread

Thanks a lot!

However, is there something "more elegant" like a header with a checkbox, like the ones found in a TreeView where the header checkbox will select and unselect all? (Just asking, I think the buttons are fine)

  • Use header checkbox
  • Code format
mtijink added inline comments.Apr 21 2018, 6:00 PM
src/org/kde/kdeconnect/Plugins/NotificationsPlugin/NotificationFilterActivity.java
217

Can't we do something like UPDATE checked = false (like in SQL)? So only one query for all checks at once.

  • Merge branch 'master' into selectall
  • Use raw SQL
apol added a subscriber: apol.Jul 26 2018, 5:48 PM

Wouldn't it make more sense to have a button that allows to blacklist applications? It will be hard to see what's going on here.

Restricted Application added a subscriber: kdeconnect. · View Herald TranscriptJul 26 2018, 5:48 PM
nicolasfella edited the summary of this revision. (Show Details)Sep 27 2018, 6:33 PM
In D12281#298654, @apol wrote:

Wouldn't it make more sense to have a button that allows to blacklist applications? It will be hard to see what's going on here.

I don't think having both a black- and a whilelist would improve things. Maybe VDG has an opinion on it

nicolasfella edited the summary of this revision. (Show Details)Sep 27 2018, 6:50 PM
apol added a comment.Sep 28 2018, 1:17 AM
In D12281#298654, @apol wrote:

Wouldn't it make more sense to have a button that allows to blacklist applications? It will be hard to see what's going on here.

I don't think having both a black- and a whilelist would improve things. Maybe VDG has an opinion on it

Eh, forget my message.

albertvaka accepted this revision as: KDE Connect.Sep 28 2018, 1:43 PM
albertvaka added a subscriber: albertvaka.

Where do you set the initial state of the "all" checkbox? I wanted to suggest that you add the case where some are selected an some are not, and set it to "indeterminate" in that case, but I couldn't find the code for the initial state.

Where do you set the initial state of the "all" checkbox? I wanted to suggest that you add the case where some are selected an some are not, and set it to "indeterminate" in that case, but I couldn't find the code for the initial state.

I don't know :D Maybe I'll revisit later

This revision was not accepted when it landed; it landed in state Needs Review.Sep 30 2018, 5:34 PM
This revision was automatically updated to reflect the committed changes.