-
Notifications
You must be signed in to change notification settings - Fork 356
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Mostly implemented menu navigation, config change storage, and reboot…
… events
- Loading branch information
1 parent
c199b9e
commit 582bbe5
Showing
20 changed files
with
452 additions
and
95 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#ifndef _GPMENUNAVIGATEEVENT_H_ | ||
#define _GPMENUNAVIGATEEVENT_H_ | ||
|
||
#include "system.h" | ||
|
||
class GPMenuNavigateEvent : public GPEvent { | ||
public: | ||
GPMenuNavigateEvent() {} | ||
GPMenuNavigateEvent(GpioAction action) { | ||
this->menuAction = action; | ||
} | ||
~GPMenuNavigateEvent() {} | ||
|
||
GPEventType eventType() { return this->_eventType; } | ||
|
||
GpioAction menuAction; | ||
private: | ||
GPEventType _eventType = GP_EVENT_MENU_NAVIGATE; | ||
}; | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#ifndef _GPSTORAGESAVEEVENT_H_ | ||
#define _GPSTORAGESAVEEVENT_H_ | ||
|
||
#include "system.h" | ||
|
||
class GPStorageSaveEvent : public GPEvent { | ||
public: | ||
GPStorageSaveEvent() {} | ||
GPStorageSaveEvent(bool force, bool restart = false) { | ||
this->forceSave = force; | ||
this->restartAfterSave = restart; | ||
} | ||
~GPStorageSaveEvent() {} | ||
|
||
GPEventType eventType() { return this->_eventType; } | ||
|
||
bool forceSave = false; | ||
bool restartAfterSave = false; | ||
private: | ||
GPEventType _eventType = GP_EVENT_STORAGE_SAVE; | ||
}; | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#ifndef _GPSYSTEMREBOOTEVENT_H_ | ||
#define _GPSYSTEMREBOOTEVENT_H_ | ||
|
||
#include "system.h" | ||
|
||
class GPSystemRebootEvent : public GPEvent { | ||
public: | ||
GPSystemRebootEvent() {} | ||
GPSystemRebootEvent(System::BootMode mode) { | ||
this->bootMode = mode; | ||
} | ||
~GPSystemRebootEvent() {} | ||
|
||
GPEventType eventType() { return this->_eventType; } | ||
|
||
System::BootMode bootMode = System::BootMode::DEFAULT; | ||
private: | ||
GPEventType _eventType = GP_EVENT_SYSTEM_REBOOT; | ||
}; | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.