1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 17:37:37 +00:00

LibGUI: Move range selection calculations into separate function

AbstractView currently assumes a certain layout of rows and colums to
perform a range selection on.

This patch moves the implementation into a helper that can be overriden
by other views.
This commit is contained in:
networkException 2022-07-23 23:57:40 +02:00 committed by Linus Groh
parent 7540259b16
commit 30d68d71b4
2 changed files with 19 additions and 13 deletions

View file

@ -156,6 +156,7 @@ protected:
virtual void add_selection(ModelIndex const&);
virtual void remove_selection(ModelIndex const&);
virtual void toggle_selection(ModelIndex const&);
virtual void select_range(ModelIndex const&);
virtual void did_change_hovered_index([[maybe_unused]] ModelIndex const& old_index, [[maybe_unused]] ModelIndex const& new_index) { }
virtual void did_change_cursor_index([[maybe_unused]] ModelIndex const& old_index, [[maybe_unused]] ModelIndex const& new_index) { }
virtual void editing_widget_did_change([[maybe_unused]] ModelIndex const& index) { }