mirror of
https://github.com/Sani7/remote-ui.git
synced 2026-10-26 21:51:13 +01:00
simulator base
adds stop
This commit is contained in:
@@ -29,6 +29,11 @@ UI_item* SimulatorBase::get_UI_item(std::string id) const {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void SimulatorBase::run() {
|
void SimulatorBase::run() {
|
||||||
// Run the simulator
|
// Start the timer
|
||||||
p_timer.setInterval(std::chrono::milliseconds(100));
|
p_timer.setInterval(std::chrono::milliseconds(100));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void SimulatorBase::stop() {
|
||||||
|
// Stop the simulator
|
||||||
|
p_timer.stop();
|
||||||
|
}
|
||||||
@@ -14,6 +14,7 @@ class SimulatorBase {
|
|||||||
UI_item* get_UI_item(std::string id) const;
|
UI_item* get_UI_item(std::string id) const;
|
||||||
|
|
||||||
void run();
|
void run();
|
||||||
|
void stop();
|
||||||
|
|
||||||
virtual void timer() {};
|
virtual void timer() {};
|
||||||
protected:
|
protected:
|
||||||
|
|||||||
Reference in New Issue
Block a user