TDE 0.1.0
 
Loading...
Searching...
No Matches
launcher.hpp
Go to the documentation of this file.
1
12#pragma once
13
14#include <qobject.h>
15#include <qprocess.h>
16
17#include "tde/app/info.hpp"
18#include "tde/common.hpp"
19
20namespace tde::app {
21
26class TDE_PUBLIC Launcher : public QObject
27{
28 Q_OBJECT
29
30public:
36 explicit Launcher(QObject* parent = nullptr)
37 : QObject{ parent }
38 {
39 }
40
41 ~Launcher() override = default;
42
48 void launch(const Info& app);
49
50signals:
56 void before_app_start(const Info& app);
57
64 void after_app_finish(int code, QProcess::ExitStatus status);
65
66public slots:
72 void on_request_launch_app(const Info& app);
73
74private slots:
81 void _on_app_finish(int code, QProcess::ExitStatus status);
82};
83
84}
Application launcher.
Definition launcher.hpp:27
void after_app_finish(int code, QProcess::ExitStatus status)
Emitted after the application is finished.
Launcher(QObject *parent=nullptr)
Construct a new Launcher object.
Definition launcher.hpp:36
void before_app_start(const Info &app)
Emitted before the application is launched.
Some utility macros.
Application information.
Application information.
Definition info.hpp:23