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
qdbusmenuconnection_p.h
Go to the documentation of this file.
1// Copyright (C) 2020 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 QDBUSMENUCONNECTION_H
6#define QDBUSMENUCONNECTION_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
19#include <QtCore/QString>
20#include <QtDBus/QDBusConnection>
21#include <QtDBus/QDBusVariant>
22
23#include <QtGui/qtgui-config.h>
24#include <QtCore/private/qglobal_p.h>
25Q_MOC_INCLUDE(<QtDBus/QDBusError>)
26
27QT_BEGIN_NAMESPACE
28
29class QDBusServiceWatcher;
30#ifndef QT_NO_SYSTEMTRAYICON
31class QDBusTrayIcon;
32#endif // QT_NO_SYSTEMTRAYICON
33
35{
37
38public:
41 QDBusConnection connection() const { return m_connection; }
42 QDBusServiceWatcher *dbusWatcher() const { return m_dbusWatcher; }
43 bool isWatcherRegistered() const { return m_watcherRegistered; }
44#ifndef QT_NO_SYSTEMTRAYICON
50#endif // QT_NO_SYSTEMTRAYICON
51
53#ifndef QT_NO_SYSTEMTRAYICON
55#endif // QT_NO_SYSTEMTRAYICON
56
57private Q_SLOTS:
58 void dbusError(const QDBusError &error);
59
60private:
61 QString m_serviceName;
62 QDBusConnection m_connection;
63 QDBusServiceWatcher *m_dbusWatcher;
64 bool m_watcherRegistered;
65};
66
67QT_END_NAMESPACE
68
69#endif // QDBUSMENUCONNECTION_H
bool registerTrayIconMenu(QDBusTrayIcon *item)
bool registerTrayIcon(QDBusTrayIcon *item)
QDBusServiceWatcher * dbusWatcher() const
void unregisterTrayIconMenu(QDBusTrayIcon *item)
void unregisterTrayIcon(QDBusTrayIcon *item)
bool registerTrayIconWithWatcher(QDBusTrayIcon *item)
QDBusConnection connection() const