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
qcocoasessionmanager.h
Go to the documentation of this file.
1// Copyright (C) 2019 Samuel Gaist <samuel.gaist@idiap.ch>
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 QCOCOASESSIONMANAGER_H
6#define QCOCOASESSIONMANAGER_H
7
8//
9// W A R N I N G
10// -------------
11//
12// This file is part of the QPA API and is not meant to be used
13// in applications. Usage of this API may make your code
14// source and binary incompatible with future versions of Qt.
15//
16
17#ifndef QT_NO_SESSIONMANAGER
18
19#include <qpa/qplatformsessionmanager.h>
20
21QT_BEGIN_NAMESPACE
22
23class QCocoaSessionManager : public QPlatformSessionManager
24{
25public:
26 QCocoaSessionManager(const QString &id, const QString &key);
27 virtual ~QCocoaSessionManager();
28
29 bool allowsInteraction() override;
30 void cancel() override;
31 void resetCancellation();
32 bool wasCanceled() const;
33
34 static QCocoaSessionManager *instance();
35
36private:
37 bool m_canceled;
38
39 Q_DISABLE_COPY(QCocoaSessionManager)
40};
41
42QT_END_NAMESPACE
43
44#endif // QT_NO_SESSIONMANAGER
45
46#endif // QCOCOASESSIONMANAGER_H