mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-02-23 08:06:11 +00:00
LibGUI: Remove confusing GModelNotification concept
This was a bad idea and it didn't stick. Instead we should just use the simple "on_foo" hook functions like we do for everything else. :^)
This commit is contained in:
@@ -28,17 +28,10 @@ void GAbstractView::set_model(RefPtr<GModel>&& model)
|
||||
did_update_model();
|
||||
}
|
||||
|
||||
void GAbstractView::model_notification(const GModelNotification& notification)
|
||||
{
|
||||
if (on_model_notification)
|
||||
on_model_notification(notification);
|
||||
}
|
||||
|
||||
void GAbstractView::did_update_model()
|
||||
{
|
||||
if (!model() || model()->selected_index() != m_edit_index)
|
||||
stop_editing();
|
||||
model_notification(GModelNotification(GModelNotification::ModelUpdated));
|
||||
}
|
||||
|
||||
void GAbstractView::did_update_selection()
|
||||
|
||||
Reference in New Issue
Block a user