forked from qt-creator/qt-creator
ADS: Do not re-use variables
Change-Id: I2aee3d6684d40077acfe652638292901bd660ea6 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
committed by
Tim Jenssen
parent
45d42d4518
commit
b329b7220b
@@ -336,9 +336,9 @@ namespace ADS
|
||||
|
||||
void DockWidget::toggleViewInternal(bool open)
|
||||
{
|
||||
DockContainerWidget *dockContainerWidget = dockContainer();
|
||||
DockWidget *topLevelDockWidgetBefore = dockContainerWidget
|
||||
? dockContainerWidget->topLevelDockWidget()
|
||||
const DockContainerWidget *const beforeDockContainerWidget = dockContainer();
|
||||
DockWidget *topLevelDockWidgetBefore = beforeDockContainerWidget
|
||||
? beforeDockContainerWidget->topLevelDockWidget()
|
||||
: nullptr;
|
||||
|
||||
if (open) {
|
||||
@@ -359,7 +359,7 @@ namespace ADS
|
||||
// Here we need to call the dockContainer() function again, because if
|
||||
// this dock widget was unassigned before the call to showDockWidget() then
|
||||
// it has a dock container now
|
||||
dockContainerWidget = dockContainer();
|
||||
const DockContainerWidget *const dockContainerWidget = dockContainer();
|
||||
DockWidget *topLevelDockWidgetAfter = dockContainerWidget
|
||||
? dockContainerWidget->topLevelDockWidget()
|
||||
: nullptr;
|
||||
|
Reference in New Issue
Block a user