Skip to content

Commit 44ff9e9

Browse files
Fixed some compiler warnings on Ubuntu 22.04
1 parent f848df7 commit 44ff9e9

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/DockContainerWidget.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2063,7 +2063,7 @@ CDockAreaWidget* CDockContainerWidget::topLevelDockArea() const
20632063
QList<CDockWidget*> CDockContainerWidget::dockWidgets() const
20642064
{
20652065
QList<CDockWidget*> Result;
2066-
for (const auto DockArea : d->DockAreas)
2066+
for (const auto& DockArea : d->DockAreas)
20672067
{
20682068
if (!DockArea)
20692069
{
@@ -2099,7 +2099,7 @@ void CDockContainerWidget::removeAutoHideWidget(CAutoHideDockContainer* Autohide
20992099
CDockWidget::DockWidgetFeatures CDockContainerWidget::features() const
21002100
{
21012101
CDockWidget::DockWidgetFeatures Features(CDockWidget::AllDockWidgetFeatures);
2102-
for (const auto DockArea : d->DockAreas)
2102+
for (const auto& DockArea : d->DockAreas)
21032103
{
21042104
if (!DockArea)
21052105
{
@@ -2122,7 +2122,7 @@ CFloatingDockContainer* CDockContainerWidget::floatingWidget() const
21222122
//============================================================================
21232123
void CDockContainerWidget::closeOtherAreas(CDockAreaWidget* KeepOpenArea)
21242124
{
2125-
for (const auto DockArea : d->DockAreas)
2125+
for (const auto& DockArea : d->DockAreas)
21262126
{
21272127
if (!DockArea || DockArea == KeepOpenArea)
21282128
{

src/DockManager.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -587,7 +587,7 @@ bool CDockManager::eventFilter(QObject *obj, QEvent *e)
587587
// Window always on top of the MainWindow.
588588
if (e->type() == QEvent::WindowActivate)
589589
{
590-
for (auto _window : floatingWidgets())
590+
for (auto _window : d->FloatingWidgets)
591591
{
592592
if (!_window->isVisible() || window()->isMinimized())
593593
{
@@ -609,7 +609,7 @@ bool CDockManager::eventFilter(QObject *obj, QEvent *e)
609609
}
610610
else if (e->type() == QEvent::WindowDeactivate)
611611
{
612-
for (auto _window : floatingWidgets())
612+
for (auto _window : d->FloatingWidgets)
613613
{
614614
if (!_window->isVisible() || window()->isMinimized())
615615
{
@@ -632,7 +632,7 @@ bool CDockManager::eventFilter(QObject *obj, QEvent *e)
632632
// Sync minimize with MainWindow
633633
if (e->type() == QEvent::WindowStateChange)
634634
{
635-
for (auto _window : floatingWidgets())
635+
for (auto _window : d->FloatingWidgets)
636636
{
637637
if (! _window->isVisible())
638638
{

0 commit comments

Comments
 (0)