diff options
Diffstat (limited to 'tests/benchmarks/widgets/graphicsview')
115 files changed, 334 insertions, 2729 deletions
diff --git a/tests/benchmarks/widgets/graphicsview/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/CMakeLists.txt index 3928328a98..bcb905aa1b 100644 --- a/tests/benchmarks/widgets/graphicsview/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/CMakeLists.txt @@ -1,4 +1,5 @@ -# Generated from graphicsview.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause add_subdirectory(functional) add_subdirectory(qgraphicsanchorlayout) diff --git a/tests/benchmarks/widgets/graphicsview/functional/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/functional/CMakeLists.txt index 20e4286a6e..8b13789179 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/functional/CMakeLists.txt @@ -1,2 +1 @@ -# Generated from functional.pro. diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/CMakeLists.txt index 3bdb724fae..c7b18103a5 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/CMakeLists.txt @@ -1,10 +1,11 @@ -# Generated from GraphicsViewBenchmark.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## tst_GraphicsViewBenchmark Binary: ##################################################################### -qt_add_benchmark(tst_GraphicsViewBenchmark +qt_internal_add_benchmark(tst_GraphicsViewBenchmark SOURCES main.cpp widgets/abstractitemcontainer.cpp widgets/abstractitemcontainer.h @@ -38,7 +39,7 @@ qt_add_benchmark(tst_GraphicsViewBenchmark widgets/topbar.cpp widgets/topbar.h INCLUDE_DIRECTORIES widgets - PUBLIC_LIBRARIES + LIBRARIES Qt::Gui Qt::Svg Qt::Test @@ -124,7 +125,7 @@ set(GraphicsViewBenchmark_resource_files "resources/blue_SVG/blue_user_status_online_38x38px.svg" ) -qt_add_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark" +qt_internal_add_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark" PREFIX "/themes/blue" FILES @@ -213,7 +214,7 @@ set(GraphicsViewBenchmark1_resource_files "resources/lime_SVG/lime_user_status_online_24x24px.svg" ) -qt_add_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark1" +qt_internal_add_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark1" PREFIX "/themes/lime" FILES @@ -322,7 +323,7 @@ set(GraphicsViewBenchmark2_resource_files "resources/avatars/avatar_woman_010_58x58.png" ) -qt_add_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark2" +qt_internal_add_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark2" PREFIX "/avatars" FILES @@ -347,22 +348,18 @@ set(GraphicsViewBenchmark3_resource_files "resources/contacts/lastnames.txt" ) -qt_add_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark3" +qt_internal_add_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark3" PREFIX "/contact" FILES ${GraphicsViewBenchmark3_resource_files} ) - -#### Keys ignored in scope 1:.:.:GraphicsViewBenchmark.pro:<TRUE>: -# TEMPLATE = "app" - ## Scopes: ##################################################################### -qt_extend_target(tst_GraphicsViewBenchmark CONDITION TARGET Qt::OpenGL - PUBLIC_LIBRARIES +qt_internal_extend_target(tst_GraphicsViewBenchmark CONDITION TARGET Qt::OpenGL + LIBRARIES Qt::OpenGL Qt::OpenGLWidgets ) diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/GraphicsViewBenchmark.pro b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/GraphicsViewBenchmark.pro deleted file mode 100644 index addb60433b..0000000000 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/GraphicsViewBenchmark.pro +++ /dev/null @@ -1,70 +0,0 @@ -TEMPLATE = app - -QT += svg testlib -qtHaveModule(opengl): QT += opengl openglwidgets - -HEADERS += widgets/gvbwidget.h \ - widgets/abstractscrollarea.h \ - widgets/mainview.h \ - widgets/iconitem.h \ - widgets/label.h \ - widgets/listitem.h \ - widgets/scrollbar.h \ - widgets/simplelistview.h \ - widgets/scroller.h \ - widgets/scroller_p.h \ - widgets/button.h \ - widgets/menu.h \ - widgets/themeevent.h \ - widgets/theme.h \ - widgets/backgrounditem.h \ - widgets/topbar.h \ - widgets/commandline.h \ - widgets/dummydatagen.h \ - widgets/settings.h \ - widgets/listitemcache.h \ - widgets/listwidget.h \ - widgets/simplelist.h \ - widgets/itemrecyclinglist.h \ - widgets/itemrecyclinglistview.h \ - widgets/abstractitemview.h \ - widgets/abstractviewitem.h \ - widgets/recycledlistitem.h \ - widgets/listitemcontainer.h \ - widgets/abstractitemcontainer.h \ - widgets/listmodel.h - -SOURCES += main.cpp \ - widgets/gvbwidget.cpp \ - widgets/abstractscrollarea.cpp \ - widgets/mainview.cpp \ - widgets/iconitem.cpp \ - widgets/label.cpp \ - widgets/listitem.cpp \ - widgets/scrollbar.cpp \ - widgets/simplelistview.cpp \ - widgets/scroller.cpp \ - widgets/button.cpp \ - widgets/menu.cpp \ - widgets/themeevent.cpp \ - widgets/theme.cpp \ - widgets/backgrounditem.cpp \ - widgets/topbar.cpp \ - widgets/commandline.cpp \ - widgets/dummydatagen.cpp \ - widgets/settings.cpp \ - widgets/listitemcache.cpp \ - widgets/listwidget.cpp \ - widgets/simplelist.cpp \ - widgets/itemrecyclinglist.cpp \ - widgets/itemrecyclinglistview.cpp \ - widgets/abstractitemview.cpp \ - widgets/abstractviewitem.cpp \ - widgets/recycledlistitem.cpp \ - widgets/listitemcontainer.cpp \ - widgets/abstractitemcontainer.cpp \ - widgets/listmodel.cpp - -TARGET = tst_GraphicsViewBenchmark -RESOURCES += GraphicsViewBenchmark.qrc -INCLUDEPATH += widgets diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/GraphicsViewBenchmark.qrc b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/GraphicsViewBenchmark.qrc deleted file mode 100644 index 18ae04dd69..0000000000 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/GraphicsViewBenchmark.qrc +++ /dev/null @@ -1,85 +0,0 @@ -<RCC> - <qresource prefix="/themes/blue"> - <file alias="background.svg">resources/blue_SVG/blue_background_360x640px.svg</file> - <file alias="background_horisontal.svg">resources/blue_SVG/blue_background_horisontal_640x360px.svg</file> - <file alias="contact_default_icon.svg">resources/blue_SVG/blue_contact_default_icon_52x52px.svg</file> - <file alias="contact_list_divider.svg">resources/blue_SVG/blue_contact_list_divider_360x76px.svg</file> - <file alias="contact_list_highlighter.svg">resources/blue_SVG/blue_contact_list_highlighter_360x76px.svg</file> - <file alias="contact_status_idle.svg">resources/blue_SVG/blue_contact_status_idle_33x33px.svg</file> - <file alias="contact_status_offline.svg">resources/blue_SVG/blue_contact_status_offline_33x33px.svg</file> - <file alias="contact_status_online.svg">resources/blue_SVG/blue_contact_status_online_33x33px.svg</file> - <file alias="scrollbar.svg">resources/blue_SVG/blue_scrollbar_7x14px.svg</file> - <file alias="scroll.svg">resources/blue_SVG/blue_scroll_16x80px.svg</file> - <file alias="status_field_left.svg">resources/blue_SVG/blue_status_field_left_14x24px.svg</file> - <file alias="status_field_middle.svg">resources/blue_SVG/blue_status_field_middle_14x24px.svg</file> - <file alias="status_field_right.svg">resources/blue_SVG/blue_status_field_right_14x24px.svg</file> - <file alias="topbar.svg">resources/blue_SVG/blue_topbar_356x96px.svg</file> - <file alias="topbar_horisontal.svg">resources/blue_SVG/blue_topbar_horisontal_636x96px.svg</file> - <file alias="user_default_icon.svg">resources/blue_SVG/blue_user_default_icon_68x68px.svg</file> - <file alias="user_status_idle.svg">resources/blue_SVG/blue_user_status_idle_38x38px.svg</file> - <file alias="user_status_offline.svg">resources/blue_SVG/blue_user_status_offline_38x38px.svg</file> - <file alias="user_status_online.svg">resources/blue_SVG/blue_user_status_online_38x38px.svg</file> - </qresource> - - <qresource prefix="/themes/lime"> - <file alias="background.svg">resources/lime_SVG/lime_background_360x640px.svg</file> - <file alias="background_horisontal.svg">resources/lime_SVG/lime_background_horisontal_640x360px.svg</file> - <file alias="contact_default_icon.svg">resources/lime_SVG/lime_contact_default_icon_53x53px.svg</file> - <file alias="contact_default_icon_highlight.svg">resources/lime_SVG/lime_contact_default_icon_highlight_53x53px.svg</file> - <file alias="contact_list_divider.svg">resources/lime_SVG/lime_contact_list_divider_360x76px.svg</file> - <file alias="contact_list_highlighter.svg">resources/lime_SVG/lime_contact_list_highlighter_357x80px.svg</file> - <file alias="contact_status_idle.svg">resources/blue_SVG/blue_contact_status_idle_33x33px.svg</file> - <file alias="contact_status_offline.svg">resources/blue_SVG/blue_contact_status_offline_33x33px.svg</file> - <file alias="contact_status_online.svg">resources/blue_SVG/blue_contact_status_online_33x33px.svg</file> - <file alias="scrollbar.svg">resources/lime_SVG/lime_scrollbar_5x14px.svg</file> - <file alias="scroll.svg">resources/lime_SVG/lime_scroll_5x80px.svg</file> - <file alias="status_field_left.svg">resources/lime_SVG/lime_status_field_left_14x24px.svg</file> - <file alias="status_field_middle.svg">resources/lime_SVG/lime_status_field_middle_10x24px.svg</file> - <file alias="status_field_right.svg">resources/lime_SVG/lime_status_field_right_14x24px.svg</file> - <file alias="topbar.svg">resources/lime_SVG/lime_topbar_356x96px.svg</file> - <file alias="topbar_horisontal.svg">resources/lime_SVG/lime_topbar_horisontal_636x96px.svg</file> - <file alias="user_default_icon.svg">resources/lime_SVG/lime_user_default_icon_84x68px.svg</file> - <file alias="user_status_idle.svg">resources/lime_SVG/lime_user_status_idle_24x24px.svg</file> - <file alias="user_status_offline.svg">resources/lime_SVG/lime_user_status_offline_24x24px.svg</file> - <file alias="user_status_online.svg">resources/lime_SVG/lime_user_status_online_24x24px.svg</file> - </qresource> - - <qresource prefix="/avatars"> - <file alias="avatar_001.png">resources/avatars/avatar_man_001_58x58.png</file> - <file alias="avatar_002.png">resources/avatars/avatar_man_002_58x58.png</file> - <file alias="avatar_003.png">resources/avatars/avatar_man_003_58x58.png</file> - <file alias="avatar_004.png">resources/avatars/avatar_man_004_58x58.png</file> - <file alias="avatar_005.png">resources/avatars/avatar_man_005_58x58.png</file> - <file alias="avatar_006.png">resources/avatars/avatar_man_006_58x58.png</file> - <file alias="avatar_007.png">resources/avatars/avatar_man_007_58x58.png</file> - <file alias="avatar_008.png">resources/avatars/avatar_man_008_58x58.png</file> - <file alias="avatar_009.png">resources/avatars/avatar_man_009_58x58.png</file> - <file alias="avatar_010.png">resources/avatars/avatar_man_010_58x58.png</file> - - <file alias="avatar_011.png">resources/avatars/avatar_picture_001_58x58.png</file> - <file alias="avatar_012.png">resources/avatars/avatar_picture_002_58x58.png</file> - <file alias="avatar_013.png">resources/avatars/avatar_picture_003_58x58.png</file> - <file alias="avatar_014.png">resources/avatars/avatar_picture_004_58x58.png</file> - <file alias="avatar_015.png">resources/avatars/avatar_picture_005_58x58.png</file> - - <file alias="avatar_016.png">resources/avatars/avatar_woman_001_58x58.png</file> - <file alias="avatar_017.png">resources/avatars/avatar_woman_002_58x58.png</file> - <file alias="avatar_018.png">resources/avatars/avatar_woman_003_58x58.png</file> - <file alias="avatar_019.png">resources/avatars/avatar_woman_004_58x58.png</file> - <file alias="avatar_020.png">resources/avatars/avatar_woman_005_58x58.png</file> - <file alias="avatar_021.png">resources/avatars/avatar_woman_006_58x58.png</file> - <file alias="avatar_022.png">resources/avatars/avatar_woman_007_58x58.png</file> - <file alias="avatar_023.png">resources/avatars/avatar_woman_008_58x58.png</file> - <file alias="avatar_024.png">resources/avatars/avatar_woman_009_58x58.png</file> - <file alias="avatar_025.png">resources/avatars/avatar_woman_010_58x58.png</file> - </qresource> - - <qresource prefix="/contact"> - <file alias="areacodes.txt">resources/contacts/areacodes.txt</file> - <file alias="firstnamesF.txt">resources/contacts/firstnamesF.txt</file> - <file alias="firstnamesM.txt">resources/contacts/firstnamesM.txt</file> - <file alias="lastnames.txt">resources/contacts/lastnames.txt</file> - </qresource> - -</RCC> - diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/main.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/main.cpp index 907a320d76..fa47ca9fa6 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/main.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/main.cpp @@ -1,33 +1,8 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - - -#include <QtTest/QtTest> +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only + + +#include <QTest> #include <QtGui/qpixmapcache.h> #include <QtGui/QScreen> @@ -566,23 +541,11 @@ void tst_GraphicsViewBenchmark::update_data() QTest::addColumn<bool>("subtreeCache"); QTest::addColumn<int>("rotationAngle"); - QList<ListType> listTypes; - listTypes << Simple << Recycling; - - QList<int> listSizes; - listSizes << 10 << 50 << 500; - - QList<Theme::Themes> themes; - themes << Theme::Blue << Theme::Lime; - - QList<int> rotationAngles; - rotationAngles << 0 << 90; - // Generate rows: - foreach (ListType listType, listTypes) { - foreach (int listSize, listSizes) { - foreach (int angle, rotationAngles) { - foreach (Theme::Themes theme, themes) { + for (ListType listType : {Simple, Recycling}) { + for (int listSize : {10, 50, 500}) { + for (int angle : {0, 90}) { + for (Theme::Themes theme : {Theme::Blue, Theme::Lime}) { for (int toImage = 0; toImage < 2; ++toImage) { for (int cache = 0; cache < 2; ++cache) { QString string = rowString(listSize, listType, theme, toImage, cache, angle); @@ -638,27 +601,12 @@ void tst_GraphicsViewBenchmark::scroll_data() QTest::addColumn<int>("rotationAngle"); QTest::addColumn<ScrollStep>("scrollStep"); - QList<ListType> listTypes; - listTypes << Simple << Recycling; - - QList<int> listSizes; - listSizes << 10 << 50 << 500; - - QList<Theme::Themes> themes; - themes << Theme::Blue << Theme::Lime; - - QList<int> rotationAngles; - rotationAngles << 0 << 90; - - QList<ScrollStep> scrollSteps; - scrollSteps << Slow << Normal << Fast; - // Generate rows: - foreach (ListType listType, listTypes) { - foreach (int listSize, listSizes) { - foreach (int angle, rotationAngles) { - foreach (ScrollStep step, scrollSteps) { - foreach (Theme::Themes theme, themes) { + for (ListType listType : {Simple, Recycling}) { + for (int listSize : {10, 50, 500}) { + for (int angle : {0, 90}) { + for (ScrollStep step : {Slow, Normal, Fast}) { + for (Theme::Themes theme : {Theme::Blue, Theme::Lime}) { for (int cache = 0; cache < 2; ++cache) { QString string = rowString(listSize, listType, theme, cache, angle, step); QTest::newRow(string.toLatin1()) << listSize << listType << theme diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.cpp index 00481a638d..9cf6ffcaa2 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QDebug> #include <QGraphicsLayout> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.h index 7373f66deb..d3d1b334f4 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef ABSTRACTITEMCONTAINER_H #define ABSTRACTITEMCONTAINER_H diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.cpp index e5214b51fb..87350f6b62 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QGraphicsLayout> #include "abstractitemview.h" diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.h index 8cd295ba89..6242c9647b 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef ABSTRACTITEMVIEW_H #define ABSTRACTITEMVIEW_H @@ -44,7 +19,7 @@ class AbstractItemView : public AbstractScrollArea { Q_OBJECT public: - AbstractItemView(QGraphicsWidget *parent = 0); + AbstractItemView(QGraphicsWidget *parent = nullptr); virtual ~AbstractItemView(); virtual void setContainer(AbstractItemContainer *container); virtual void setModel(QAbstractItemModel *model, AbstractViewItem *prototype); diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.cpp index e4588cc1d1..c390550cb9 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QGraphicsSceneResizeEvent> #include <QGraphicsWidget> @@ -115,9 +90,9 @@ void AbstractScrollArea::setViewport(QGraphicsWidget *viewport) if (m_viewport) { m_viewport->setParentItem(0); - QList<QGraphicsItem*> children = m_viewport->childItems(); + const QList<QGraphicsItem*> children = m_viewport->childItems(); - foreach (QGraphicsItem *child, children) + for (QGraphicsItem *child : children) child->setParentItem(0); delete m_viewport; diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.h index f681ca9fce..0fefcfe271 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef ABSTRACTSCROLLAREA_H #define ABSTRACTSCROLLAREA_H @@ -40,7 +15,7 @@ class AbstractScrollArea : public GvbWidget public: - AbstractScrollArea(QGraphicsWidget *parent = 0); + AbstractScrollArea(QGraphicsWidget *parent = nullptr); ~AbstractScrollArea(); public: diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractviewitem.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractviewitem.cpp index dbd7c40c35..b12cf4c81a 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractviewitem.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractviewitem.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "abstractviewitem.h" diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractviewitem.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractviewitem.h index 4f9fbf4623..c85ad3d203 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractviewitem.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractviewitem.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef ABSTRACTVIEWITEM_H #define ABSTRACTVIEWITEM_H @@ -41,7 +16,7 @@ class AbstractViewItem : public GvbWidget { Q_OBJECT public: - AbstractViewItem(QGraphicsWidget *parent = 0); + AbstractViewItem(QGraphicsWidget *parent = nullptr); virtual ~AbstractViewItem(); virtual AbstractViewItem *newItemInstance() = 0; diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.cpp index 1b928ab908..16eeb25467 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QStyleOptionGraphicsItem> #include <QGraphicsSceneResizeEvent> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.h index 0cb0ee778c..ba961e2792 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef __BACKGROUNDITEM_H__ #define __BACKGROUNDITEM_H__ diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/button.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/button.cpp index 98bf9f8521..d9d6e48f99 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/button.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/button.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "button.h" #include "theme.h" diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/button.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/button.h index 8e76b88463..0c117d2c81 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/button.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/button.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef BUTTON_H #define BUTTON_H diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.cpp index 226c60cec8..492eb95628 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QStringList> #include <QDebug> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.h index eaddeac59d..59be7e87f1 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef COMMANDLINE_H #define COMMANDLINE_H diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.cpp index 7809b38050..19cbb62770 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QFile> #include <QRandomGenerator> @@ -123,5 +98,5 @@ QString DummyDataGenerator::randomStatusItem() case 1: return Theme::p()->pixmapPath() + "contact_status_offline.svg"; case 2: return Theme::p()->pixmapPath() + "contact_status_idle.svg"; } - return 0; + return {}; } diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.h index bcb9681d5d..114380c264 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef __DUMMYDATAGEN_H__ #define __DUMMYDATAGEN_H__ diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.cpp index 93285c0723..efa35db679 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QtGui> #include "gvbwidget.h" diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.h index 1212703ddb..54d7cac5a5 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef GVBWIDGET_H #define GVBWIDGET_H @@ -37,7 +12,7 @@ class GvbWidget : public QGraphicsWidget public: - GvbWidget(QGraphicsItem * parent = 0, Qt::WindowFlags wFlags = { }); + GvbWidget(QGraphicsItem * parent = nullptr, Qt::WindowFlags wFlags = { }); ~GvbWidget(); virtual void keyPressEvent(QKeyEvent *event); }; diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.cpp index a081e1b064..088f517105 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QtGui> #include <QSvgRenderer> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.h index 48d1bafe9f..53bcce2466 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef ICONITEM_H #define ICONITEM_H @@ -42,7 +17,7 @@ class IconItem : public GvbWidget public: - IconItem(const QString &filename = "", QGraphicsItem *parent = 0); + IconItem(const QString &filename = "", QGraphicsItem *parent = nullptr); virtual ~IconItem(); diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.cpp index 0aa73b9e26..3e9669cd44 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2020 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2020 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QDebug> #include <QElapsedTimer> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.h index a69b60c9e2..7dc6b3e224 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef ITEMRECYCLINGLIST_H #define ITEMRECYCLINGLIST_H @@ -42,7 +17,7 @@ class ItemRecyclingList : public ItemRecyclingListView Q_OBJECT public: - ItemRecyclingList(const int itemBuffer = 4, QGraphicsWidget * parent = 0); + ItemRecyclingList(const int itemBuffer = 4, QGraphicsWidget * parent = nullptr); virtual ~ItemRecyclingList(); virtual void insertItem(int index, RecycledListItem *item); diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.pri b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.pri deleted file mode 100644 index 55b551ef8f..0000000000 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.pri +++ /dev/null @@ -1,19 +0,0 @@ -HEADERS += $$ROOTDIR/tests/itemrecyclinglist/itemrecyclinglist.h \ - $$ROOTDIR/tests/itemrecyclinglist/itemrecyclinglistview.h \ - $$ROOTDIR/tests/itemrecyclinglist/abstractitemview.h \ - $$ROOTDIR/tests/itemrecyclinglist/abstractviewitem.h \ - $$ROOTDIR/tests/itemrecyclinglist/recycledlistitem.h \ - $$ROOTDIR/tests/itemrecyclinglist/listitemcontainer.h \ - $$ROOTDIR/tests/itemrecyclinglist/abstractitemcontainer.h \ - $$ROOTDIR/tests/itemrecyclinglist/listmodel.h - -SOURCES += $$ROOTDIR/tests/itemrecyclinglist/itemrecyclinglist.cpp \ - $$ROOTDIR/tests/itemrecyclinglist/itemrecyclinglistview.cpp \ - $$ROOTDIR/tests/itemrecyclinglist/abstractitemview.cpp \ - $$ROOTDIR/tests/itemrecyclinglist/abstractviewitem.cpp \ - $$ROOTDIR/tests/itemrecyclinglist/recycledlistitem.cpp \ - $$ROOTDIR/tests/itemrecyclinglist/listitemcontainer.cpp \ - $$ROOTDIR/tests/itemrecyclinglist/abstractitemcontainer.cpp \ - $$ROOTDIR/tests/itemrecyclinglist/listmodel.cpp - -INCLUDEPATH += $$ROOTDIR/tests/itemrecyclinglist diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglistview.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglistview.cpp index 5aa93256ff..7406c37677 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglistview.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglistview.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "itemrecyclinglistview.h" diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglistview.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglistview.h index 467f193604..b7ab0f3004 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglistview.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglistview.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef ITEMRECYCLINGLISTVIEW_H #define ITEMRECYCLINGLISTVIEW_H @@ -34,7 +9,7 @@ class ItemRecyclingListView : public AbstractItemView { public: - ItemRecyclingListView(QGraphicsWidget * parent = 0); + ItemRecyclingListView(QGraphicsWidget * parent = nullptr); virtual ~ItemRecyclingListView(); void setCurrentRow(const int row); int rows() const; diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/label.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/label.cpp index 5fb2ee1a51..c09043df93 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/label.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/label.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QtGui> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/label.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/label.h index 2c1f14b20e..6d6705027e 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/label.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/label.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef TEXTITEM_H #define TEXTITEM_H @@ -41,7 +16,7 @@ class Label : public GvbWidget public: - Label(const QString& text, QGraphicsItem *parent = 0); + Label(const QString& text, QGraphicsItem *parent = nullptr); ~Label(); public: diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.cpp index 1872bcc9d3..6c11effa28 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QDebug> #include <QGraphicsGridLayout> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.h index 4f033803ac..01c1d61ea4 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef LISTITEM_H #define LISTITEM_H @@ -57,7 +32,7 @@ public: RightIcon = 1 }; - ListItem(QGraphicsWidget *parent = 0); + ListItem(QGraphicsWidget *parent = nullptr); virtual ~ListItem(); void setIcon(IconItem *iconItem, const IconItemPos iconPos); diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.cpp index 0e4520d0a8..ed8943aa7b 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QGraphicsItem> #include <QPainter> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.h index ba35023bbc..0827ae1cea 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef LISTITEMCACHE_H #define LISTITEMCACHE_H diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.cpp index 496919214d..5815dfa103 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <qmath.h> #include <QGraphicsLinearLayout> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.h index 62c9450c38..6c03a9e116 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef LISTITEMCONTAINER_H #define LISTITEMCONTAINER_H diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.cpp index 1aa2cfa1ea..eb10745328 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "listmodel.h" #include "recycledlistitem.h" diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.h index 623c90dedc..b6fdbcb837 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef LISTMODEL_H #define LISTMODEL_H @@ -40,7 +15,7 @@ class ListModel : public QAbstractListModel public: - ListModel(QObject *parent = 0); + ListModel(QObject *parent = nullptr); ~ListModel(); public: diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.cpp index 6e09a09d81..fbb82777b9 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QGraphicsSceneResizeEvent> #include <QGraphicsGridLayout> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.h index 0dfd41a1c3..cbd23ca19a 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef LISTWIDGET_H #define LISTWIDGET_H @@ -44,7 +19,7 @@ class ListWidget : public GvbWidget Q_OBJECT public: - ListWidget(QGraphicsWidget * parent = 0); + ListWidget(QGraphicsWidget * parent = nullptr); virtual ~ListWidget(); void addItem(QGraphicsWidget *item); void insertItem(int index, QGraphicsWidget *item); diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.cpp index d8e778f151..1f92107729 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2020 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2020 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QDebug> #include <QApplication> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.h index e92f46a53b..d2ff03f039 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2020 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2020 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef __MAINWINDOW_H__ #define __MAINWINDOW_H__ @@ -49,7 +24,7 @@ class MainView : public QGraphicsView { Q_OBJECT public: - MainView(const bool enableOpenGL, const bool outputFps, const bool imageBasedRendering = false, QWidget *parent = 0); + MainView(const bool enableOpenGL, const bool outputFps, const bool imageBasedRendering = false, QWidget *parent = nullptr); ~MainView(); void setTestWidget(QGraphicsWidget *testWidget); diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.cpp index 1cc75d569b..8c2ff7b7ce 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QGraphicsView> #include <QGraphicsWidget> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.h index 074d5b9d95..fd50fe5039 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef __MENU_H__ #define __MENU_H__ diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.cpp index c0aed25abb..a457b69be9 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QGraphicsGridLayout> #include <QDebug> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.h index 021a8b8902..82dd304b38 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef RECYCLEDLISTITEM_H #define RECYCLEDLISTITEM_H diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/resourcemoninterface.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/resourcemoninterface.h index b03f09048a..6d58d139bb 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/resourcemoninterface.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/resourcemoninterface.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef __RESOURCEMONINTERFACE_H__ #define __RESOURCEMONINTERFACE_H__ diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.cpp index 81f123e2b7..3361c1e1c0 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QGraphicsWidget> #include <QPainter> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.h index 966052676c..9abd5d264b 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef SCROLLBAR_H #define SCROLLBAR_H diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.cpp index 203ea7e046..241d752365 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QScrollBar> #include <QEvent> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.h index 8f40dcfd16..db9c47d838 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef SCROLLER_H #define SCROLLER_H @@ -40,7 +15,7 @@ class Scroller : public QObject public: - Scroller(QObject *parent = 0); + Scroller(QObject *parent = nullptr); virtual ~Scroller(); public: diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller_p.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller_p.h index c8769f59b2..c18f4069e3 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller_p.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller_p.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2020 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2020 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef SCROLLER_P_H #define SCROLLER_P_H diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.cpp index 9cb44882a6..4b0adffe5c 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "settings.h" diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.h index dc228162c4..da961493ad 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef SETTINGS_H #define SETTINGS_H diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.cpp index d64f3ac38d..0020e2491d 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2020 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2020 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QDebug> #include <QGraphicsLinearLayout> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.h index 3c1ec4f82a..ef29d5c855 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef SIMPLELIST_H_ #define SIMPLELIST_H_ diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.cpp index b1467238f8..3de5554e61 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "simplelistview.h" #include "scrollbar.h" diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.h index ad606cda8f..32ed0af937 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef SIMPLELISTVIEW_H #define SIMPLELISTVIEW_H @@ -41,7 +16,7 @@ class SimpleListView : public AbstractScrollArea public: - SimpleListView(QGraphicsWidget *parent = 0); + SimpleListView(QGraphicsWidget *parent = nullptr); virtual ~SimpleListView(); public: diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/theme.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/theme.cpp index 06851b0fd8..8de0b612df 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/theme.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/theme.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QDebug> #include <QPainter> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/theme.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/theme.h index 4aafd0c288..b78a9033f9 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/theme.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/theme.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef THEME_H #define THEME_H @@ -89,7 +64,7 @@ signals: void themeChanged(); private: - Theme(QObject *parent = 0); + Theme(QObject *parent = nullptr); void setBlueTheme(); void setLimeTheme(); diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.cpp index 1209b4a0f7..4df67b63bf 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "themeevent.h" diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.h index 4ae63d8755..4b06f54267 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef __THEMEEVENT_H__ #define __THEMEEVENT_H__ diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.cpp index 7c3d97b859..ece0cfa66f 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QGraphicsView> #include <QStyleOptionGraphicsItem> diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.h index 53750ca706..152b4ba2b6 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef __TOPBAR_H__ #define __TOPBAR_H__ diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.cpp b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.cpp index d09bd43214..c3c14a6362 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.cpp +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "webview.h" #include "webview_p.h" diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.h index a18df35957..8eafb65048 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef WEBVIEW_H #define WEBVIEW_H @@ -40,7 +15,7 @@ class WebView : public AbstractScrollArea public: - WebView(QGraphicsWidget *parent = 0); + WebView(QGraphicsWidget *parent = nullptr); ~WebView(); public: diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview_p.h b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview_p.h index 98817e6762..f0c87e5a0f 100644 --- a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview_p.h +++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/widgets/webview_p.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef WEBVIEW_P_H #define WEBVIEW_P_H diff --git a/tests/benchmarks/widgets/graphicsview/functional/functional.pro b/tests/benchmarks/widgets/graphicsview/functional/functional.pro deleted file mode 100644 index 3c2979448b..0000000000 --- a/tests/benchmarks/widgets/graphicsview/functional/functional.pro +++ /dev/null @@ -1,4 +0,0 @@ -TEMPLATE = subdirs -SUBDIRS = \ - #GraphicsViewBenchmark # FIXME: cannot be compiled by default as part of qtbase, - # since it depends on qtsvg diff --git a/tests/benchmarks/widgets/graphicsview/graphicsview.pro b/tests/benchmarks/widgets/graphicsview/graphicsview.pro deleted file mode 100644 index 8344cd4edf..0000000000 --- a/tests/benchmarks/widgets/graphicsview/graphicsview.pro +++ /dev/null @@ -1,10 +0,0 @@ -TEMPLATE = subdirs -SUBDIRS = \ - functional \ - qgraphicsanchorlayout \ - qgraphicsitem \ - qgraphicslayout \ - qgraphicslinearlayout \ - qgraphicsscene \ - qgraphicsview \ - qgraphicswidget diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt index 4355be1f99..53c5068d7b 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt @@ -1,17 +1,15 @@ -# Generated from qgraphicsanchorlayout.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## tst_bench_qgraphicsanchorlayout Binary: ##################################################################### -qt_add_benchmark(tst_bench_qgraphicsanchorlayout +qt_internal_add_benchmark(tst_bench_qgraphicsanchorlayout SOURCES tst_qgraphicsanchorlayout.cpp - PUBLIC_LIBRARIES + LIBRARIES Qt::Gui Qt::Test Qt::Widgets ) - -#### Keys ignored in scope 1:.:.:qgraphicsanchorlayout.pro:<TRUE>: -# TEMPLATE = "app" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/qgraphicsanchorlayout.pro b/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/qgraphicsanchorlayout.pro deleted file mode 100644 index 01c0dbd653..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/qgraphicsanchorlayout.pro +++ /dev/null @@ -1,7 +0,0 @@ -QT += widgets testlib - -TEMPLATE = app -TARGET = tst_bench_qgraphicsanchorlayout - -SOURCES += tst_qgraphicsanchorlayout.cpp - diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/tst_qgraphicsanchorlayout.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/tst_qgraphicsanchorlayout.cpp index e0c5a7f683..d65246a568 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/tst_qgraphicsanchorlayout.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/tst_qgraphicsanchorlayout.cpp @@ -1,32 +1,7 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -#include <QtTest/QtTest> +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only + +#include <QTest> #include <QtWidgets/qgraphicsanchorlayout.h> #include <QtWidgets/qgraphicslinearlayout.h> #include <QtWidgets/qgraphicswidget.h> @@ -54,9 +29,9 @@ private slots: class RectWidget : public QGraphicsWidget { public: - RectWidget(QGraphicsItem *parent = 0) : QGraphicsWidget(parent){} + RectWidget(QGraphicsItem *parent = nullptr) : QGraphicsWidget(parent){} - void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) + void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) override { Q_UNUSED(option); Q_UNUSED(widget); diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsitem/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsitem/CMakeLists.txt index e32fd82819..0ab35585fb 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsitem/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsitem/CMakeLists.txt @@ -1,17 +1,15 @@ -# Generated from qgraphicsitem.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## tst_bench_qgraphicsitem Binary: ##################################################################### -qt_add_benchmark(tst_bench_qgraphicsitem +qt_internal_add_benchmark(tst_bench_qgraphicsitem SOURCES tst_qgraphicsitem.cpp - PUBLIC_LIBRARIES + LIBRARIES Qt::Gui Qt::Test Qt::Widgets ) - -#### Keys ignored in scope 1:.:.:qgraphicsitem.pro:<TRUE>: -# TEMPLATE = "app" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsitem/qgraphicsitem.pro b/tests/benchmarks/widgets/graphicsview/qgraphicsitem/qgraphicsitem.pro deleted file mode 100644 index 461ec13263..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsitem/qgraphicsitem.pro +++ /dev/null @@ -1,6 +0,0 @@ -QT += widgets testlib - -TEMPLATE = app -TARGET = tst_bench_qgraphicsitem - -SOURCES += tst_qgraphicsitem.cpp diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsitem/tst_qgraphicsitem.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsitem/tst_qgraphicsitem.cpp index 56b34fff2a..7556864ded 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsitem/tst_qgraphicsitem.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsitem/tst_qgraphicsitem.cpp @@ -1,35 +1,11 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite module of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <qtest.h> #include <QGraphicsItem> #include <QGraphicsScene> #include <QGraphicsView> +#include <QTextDocument> class tst_QGraphicsItem : public QObject { @@ -57,6 +33,8 @@ private slots: void scale(); void shear(); void translate(); + void createTextItem(); + void createTextItemNoLayouting(); }; tst_QGraphicsItem::tst_QGraphicsItem() @@ -230,5 +208,32 @@ void tst_QGraphicsItem::translate() } } +void tst_QGraphicsItem::createTextItem() +{ + // Ensure QFontDatabase loaded the font beforehand + QFontInfo(qApp->font()).family(); + const QString text = "This is some text"; + QBENCHMARK { + QGraphicsTextItem item(text); + } +} + +void tst_QGraphicsItem::createTextItemNoLayouting() +{ + // Ensure QFontDatabase loaded the font beforehand + QFontInfo(qApp->font()).family(); + const QString text = "This is some text"; + QBENCHMARK { + QGraphicsTextItem item; + item.document()->setLayoutEnabled(false); + // Prepare everything + item.setPlainText(text); + QTextOption option = item.document()->defaultTextOption(); + option.setAlignment(Qt::AlignHCenter); + item.document()->setDefaultTextOption(option); + // And (in a real app) enable layouting here + } +} + QTEST_MAIN(tst_QGraphicsItem) #include "tst_qgraphicsitem.moc" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicslayout/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicslayout/CMakeLists.txt index aa25f356ca..0a33918c39 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicslayout/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/qgraphicslayout/CMakeLists.txt @@ -1,17 +1,17 @@ -# Generated from qgraphicslayout.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## tst_bench_qgraphicslayout Binary: ##################################################################### -qt_add_benchmark(tst_bench_qgraphicslayout +qt_internal_add_benchmark(tst_bench_qgraphicslayout SOURCES tst_qgraphicslayout.cpp - PUBLIC_LIBRARIES + LIBRARIES Qt::Gui Qt::Test Qt::Widgets ) -#### Keys ignored in scope 1:.:.:qgraphicslayout.pro:<TRUE>: # TEMPLATE = "app" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicslayout/qgraphicslayout.pro b/tests/benchmarks/widgets/graphicsview/qgraphicslayout/qgraphicslayout.pro deleted file mode 100644 index a20d9e0921..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicslayout/qgraphicslayout.pro +++ /dev/null @@ -1,5 +0,0 @@ -TEMPLATE = app -TARGET = tst_bench_qgraphicslayout -QT += testlib widgets -SOURCES += tst_qgraphicslayout.cpp - diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicslayout/tst_qgraphicslayout.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicslayout/tst_qgraphicslayout.cpp index bd7899e671..f583606266 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicslayout/tst_qgraphicslayout.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicslayout/tst_qgraphicslayout.cpp @@ -1,32 +1,7 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -#include <QtTest> +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only + +#include <QTest> #include <QGraphicsLayout> #include <QGraphicsLinearLayout> #include <QGraphicsWidget> @@ -47,9 +22,9 @@ private slots: class RectWidget : public QGraphicsWidget { public: - RectWidget(QGraphicsItem *parent = 0, Qt::WindowFlags wFlags = { }) : QGraphicsWidget(parent, wFlags), setGeometryCalls(0) {} + RectWidget(QGraphicsItem *parent = nullptr, Qt::WindowFlags wFlags = { }) : QGraphicsWidget(parent, wFlags), setGeometryCalls(0) {} - void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) + void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) override { Q_UNUSED(option); Q_UNUSED(widget); @@ -58,7 +33,7 @@ public: painter->drawLine(rect().bottomLeft(), rect().topRight()); } - void setGeometry(const QRectF &rect) + void setGeometry(const QRectF &rect) override { //qDebug() << "setGeometry():" << this->data(0).toString(); setGeometryCalls->insert(this, rect); @@ -114,15 +89,13 @@ void tst_QGraphicsLayout::invalidate() // ...then measure... - int pass = 1; - // should be as small as possible, to reduce overhead of painting QSizeF size(1, 1); setGeometryCalls->clear(); QBENCHMARK { leaf->setMinimumSize(size); leaf->setMaximumSize(size); - while (setGeometryCalls->count() < depth) { + while (setGeometryCalls->size() < depth) { QApplication::sendPostedEvents(); } // force a resize on each widget, this will ensure diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt index 5d682dcdde..10e59e0ecf 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt @@ -1,17 +1,15 @@ -# Generated from qgraphicslinearlayout.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## tst_bench_qgraphicslinearlayout Binary: ##################################################################### -qt_add_benchmark(tst_bench_qgraphicslinearlayout +qt_internal_add_benchmark(tst_bench_qgraphicslinearlayout SOURCES tst_qgraphicslinearlayout.cpp - PUBLIC_LIBRARIES + LIBRARIES Qt::Gui Qt::Test Qt::Widgets ) - -#### Keys ignored in scope 1:.:.:qgraphicslinearlayout.pro:<TRUE>: -# TEMPLATE = "app" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/qgraphicslinearlayout.pro b/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/qgraphicslinearlayout.pro deleted file mode 100644 index e9a9e9353e..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/qgraphicslinearlayout.pro +++ /dev/null @@ -1,5 +0,0 @@ -TEMPLATE = app -TARGET = tst_bench_qgraphicslinearlayout -QT += testlib widgets -SOURCES += tst_qgraphicslinearlayout.cpp - diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/tst_qgraphicslinearlayout.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/tst_qgraphicslinearlayout.cpp index 254d147e52..6dd9dc7d9a 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/tst_qgraphicslinearlayout.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/tst_qgraphicslinearlayout.cpp @@ -1,32 +1,7 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -#include <QtTest> +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only + +#include <QTest> #include <QGraphicsLinearLayout> #include <QGraphicsWidget> #include <QGraphicsView> @@ -47,7 +22,7 @@ private slots: struct MySquareWidget : public QGraphicsWidget { MySquareWidget() {} - virtual QSizeF sizeHint ( Qt::SizeHint which, const QSizeF & constraint = QSizeF() ) const + QSizeF sizeHint(Qt::SizeHint which, const QSizeF &constraint = QSizeF()) const override { if (which != Qt::PreferredSize) return QGraphicsWidget::sizeHint(which, constraint); diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsscene/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsscene/CMakeLists.txt index 682fb1acae..1a39b258db 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsscene/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsscene/CMakeLists.txt @@ -1,17 +1,15 @@ -# Generated from qgraphicsscene.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## tst_bench_qgraphicsscene Binary: ##################################################################### -qt_add_benchmark(tst_bench_qgraphicsscene +qt_internal_add_benchmark(tst_bench_qgraphicsscene SOURCES tst_qgraphicsscene.cpp - PUBLIC_LIBRARIES + LIBRARIES Qt::Gui Qt::Test Qt::Widgets ) - -#### Keys ignored in scope 1:.:.:qgraphicsscene.pro:<TRUE>: -# TEMPLATE = "app" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsscene/qgraphicsscene.pro b/tests/benchmarks/widgets/graphicsview/qgraphicsscene/qgraphicsscene.pro deleted file mode 100644 index 769f84423e..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsscene/qgraphicsscene.pro +++ /dev/null @@ -1,7 +0,0 @@ -QT += widgets testlib - -TEMPLATE = app -TARGET = tst_bench_qgraphicsscene - -SOURCES += tst_qgraphicsscene.cpp - diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsscene/tst_qgraphicsscene.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsscene/tst_qgraphicsscene.cpp index 6145fabbf8..cc53100a43 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsscene/tst_qgraphicsscene.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsscene/tst_qgraphicsscene.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <qtest.h> #include <QGraphicsItem> @@ -217,6 +192,7 @@ void tst_QGraphicsScene::itemAt() QGraphicsItem *item = 0; QBENCHMARK { item = scene.items(QPointF(0, 0)).value(0, nullptr); + Q_UNUSED(item) } //let QGraphicsScene::_q_polishItems be called so ~QGraphicsItem doesn't spend all his time cleaning the unpolished list diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsview/CMakeLists.txt index a86f236664..c9eff6db3c 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/CMakeLists.txt @@ -1,15 +1,16 @@ -# Generated from qgraphicsview.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## tst_bench_qgraphicsview Binary: ##################################################################### -qt_add_benchmark(tst_bench_qgraphicsview +qt_internal_add_benchmark(tst_bench_qgraphicsview SOURCES chiptester/chip.cpp chiptester/chip.h chiptester/chiptester.cpp chiptester/chiptester.h tst_qgraphicsview.cpp - PUBLIC_LIBRARIES + LIBRARIES Qt::Gui Qt::Test Qt::Widgets @@ -23,17 +24,17 @@ set(qgraphicsview_resource_files "random.data" ) -qt_add_resource(tst_bench_qgraphicsview "qgraphicsview" +qt_internal_add_resource(tst_bench_qgraphicsview "qgraphicsview" PREFIX "/" FILES ${qgraphicsview_resource_files} ) set(images_resource_files - "qt4logo.png" + "chiptester/qt4logo.png" ) -qt_add_resource(tst_bench_qgraphicsview "images" +qt_internal_add_resource(tst_bench_qgraphicsview "images" PREFIX "/" BASE @@ -42,14 +43,10 @@ qt_add_resource(tst_bench_qgraphicsview "images" ${images_resource_files} ) - -#### Keys ignored in scope 1:.:.:qgraphicsview.pro:<TRUE>: -# TEMPLATE = "app" - ## Scopes: ##################################################################### -qt_extend_target(tst_bench_qgraphicsview CONDITION TARGET Qt::OpenGL - PUBLIC_LIBRARIES +qt_internal_extend_target(tst_bench_qgraphicsview CONDITION TARGET Qt::OpenGL + LIBRARIES Qt::OpenGL ) diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/CMakeLists.txt index ae5a17f020..e3577fd91e 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/CMakeLists.txt @@ -1,17 +1,18 @@ -# Generated from chip.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## chip Binary: ##################################################################### -qt_add_benchmark(chip +qt_internal_add_benchmark(chip GUI SOURCES chip.cpp chip.h main.cpp mainwindow.cpp mainwindow.h view.cpp view.h - PUBLIC_LIBRARIES + LIBRARIES Qt::Gui ) @@ -25,24 +26,17 @@ set(images_resource_files "zoomout.png" ) -qt_add_resource(chip "images" +qt_internal_add_resource(chip "images" PREFIX "/" FILES ${images_resource_files} ) - -#### Keys ignored in scope 1:.:.:chip.pro:<TRUE>: -# INSTALLS = "target" "sources" -# sources.files = "$$SOURCES" "$$HEADERS" "$$RESOURCES" "*.png" "*.pro" "*.html" "*.doc" "images" -# sources.path = "$$[QT_INSTALL_EXAMPLES]/graphicsview/chip" -# target.path = "$$[QT_INSTALL_EXAMPLES]/graphicsview/chip" - ## Scopes: ##################################################################### -qt_extend_target(chip CONDITION TARGET Qt::OpenGL - PUBLIC_LIBRARIES +qt_internal_extend_target(chip CONDITION TARGET Qt::OpenGL + LIBRARIES Qt::OpenGL ) diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.cpp index 4937edf8fd..94c779658d 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "chip.h" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.debug b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.debug Binary files differdeleted file mode 100644 index 8fe1e5b0f1..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.debug +++ /dev/null diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.h b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.h index 1f5142f35f..5852b5055e 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.h +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef CHIP_H #define CHIP_H diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.pro b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.pro deleted file mode 100644 index 8ef79cef23..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/chip.pro +++ /dev/null @@ -1,19 +0,0 @@ -RESOURCES += images.qrc - -HEADERS += mainwindow.h view.h chip.h -SOURCES += main.cpp -SOURCES += mainwindow.cpp view.cpp chip.cpp - -qtHaveModule(opengl): QT += opengl - -build_all:!build_pass { - CONFIG -= build_all - CONFIG += release -} - -# install -target.path = $$[QT_INSTALL_EXAMPLES]/graphicsview/chip -sources.files = $$SOURCES $$HEADERS $$RESOURCES *.png *.pro *.html *.doc images -sources.path = $$[QT_INSTALL_EXAMPLES]/graphicsview/chip -INSTALLS += target sources - diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/main.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/main.cpp index 53fcfa7192..e2c6a943dd 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/main.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/main.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "mainwindow.h" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.cpp index b162461403..48aa7f5d71 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "mainwindow.h" #include "view.h" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.h b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.h index b0e12b448a..aae2435a32 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.h +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef MAINWINDOW_H #define MAINWINDOW_H @@ -41,7 +16,7 @@ class MainWindow : public QWidget { Q_OBJECT public: - MainWindow(QWidget *parent = 0); + MainWindow(QWidget *parent = nullptr); private: void setupMatrix(); diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/view.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/view.cpp index 60e8dd0032..4689532eae 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/view.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/view.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "view.h" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/view.h b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/view.h index e20543858b..d3cbea87d9 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/view.h +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/view.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef VIEW_H #define VIEW_H @@ -40,7 +15,7 @@ class View : public QFrame { Q_OBJECT public: - View(const QString &name, QWidget *parent = 0); + View(const QString &name, QWidget *parent = nullptr); QGraphicsView *view() const; diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/CMakeLists.txt index 6b7867a7cb..3bbeb08350 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/CMakeLists.txt @@ -1,13 +1,14 @@ -# Generated from moveItems.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## moveItems Binary: ##################################################################### -qt_add_benchmark(moveItems +qt_internal_add_benchmark(moveItems GUI SOURCES main.cpp - PUBLIC_LIBRARIES + LIBRARIES Qt::Gui ) diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/main.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/main.cpp index 140278b8f6..f6ab1c6714 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/main.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/main.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QtGui> #include "valgrind/callgrind.h" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/moveItems.pro b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/moveItems.pro deleted file mode 100644 index 28dcadcbfa..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/moveItems.pro +++ /dev/null @@ -1 +0,0 @@ -SOURCES += main.cpp diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/CMakeLists.txt index 716fc03774..f35781b344 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/CMakeLists.txt @@ -1,13 +1,14 @@ -# Generated from scrolltest.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## scrolltest Binary: ##################################################################### -qt_add_benchmark(scrolltest +qt_internal_add_benchmark(scrolltest GUI SOURCES main.cpp - PUBLIC_LIBRARIES + LIBRARIES Qt::Gui ) diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/main.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/main.cpp index 566d16ca51..acd0b38ec1 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/main.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/main.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QtGui> #include "valgrind/callgrind.h" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/scrolltest.pro b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/scrolltest.pro deleted file mode 100644 index 28dcadcbfa..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/scrolltest.pro +++ /dev/null @@ -1 +0,0 @@ -SOURCES += main.cpp diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chip.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chip.cpp index 7eaca1e9c1..fc81c460ce 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chip.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chip.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "chip.h" @@ -97,7 +72,7 @@ void Chip::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWid // Draw text if (lod >= 2) { - QFont font("Times", 10); + QFont font(QStringList{"Times"}, 10); font.setStyleStrategy(QFont::ForceOutline); painter->setFont(font); painter->save(); diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chip.h b/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chip.h index 754dd8dfa7..ce5fb5222e 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chip.h +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chip.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef CHIP_H #define CHIP_H @@ -37,14 +12,14 @@ class Chip : public QGraphicsItem public: Chip(const QColor &color, int x, int y); - QRectF boundingRect() const; - QPainterPath shape() const; - void paint(QPainter *painter, const QStyleOptionGraphicsItem *item, QWidget *widget); + QRectF boundingRect() const override; + QPainterPath shape() const override; + void paint(QPainter *painter, const QStyleOptionGraphicsItem *item, QWidget *widget) override; protected: - void mousePressEvent(QGraphicsSceneMouseEvent *event); - void mouseMoveEvent(QGraphicsSceneMouseEvent *event); - void mouseReleaseEvent(QGraphicsSceneMouseEvent *event); + void mousePressEvent(QGraphicsSceneMouseEvent *event) override; + void mouseMoveEvent(QGraphicsSceneMouseEvent *event) override; + void mouseReleaseEvent(QGraphicsSceneMouseEvent *event) override; private: int x, y; diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chiptester.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chiptester.cpp index 6b108f7be9..d6c0b46487 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chiptester.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chiptester.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2020 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2020 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include "chiptester.h" #include "chip.h" @@ -104,7 +79,6 @@ void ChipTester::populateScene() // Populate scene int xx = 0; - int nitems = 0; for (int i = -1100; i < 1100; i += 110) { ++xx; int yy = 0; @@ -117,8 +91,6 @@ void ChipTester::populateScene() QGraphicsItem *item = new Chip(color, xx, yy); item->setPos(QPointF(i, j)); scene->addItem(item); - - ++nitems; } } } diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chiptester.h b/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chiptester.h index 467c3fb293..7be17d7144 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chiptester.h +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chiptester.h @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2020 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2020 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef CHIPTESTER_H #define CHIPTESTER_H @@ -47,15 +22,15 @@ public: ZoomInOut, Translate }; - ChipTester(QWidget *parent = 0); + ChipTester(QWidget *parent = nullptr); void setAntialias(bool enabled); void runBenchmark(); void setOperation(Operation operation); protected: - void paintEvent(QPaintEvent *event); - void timerEvent(QTimerEvent *event); + void paintEvent(QPaintEvent *event) override; + void timerEvent(QTimerEvent *event) override; private: void populateScene(); diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chiptester.pri b/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chiptester.pri deleted file mode 100644 index 105117de30..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/chiptester/chiptester.pri +++ /dev/null @@ -1,13 +0,0 @@ -SOURCES += \ - chiptester/chiptester.cpp \ - chiptester/chip.cpp - -HEADERS += \ - chiptester/chiptester.h \ - chiptester/chip.h - -RESOURCES += \ - chiptester/images.qrc - -QT += widgets -qtHaveModule(opengl): QT += opengl diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/qgraphicsview.pro b/tests/benchmarks/widgets/graphicsview/qgraphicsview/qgraphicsview.pro deleted file mode 100644 index 3d48959f3c..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/qgraphicsview.pro +++ /dev/null @@ -1,9 +0,0 @@ -QT += widgets testlib - -TEMPLATE = app -TARGET = tst_bench_qgraphicsview - -SOURCES += tst_qgraphicsview.cpp -RESOURCES += qgraphicsview.qrc - -include(chiptester/chiptester.pri) diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/qgraphicsview.qrc b/tests/benchmarks/widgets/graphicsview/qgraphicsview/qgraphicsview.qrc deleted file mode 100644 index 3681648f56..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/qgraphicsview.qrc +++ /dev/null @@ -1,9 +0,0 @@ -<!DOCTYPE RCC><RCC version="1.0"> -<qresource> - <file>images/designer.png</file> - <file>images/wine.jpeg</file> - <file>images/wine-big.jpeg</file> - <file>random.data</file> -</qresource> -</RCC> - diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp index 27f5a90bab..cefbc75e76 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <qtest.h> #include <QtCore/QDebug> @@ -68,11 +43,11 @@ public: void tryResize(int width, int height) { - QWidget *desktop = QApplication::desktop(); - if (desktop->width() < width) - width = desktop->width(); - if (desktop->height() < height) - height = desktop->height(); + const QSize desktopSize = QGuiApplication::primaryScreen()->size(); + if (desktopSize.width() < width) + width = desktopSize.width(); + if (desktopSize.height() < height) + height = desktopSize.height(); if (size() != QSize(width, height)) { resize(width, height); QTest::qWait(250); @@ -81,14 +56,14 @@ public: } protected: - void paintEvent(QPaintEvent *event) + void paintEvent(QPaintEvent *event) override { QGraphicsView::paintEvent(event); if (waiting) eventLoop.exit(); } - void timerEvent(QTimerEvent *event) + void timerEvent(QTimerEvent *event) override { if (event->timerId() == timerId) eventLoop.exit(); @@ -469,7 +444,7 @@ void tst_QGraphicsView::deepNesting() class AnimatedPixmapItem : public QGraphicsPixmapItem { public: - AnimatedPixmapItem(int x, int y, bool rot, bool scal, QGraphicsItem *parent = 0) + AnimatedPixmapItem(int x, int y, bool rot, bool scal, QGraphicsItem *parent = nullptr) : QGraphicsPixmapItem(parent), rotateFactor(0), scaleFactor(0) { rotate = rot; @@ -479,7 +454,7 @@ public: } protected: - void advance(int i) + void advance(int i) override { if (!i) return; @@ -576,7 +551,7 @@ void tst_QGraphicsView::imageRiver() class AnimatedTextItem : public QGraphicsSimpleTextItem { public: - AnimatedTextItem(int x, int y, bool rot, bool scal, QGraphicsItem *parent = 0) + AnimatedTextItem(int x, int y, bool rot, bool scal, QGraphicsItem *parent = nullptr) : QGraphicsSimpleTextItem(parent), rotateFactor(0), scaleFactor(25) { setText("River of text"); @@ -587,7 +562,7 @@ public: } protected: - void advance(int i) + void advance(int i) override { if (!i) return; @@ -686,21 +661,22 @@ void tst_QGraphicsView::textRiver() class AnimatedPixmapCacheItem : public QGraphicsPixmapItem { public: - AnimatedPixmapCacheItem(int x, int y, QGraphicsItem *parent = 0) + AnimatedPixmapCacheItem(int x, int y, QGraphicsItem *parent = nullptr) : QGraphicsPixmapItem(parent) { xspeed = x; yspeed = y; } - void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0) + void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, + QWidget *widget = 0) override { QGraphicsPixmapItem::paint(painter,option,widget); //We just want to wait, and we don't want to process the event loop with qWait QTest::qSleep(3); } protected: - void advance(int i) + void advance(int i) override { if (!i) return; @@ -787,17 +763,18 @@ void tst_QGraphicsView::moveItemCache() class UpdatedPixmapCacheItem : public QGraphicsPixmapItem { public: - UpdatedPixmapCacheItem(bool partial, QGraphicsItem *parent = 0) + UpdatedPixmapCacheItem(bool partial, QGraphicsItem *parent = nullptr) : QGraphicsPixmapItem(parent), partial(partial) { } - void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0) + void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, + QWidget *widget = 0) override { QGraphicsPixmapItem::paint(painter,option,widget); } protected: - void advance(int i) + void advance(int i) override { Q_UNUSED(i); if (partial) diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicswidget/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicswidget/CMakeLists.txt index 2646da95fc..c8d7bc0301 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicswidget/CMakeLists.txt +++ b/tests/benchmarks/widgets/graphicsview/qgraphicswidget/CMakeLists.txt @@ -1,17 +1,15 @@ -# Generated from qgraphicswidget.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## tst_bench_qgraphicswidget Binary: ##################################################################### -qt_add_benchmark(tst_bench_qgraphicswidget +qt_internal_add_benchmark(tst_bench_qgraphicswidget SOURCES tst_qgraphicswidget.cpp - PUBLIC_LIBRARIES + LIBRARIES Qt::Gui Qt::Test Qt::Widgets ) - -#### Keys ignored in scope 1:.:.:qgraphicswidget.pro:<TRUE>: -# TEMPLATE = "app" diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicswidget/qgraphicswidget.pro b/tests/benchmarks/widgets/graphicsview/qgraphicswidget/qgraphicswidget.pro deleted file mode 100644 index 00becec216..0000000000 --- a/tests/benchmarks/widgets/graphicsview/qgraphicswidget/qgraphicswidget.pro +++ /dev/null @@ -1,6 +0,0 @@ -QT += widgets testlib - -TEMPLATE = app -TARGET = tst_bench_qgraphicswidget - -SOURCES += tst_qgraphicswidget.cpp diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicswidget/tst_qgraphicswidget.cpp b/tests/benchmarks/widgets/graphicsview/qgraphicswidget/tst_qgraphicswidget.cpp index d9bc7f21b6..fb274160fa 100644 --- a/tests/benchmarks/widgets/graphicsview/qgraphicswidget/tst_qgraphicswidget.cpp +++ b/tests/benchmarks/widgets/graphicsview/qgraphicswidget/tst_qgraphicswidget.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <qtest.h> #include <QGraphicsItem> |