diff options
Diffstat (limited to 'tests/manual/embeddedintoforeignwindow')
4 files changed, 9 insertions, 9 deletions
diff --git a/tests/manual/embeddedintoforeignwindow/CMakeLists.txt b/tests/manual/embeddedintoforeignwindow/CMakeLists.txt index 003f1e02e9..a80206133b 100644 --- a/tests/manual/embeddedintoforeignwindow/CMakeLists.txt +++ b/tests/manual/embeddedintoforeignwindow/CMakeLists.txt @@ -1,8 +1,6 @@ # Copyright (C) 2022 The Qt Company Ltd. # SPDX-License-Identifier: BSD-3-Clause -# Generated from embeddedintoforeignwindow.pro. - ##################################################################### ## embeddedintoforeignwindow Binary: ##################################################################### @@ -15,6 +13,8 @@ qt_internal_add_manual_test(embeddedintoforeignwindow ../diaglib/textdump.cpp ../diaglib/textdump.h itemwindow.cpp itemwindow.h main.cpp + NO_PCH_SOURCES + itemwindow.cpp # undef QT_NO_FOREACH DEFINES QT_DIAG_LIB INCLUDE_DIRECTORIES @@ -25,9 +25,6 @@ qt_internal_add_manual_test(embeddedintoforeignwindow Qt::GuiPrivate ) -#### Keys ignored in scope 1:.:.:embeddedintoforeignwindow.pro:<TRUE>: -# TEMPLATE = "app" - ## Scopes: ##################################################################### diff --git a/tests/manual/embeddedintoforeignwindow/itemwindow.cpp b/tests/manual/embeddedintoforeignwindow/itemwindow.cpp index 143cdea402..422e699afc 100644 --- a/tests/manual/embeddedintoforeignwindow/itemwindow.cpp +++ b/tests/manual/embeddedintoforeignwindow/itemwindow.cpp @@ -1,5 +1,7 @@ // Copyright (C) 2017 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only + +#undef QT_NO_FOREACH // this file contains unported legacy Q_FOREACH uses #include "itemwindow.h" diff --git a/tests/manual/embeddedintoforeignwindow/itemwindow.h b/tests/manual/embeddedintoforeignwindow/itemwindow.h index a0e11ae1c0..a8db113761 100644 --- a/tests/manual/embeddedintoforeignwindow/itemwindow.h +++ b/tests/manual/embeddedintoforeignwindow/itemwindow.h @@ -1,5 +1,5 @@ // Copyright (C) 2017 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef ITEMWINDOW_H #define ITEMWINDOW_H @@ -65,7 +65,8 @@ private: #define PROPAGATE_EVENT(windowHandler, eventClass, itemHandler) \ void windowHandler(eventClass *e) override \ { \ - foreach (Item *i, m_items) \ + const auto copy = m_items; /* needed? */ \ + for (Item *i : copy) \ i->itemHandler(e); \ } diff --git a/tests/manual/embeddedintoforeignwindow/main.cpp b/tests/manual/embeddedintoforeignwindow/main.cpp index d87962e6b5..cadd9a3bec 100644 --- a/tests/manual/embeddedintoforeignwindow/main.cpp +++ b/tests/manual/embeddedintoforeignwindow/main.cpp @@ -1,5 +1,5 @@ // Copyright (C) 2017 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "itemwindow.h" |