Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qquicklabsplatformmessagedialog_p.h
Go to the documentation of this file.
1// Copyright (C) 2017 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3// Qt-Security score:significant reason:default
4
5#ifndef QQUICKLABSPLATFORMMESSAGEDIALOG_P_H
6#define QQUICKLABSPLATFORMMESSAGEDIALOG_P_H
7
8//
9// W A R N I N G
10// -------------
11//
12// This file is not part of the Qt API. It exists purely as an
13// implementation detail. This header file may change from version to
14// version without notice, or even be removed.
15//
16// We mean it.
17//
18
20#include <QtQml/qqml.h>
21
22#if QT_DEPRECATED_SINCE(6, 9)
23
24QT_BEGIN_NAMESPACE
25
26class QQuickLabsPlatformMessageDialog : public QQuickLabsPlatformDialog
27{
28 Q_OBJECT
29 QML_NAMED_ELEMENT(MessageDialog)
30 QML_ADDED_IN_VERSION(1, 0)
31 Q_PROPERTY(QString text READ text WRITE setText NOTIFY textChanged FINAL)
32 Q_PROPERTY(QString informativeText READ informativeText WRITE setInformativeText NOTIFY informativeTextChanged FINAL)
33 Q_PROPERTY(QString detailedText READ detailedText WRITE setDetailedText NOTIFY detailedTextChanged FINAL)
34 Q_PROPERTY(QPlatformDialogHelper::StandardButtons buttons READ buttons WRITE setButtons NOTIFY buttonsChanged FINAL)
35 QML_EXTENDED_NAMESPACE(QPlatformDialogHelper)
36
37public:
38 explicit QQuickLabsPlatformMessageDialog(QObject *parent = nullptr);
39
40 QString text() const;
41 void setText(const QString &text);
42
43 QString informativeText() const;
44 void setInformativeText(const QString &text);
45
46 QString detailedText() const;
47 void setDetailedText(const QString &text);
48
49 QPlatformDialogHelper::StandardButtons buttons() const;
50 void setButtons(QPlatformDialogHelper::StandardButtons buttons);
51
52Q_SIGNALS:
53 void textChanged();
54 void informativeTextChanged();
55 void detailedTextChanged();
56 void buttonsChanged();
57 void clicked(QPlatformDialogHelper::StandardButton button);
58
59 void okClicked();
60 void saveClicked();
61 void saveAllClicked();
62 void openClicked();
63 void yesClicked();
64 void yesToAllClicked();
65 void noClicked();
66 void noToAllClicked();
67 void abortClicked();
68 void retryClicked();
69 void ignoreClicked();
70 void closeClicked();
71 void cancelClicked();
72 void discardClicked();
73 void helpClicked();
74 void applyClicked();
75 void resetClicked();
76 void restoreDefaultsClicked();
77
78protected:
79 void onCreate(QPlatformDialogHelper *dialog) override;
80 void onShow(QPlatformDialogHelper *dialog) override;
81
82private Q_SLOTS:
83 void handleClick(QPlatformDialogHelper::StandardButton button);
84
85private:
86 QSharedPointer<QMessageDialogOptions> m_options;
87};
88
89QT_END_NAMESPACE
90
91#endif // QT_DEPRECATED_SINCE(6, 9)
92
93#endif // QQUICKLABSPLATFORMMESSAGEDIALOG_P_H