mirror of
https://github.com/RGBCube/serenity
synced 2025-05-15 22:54:57 +00:00
LibGUI+FileManager: Add GAbstractView::on_selection_change hook
This hook will be called whenever the view's selection changes somehow. Use this in the FileManager to keep the left and right views in sync.
This commit is contained in:
parent
9d97781e37
commit
6dec328af7
3 changed files with 6 additions and 2 deletions
|
@ -100,5 +100,8 @@ void GAbstractView::activate(const GModelIndex& index)
|
|||
|
||||
void GAbstractView::notify_selection_changed(Badge<GModelSelection>)
|
||||
{
|
||||
did_update_selection();
|
||||
if (on_selection_change)
|
||||
on_selection_change();
|
||||
update();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue