Mercurial > minori
annotate include/core/time.h @ 266:1a6a5d3a94cd
dep/animone: make bsd.cc and x11.cc actually work
apparently I broke these, and even now the x11 code *still* doesn't want
to work correctly (at least on FreeBSD). half of the PID response codes
are just 0 or the PID for the X server itself... wtf?
maybe dwm just doesn't support the XRes extension, or I'm just stupid.
i don't know.
| author | Paper <paper@paper.us.eu.org> |
|---|---|
| date | Thu, 11 Apr 2024 22:05:41 -0400 |
| parents | 3ec7804abf17 |
| children | 91ac90a34003 |
| rev | line source |
|---|---|
|
261
3ec7804abf17
include: make header guards more sane
Paper <paper@paper.us.eu.org>
parents:
258
diff
changeset
|
1 #ifndef MINORI_CORE_TIME_H_ |
|
3ec7804abf17
include: make header guards more sane
Paper <paper@paper.us.eu.org>
parents:
258
diff
changeset
|
2 #define MINORI_CORE_TIME_H_ |
| 85 | 3 |
| 9 | 4 #include <cstdint> |
| 5 #include <string> | |
| 6 namespace Time { | |
| 7 | |
| 8 class Duration { | |
| 258 | 9 public: |
| 10 Duration(int64_t l); | |
| 11 int64_t InSeconds(); | |
| 12 int64_t InMinutes(); | |
| 13 int64_t InHours(); | |
| 14 int64_t InDays(); | |
| 15 std::string AsRelativeString(); | |
| 9 | 16 |
| 258 | 17 private: |
| 18 int64_t length; | |
| 9 | 19 }; |
| 20 | |
| 21 int64_t GetSystemTime(); | |
| 22 | |
| 85 | 23 }; // namespace Time |
| 24 | |
|
261
3ec7804abf17
include: make header guards more sane
Paper <paper@paper.us.eu.org>
parents:
258
diff
changeset
|
25 #endif // MINORI_CORE_TIME_H_ |
