Skip to content

Commit

Permalink
fix spurious selection when reloading the browser on macOS
Browse files Browse the repository at this point in the history
  • Loading branch information
cfillion committed Feb 14, 2024
1 parent ffd9b2e commit 7134045
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/listview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -315,6 +315,11 @@ void ListView::endEdit()
void ListView::clear()
{
ListView_DeleteAllItems(handle());
#ifdef __APPLE__
// NSTableView preverves the previous selection when removing rows after
// beginUpdates is called (via WM_SETREDRAW=0 in SWELL)
unselectAll();
#endif

m_rows.clear();
}
Expand Down

0 comments on commit 7134045

Please sign in to comment.