summaryrefslogtreecommitdiffstats
path: root/applauncher/AppLauncherClient.h
blob: 91723abedf351070c0242f7b8351a2e6002185bd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
// SPDX-License-Identifier: Apache-2.0
/*
 * Copyright (C) 2022 Konsulko Group
 */

#ifndef APPLAUNCHER_CLIENT_H
#define APPLAUNCHER_CLIENT_H

#include <QObject>
#include <QList>
#include <QMap>

class AppLauncherGrpcClient;

class AppLauncherClient : public QObject
{
	Q_OBJECT

public:
	explicit AppLauncherClient(QObject *parent = Q_NULLPTR);
	virtual ~AppLauncherClient();

	Q_INVOKABLE bool startApplication(const QString &id);
	Q_INVOKABLE bool listApplications(QList<QMap<QString, QString>> &list);

public slots:
	void sendStatusEvent(const QString &id, const QString &status);

signals:
	void appStatusEvent(const QString &id, const QString &status);

private:
	AppLauncherGrpcClient *m_launcher;
};

#endif // APPLAUNCHER_CLIENT_H