Pogger/src/Preferences.h

51 lines
788 B
C
Raw Normal View History

2020-12-30 22:07:54 -06:00
/*
* Copyright 2020, Jaidyn Levesque <jadedctrl@teknik.io>
* All rights reserved. Distributed under the terms of the MIT license.
*/
2021-01-24 23:20:11 -06:00
#ifndef PREFS_H
#define PREFS_H
2020-07-03 19:13:41 -05:00
2020-12-30 22:07:54 -06:00
2020-07-07 17:42:12 -05:00
#include <DateTime.h>
#include <String.h>
2020-07-03 19:13:41 -05:00
#include <StorageKit.h>
2020-12-30 22:07:54 -06:00
2021-01-25 19:39:31 -06:00
const int64 HOUR_IN_MICROSECONDS = 3600000000;
2021-01-24 23:20:11 -06:00
class Preferences {
2020-07-03 19:13:41 -05:00
public:
2021-01-24 23:20:11 -06:00
Preferences();
Preferences(Preferences*);
2020-12-30 22:07:54 -06:00
void Load();
void Save();
2021-01-25 19:39:31 -06:00
int64 UpdateInterval();
int UpdateIntervalIndex();
void SetUpdateIntervalIndex(int8 index);
bool NotifyOnFailure();
bool NotifyOnNew();
void SetNotifyOnFailure(bool value);
void SetNotifyOnNew(bool value);
2021-01-25 19:39:31 -06:00
BString fEntryDir;
BString fEntryFileExt;
bool fOpenAsHtml;
BString fOpenWith;
2020-07-07 17:42:12 -05:00
2021-01-25 19:39:31 -06:00
private:
int8 fUpdateInterval;
2020-07-07 20:17:52 -05:00
2021-01-25 19:39:31 -06:00
bool fNewNotify;
bool fFailureNotify;
2020-07-03 19:13:41 -05:00
};
2020-12-30 22:07:54 -06:00
2021-01-24 23:20:11 -06:00
#endif // PREFS_H
2020-12-30 22:07:54 -06:00