aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/Process.hpp14
-rw-r--r--include/gui/Button.hpp3
2 files changed, 17 insertions, 0 deletions
diff --git a/include/Process.hpp b/include/Process.hpp
new file mode 100644
index 0000000..a41b9a0
--- /dev/null
+++ b/include/Process.hpp
@@ -0,0 +1,14 @@
+#pragma once
+
+namespace gsr {
+ enum class GsrMode {
+ Replay,
+ Record,
+ Stream,
+ Unknown
+ };
+
+ // Arguments ending with NULL
+ bool exec_program_daemonized(const char **args);
+ bool is_gpu_screen_recorder_running(int &gsr_pid, GsrMode &mode);
+} \ No newline at end of file
diff --git a/include/gui/Button.hpp b/include/gui/Button.hpp
index ac9aa5c..145d869 100644
--- a/include/gui/Button.hpp
+++ b/include/gui/Button.hpp
@@ -2,6 +2,7 @@
#include "Widget.hpp"
#include <string>
+#include <functional>
namespace gsr {
class Button : public Widget {
@@ -9,6 +10,8 @@ namespace gsr {
Button(mgl::vec2f size);
void on_event(mgl::Event &event, mgl::Window &window) override;
void draw(mgl::Window &window) override;
+
+ std::function<void()> on_click;
private:
mgl::vec2f size;
bool mouse_inside = false;