Skip to content

Commit

Permalink
Update DockAreaTabBar.cpp (#640)
Browse files Browse the repository at this point in the history
This fix seems to have introduced a regression when _this is deleted before the lambda slot occurred, for example deleting the DockManager (and consequently _this) immediately after the execution of updateTabs function (we encountered this problem in linux)
  • Loading branch information
invisibleGG authored Jun 3, 2024
1 parent 3ff6918 commit 06e8451
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/DockAreaTabBar.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ void DockAreaTabBarPrivate::updateTabs()
// Sometimes the synchronous calculation of the rectangular area fails
// Therefore we use QTimer::singleShot here to execute the call
// within the event loop - see #520
QTimer::singleShot(0, TabWidget, [&, TabWidget]
QTimer::singleShot(0, _this, [&, TabWidget]
{
_this->ensureWidgetVisible(TabWidget);
});
Expand Down

0 comments on commit 06e8451

Please sign in to comment.