Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qcocoamessagedialog.h
Go to the documentation of this file.
1// Copyright (C) 2022 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
4#ifndef QCOCOAMESSAGEDIALOG_H
5#define QCOCOAMESSAGEDIALOG_H
6
7#include <qpa/qplatformdialoghelper.h>
8
10typedef long NSInteger;
12
14
15class QEventLoop;
16
18{
19public:
22
23 void exec() override;
24 bool show(Qt::WindowFlags windowFlags, Qt::WindowModality windowModality, QWindow *parent) override;
25 void hide() override;
26
27private:
28 Qt::WindowModality modality() const;
29 NSAlert *m_alert = nullptr;
30 QEventLoop *m_eventLoop = nullptr;
31 NSModalResponse runModal() const;
32 void processResponse(NSModalResponse response);
33};
34
36
37#endif // QCOCOAMESSAGEDIALOG_H
38
QCocoaMessageDialog()=default
\inmodule QtCore
Definition qeventloop.h:16
QObject * parent() const
Returns a pointer to the parent object.
Definition qobject.h:346
The QPlatformMessageDialogHelper class allows for platform-specific customization of Message dialogs.
\inmodule QtGui
Definition qwindow.h:63
Combined button and popup list for selecting options.
WindowModality
long NSInteger
NSInteger NSModalResponse
#define Q_FORWARD_DECLARE_OBJC_CLASS(classname)
view show()
[18] //! [19]