mirror of
https://repo.dec05eba.com/gpu-screen-recorder-ui
synced 2026-05-06 06:50:44 +09:00
Start/stop recording if not running/already running
This commit is contained in:
14
include/Process.hpp
Normal file
14
include/Process.hpp
Normal file
@@ -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);
|
||||
}
|
||||
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user