aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ui/qt/main_window_slots.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/ui/qt/main_window_slots.cpp b/ui/qt/main_window_slots.cpp
index b78c1ddc0d..a41aa2dbde 100644
--- a/ui/qt/main_window_slots.cpp
+++ b/ui/qt/main_window_slots.cpp
@@ -1025,16 +1025,17 @@ void MainWindow::filterExpressionsChanged()
data.window = this;
data.actions_added = false;
+ // Hiding and showing seems to be the only way to get the layout to
+ // work correctly in some cases. See bug 14121 for details.
+ setUpdatesEnabled(false);
+ filter_expression_toolbar_->hide();
filter_expression_toolbar_->clear();
// XXX Add a context menu for removing and changing buttons.
filter_expression_iterate_expressions(filter_expression_add_action, &data);
- if (data.actions_added) {
- // QToolButton calls updateGeometry+update all over the place.
- // updateGeometry should be sufficient here.
- main_ui_->displayFilterToolBar->updateGeometry();
- }
+ filter_expression_toolbar_->show();
+ setUpdatesEnabled(true);
}
//