init
Some checks failed
Docker. / Ubuntu (push) Has been cancelled
User-agent updater. / User-agent (push) Failing after 15s
Lock Threads / lock (push) Failing after 10s
Waiting for answer. / waiting-for-answer (push) Failing after 22s
Needs user action. / needs-user-action (push) Failing after 8s
Can't reproduce. / cant-reproduce (push) Failing after 8s
Close stale issues and PRs / stale (push) Has been cancelled
Some checks failed
Docker. / Ubuntu (push) Has been cancelled
User-agent updater. / User-agent (push) Failing after 15s
Lock Threads / lock (push) Failing after 10s
Waiting for answer. / waiting-for-answer (push) Failing after 22s
Needs user action. / needs-user-action (push) Failing after 8s
Can't reproduce. / cant-reproduce (push) Failing after 8s
Close stale issues and PRs / stale (push) Has been cancelled
This commit is contained in:
54
Telegram/ThirdParty/fcitx5-qt/qt6/dbusaddons/fcitxqtwatcher.h
vendored
Normal file
54
Telegram/ThirdParty/fcitx5-qt/qt6/dbusaddons/fcitxqtwatcher.h
vendored
Normal file
@@ -0,0 +1,54 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: 2012~2017 CSSlayer <wengxt@gmail.com>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef _DBUSADDONS_FCITXQTWATCHER_H_
|
||||
#define _DBUSADDONS_FCITXQTWATCHER_H_
|
||||
|
||||
#include "fcitx5qt6dbusaddons_export.h"
|
||||
|
||||
#include <QDBusConnection>
|
||||
#include <QObject>
|
||||
|
||||
namespace fcitx {
|
||||
|
||||
class FcitxQtWatcherPrivate;
|
||||
|
||||
class FCITX5QT6DBUSADDONS_EXPORT FcitxQtWatcher : public QObject {
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit FcitxQtWatcher(QObject *parent = nullptr);
|
||||
explicit FcitxQtWatcher(const QDBusConnection &connection,
|
||||
QObject *parent = nullptr);
|
||||
~FcitxQtWatcher();
|
||||
void watch();
|
||||
void unwatch();
|
||||
void setConnection(const QDBusConnection &connection);
|
||||
QDBusConnection connection() const;
|
||||
void setWatchPortal(bool portal);
|
||||
bool watchPortal() const;
|
||||
bool isWatching() const;
|
||||
bool availability() const;
|
||||
|
||||
QString serviceName() const;
|
||||
|
||||
Q_SIGNALS:
|
||||
void availabilityChanged(bool);
|
||||
|
||||
private Q_SLOTS:
|
||||
void imChanged(const QString &service, const QString &oldOwner,
|
||||
const QString &newOwner);
|
||||
|
||||
private:
|
||||
void setAvailability(bool availability);
|
||||
void updateAvailability();
|
||||
|
||||
FcitxQtWatcherPrivate *const d_ptr;
|
||||
Q_DECLARE_PRIVATE(FcitxQtWatcher);
|
||||
};
|
||||
} // namespace fcitx
|
||||
|
||||
#endif // _DBUSADDONS_FCITXQTWATCHER_H_
|
||||
Reference in New Issue
Block a user