| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
#pragma once |
| 5 |
|
| 6 |
#include <string> |
| 7 |
|
| 8 |
#include "Common/CommonTypes.h" |
| 9 |
#include "Common/HookableEvent.h" |
| 10 |
|
| 11 |
struct WindowSystemInfo; |
| 12 |
|
| 13 |
namespace UICommon |
| 14 |
{ |
| 15 |
void Init(); |
| 16 |
void Shutdown(); |
| 17 |
|
| 18 |
|
| 19 |
[[nodiscard]] Common::EventHook AddFlushUnsavedDataCallback(std::function<void()> callback); |
| 20 |
void FlushUnsavedData(); |
| 21 |
|
| 22 |
void InitControllers(const WindowSystemInfo& wsi); |
| 23 |
void ShutdownControllers(); |
| 24 |
|
| 25 |
void InhibitScreenSaver(bool inhibit); |
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
void SetLocale(std::string locale_name); |
| 30 |
|
| 31 |
void CreateDirectories(); |
| 32 |
void SetUserDirectory(std::string custom_path); |
| 33 |
|
| 34 |
bool TriggerSTMPowerEvent(); |
| 35 |
|
| 36 |
|
| 37 |
|
| 38 |
std::string FormatSize(u64 bytes, int decimals = 2); |
| 39 |
} |