| 1 |
/* |
| 2 |
* TriggerSelector.h |
| 3 |
* |
| 4 |
* Created on: 14 Mar 2017 |
| 5 |
* Author: jeremy |
| 6 |
*/ |
| 7 |
|
| 8 |
#ifndef SOURCE_WIDGETS_TRIGGERSELECTOR_H_ |
| 9 |
#define SOURCE_WIDGETS_TRIGGERSELECTOR_H_ |
| 10 |
|
| 11 |
#include <gtkmm/grid.h> |
| 12 |
#include <gtkmm/label.h> |
| 13 |
#include <gtkmm/button.h> |
| 14 |
|
| 15 |
#include <memory> |
| 16 |
#include <string> |
| 17 |
|
| 18 |
namespace Widgets |
| 19 |
{ |
| 20 |
|
| 21 |
class TriggerSelector : public Gtk::Grid |
| 22 |
{ |
| 23 |
|
| 24 |
public: |
| 25 |
|
| 26 |
explicit TriggerSelector(int sensorId); |
| 27 |
virtual ~TriggerSelector() = default; |
| 28 |
|
| 29 |
|
| 30 |
int GetSensorId() const noexcept { return sensorId; } |
| 31 |
Gtk::Button& GetPreferencesButton() { return preferencesButton; } |
| 32 |
Gtk::Button& GetDeleteButton() { return deleteButton; } |
| 33 |
|
| 34 |
|
| 35 |
private: |
| 36 |
|
| 37 |
int sensorId; |
| 38 |
Gtk::Label label; |
| 39 |
Gtk::Button preferencesButton; |
| 40 |
Gtk::Button deleteButton; |
| 41 |
|
| 42 |
}; |
| 43 |
|
| 44 |
|
| 45 |
typedef std::shared_ptr<TriggerSelector> TriggerSelectorPtr; |
| 46 |
|
| 47 |
} /* namespace Widgets */ |
| 48 |
|
| 49 |
#endif /* SOURCE_WIDGETS_TRIGGERSELECTOR_H_ */ |