summaryrefslogtreecommitdiffstats
path: root/tests/manual/dialogs/utils.h
diff options
context:
space:
mode:
Diffstat (limited to 'tests/manual/dialogs/utils.h')
-rw-r--r--tests/manual/dialogs/utils.h18
1 files changed, 17 insertions, 1 deletions
diff --git a/tests/manual/dialogs/utils.h b/tests/manual/dialogs/utils.h
index 7d257eea02..3db08ce44e 100644
--- a/tests/manual/dialogs/utils.h
+++ b/tests/manual/dialogs/utils.h
@@ -1,5 +1,5 @@
// Copyright (C) 2016 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
#ifndef UTILS_H
#define UTILS_H
@@ -10,7 +10,12 @@
#include <QPair>
#include <QList>
+#include <functional>
+
QT_FORWARD_DECLARE_CLASS(QCheckBox)
+QT_FORWARD_DECLARE_CLASS(QGridLayout)
+QT_FORWARD_DECLARE_CLASS(QVBoxLayout)
+QT_FORWARD_DECLARE_CLASS(QPushButton)
// Associate enum/flag value with a description.
struct FlagData
@@ -51,4 +56,15 @@ private:
QList<CheckBoxFlagPair> m_checkBoxes;
};
+QPushButton *addButton(const QString &description, QGridLayout *layout, int &row, int column,
+ QObject *receiver, const char *slotFunc);
+
+QPushButton *addButton(const QString &description, QGridLayout *layout, int &row, int column,
+ std::function<void()> fn);
+
+QPushButton *addButton(const QString &description, QVBoxLayout *layout, QObject *receiver,
+ const char *slotFunc);
+
+QPushButton *addButton(const QString &description, QVBoxLayout *layout, std::function<void()> fn);
+
#endif // UTILS_H