aboutsummaryrefslogtreecommitdiff
path: root/src/Ryujinx.Horizon/Sdk/Settings/System/SleepSettings.cs
blob: 7493c677cab44f7ab7c849c5fcafe1d12edf1af9 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
using System;
using System.Runtime.InteropServices;

namespace Ryujinx.Horizon.Sdk.Settings.System
{
    [Flags]
    enum SleepFlag : uint
    {
        SleepsWhilePlayingMedia = 1 << 0,
        WakesAtPowerStateChange = 1 << 1,
    }

    enum HandheldSleepPlan : uint
    {
        At1Min,
        At3Min,
        At5Min,
        At10Min,
        At30Min,
        Never,
    }

    enum ConsoleSleepPlan : uint
    {
        At1Hour,
        At2Hour,
        At3Hour,
        At6Hour,
        At12Hour,
        Never,
    }

    [StructLayout(LayoutKind.Sequential, Size = 0xC, Pack = 0x4)]
    struct SleepSettings
    {
        public SleepFlag Flags;
        public HandheldSleepPlan HandheldSleepPlan;
        public ConsoleSleepPlan ConsoleSleepPlan;
    }
}