Repository navigation
Fix inconsistent Operations buttons and check actions that affect drivers hidden by search - #494
Conversation
Refresh, Add and Delete have used FlatStyle.System since v0.5, but buttons added later (Select Old, Select Unused, Export and Export All) kept the default WinForms style. The two styles react differently when the mouse hovers over them, so the panel looked inconsistent. Give the newer buttons FlatStyle.System too, and add a test that checks every Operations button.
With a search active, ObjectListView's CheckedObjects only returns the rows that are shown, while CheckAll and the CheckedObjects setter change every driver. That made several actions affect drivers the user could not see: - Select All checked drivers hidden by the search. Delete and the status bar only counted the shown ones, and the hidden drivers reappeared checked once the search was cleared. - Invert Selection checked every hidden driver instead of inverting it. - Select from the context menu silently unchecked hidden drivers. - Select Old and Select Unused checked matches hidden by the search. Select All, Invert Selection and Select now only change the shown rows, so hidden drivers keep their check state. Select Old and Select Unused look at the whole store, so they clear the search first and everything they check is visible. Cancelling the unused-driver warning keeps the search.
There was a problem hiding this comment.
🟡 Changes recommended
A pending search query is not cleared when a store-wide selection action runs before the debounce completes, allowing the timer to hide newly checked drivers; the guard needs correction and a regression test.
1 open issue
1 file not reviewed
Rapr/DSEForm.Designer.cs: Generated file
What changed in this PR
This PR makes the Operations buttons visually consistent and updates driver check actions to respect search visibility.
Changes:
- Applies the native Windows button style to all Operations buttons.
- Limits ordinary check actions to visible drivers and clears applied searches before store-wide selection.
- Adds regression tests for button styling, filtered selection, and warning cancellation.
| File | Description |
|---|---|
| RaprTests/DSEFormTests.cs | Adds tests for button styles and search-aware selection behavior. |
| Rapr/DSEForm.Designer.cs | Sets four Operations buttons to FlatStyle.System. |
| Rapr/DSEForm.cs | Updates check actions and adds search clearing for store-wide selection. |
Review effort: Balanced
The search box applies its filter through a 300 ms debounce timer. If Select Old ran, or Select Unused ran with its warning turned off, right after typing, the filter was still null, so the search was not cleared and the timer stayed running. Its tick then applied the search and hid drivers that the selection had just checked. Check the search text as well as the filter, and stop the timer in both cases. Add a regression test that runs both actions before the filter is applied.
|
Good catch, confirmed. With text typed less than 300 ms earlier, |
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues are reported for the Operations button styling and search-aware selection changes.
No open issues 🎉
1 resolved since last review
1 file not reviewed
Rapr/DSEForm.Designer.cs: Generated file
Review effort: Balanced

Summary
Two fixes, one commit each.
1. Consistent hover effect in the Operations panel
Refresh, Add and Delete have used
FlatStyle.Systemsince v0.5, but the buttons addedlater (Select Old, Select Unused, Export, Export All) kept the default WinForms style.
The two styles react differently when the mouse is over them, so the panel looked
inconsistent. All Operations buttons now use
FlatStyle.System, the native Windowsbutton. This is a one-line property change per button, in the same form the designer
generates.
Before:
2026-11-01.12-52-31.mp4
After:
2026-11-01.12-53-11.mp4
2. Check actions no longer change drivers hidden by the search
While a search is active, ObjectListView's
CheckedObjectsreturns only the rows thatare shown, but
CheckAll()and theCheckedObjectssetter change every driver. As aresult:
Now:
keep their check state.
first and everything they check is visible. Cancelling the unused-driver warning keeps
the search.
Before:
2026-11-01.12-57-23.mp4
After:
2026-11-01.12-57-54.mp4
Tests
5 new tests in
DSEFormTests:OperationButtonsShareTheNativeButtonStylebuilds the designer controls and checksevery Operations button.
CheckActionsLeaveDriversHiddenBySearchUnchangedcovers Select All, Invert and Selectwith a search active.
StoreWideSelectionClearsTheSearchFirstcovers Select Old and Select Unused.CancelledUnusedDriverSelectionKeepsTheSearch.