From 9c6f7d3e7d2252ad2d51f2c7c7379cab867fa477 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Tue, 25 Feb 2020 10:47:30 +0100 Subject: LibGUI: Actually store the column in MultiView::set_model_column() We were only forwarding the value to the subviews, but not storing it in m_model_column. This would cause MultiView::model_column() to return the wrong value. Thanks to Daniel Bos for spotting this! :^) --- Libraries/LibGUI/MultiView.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Libraries/LibGUI/MultiView.cpp b/Libraries/LibGUI/MultiView.cpp index 162a6c32c4..87334be9e4 100644 --- a/Libraries/LibGUI/MultiView.cpp +++ b/Libraries/LibGUI/MultiView.cpp @@ -137,6 +137,9 @@ void MultiView::set_model(RefPtr model) void MultiView::set_model_column(int column) { + if (m_model_column == column) + return; + m_model_column = column; m_item_view->set_model_column(column); m_columns_view->set_model_column(column); } -- cgit v1.2.3