NotificationManager.h: Reorder notification struct fields to allow easier creation. (#1774)

This commit changes the order for the notification struct fields to allow the creation of notifications using a string literal.
```cpp
NotificationManager::Notifiation notification {
  "String literal with notification text",
  42,
  NotificationManager::Categories::SimpleAlert
};
```

Co-authored-by: minacode <minamoto9@web.de>
This commit is contained in:
Max Friedrich 2023-07-09 14:39:38 +02:00 committed by GitHub
parent 5f3acfadd2
commit 39d5b5c3a2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -27,11 +27,12 @@ namespace Pinetime {
struct Notification {
using Id = uint8_t;
using Idx = uint8_t;
std::array<char, MessageSize + 1> message;
uint8_t size;
Categories category = Categories::Unknown;
Id id = 0;
bool valid = false;
uint8_t size;
std::array<char, MessageSize + 1> message;
Categories category = Categories::Unknown;
const char* Message() const;
const char* Title() const;