mirror of
https://github.com/clockworkpi/LauncherGoDev.git
synced 2025-12-12 16:08:52 +01:00
41 lines
865 B
Go
41 lines
865 B
Go
package sysgo
|
|
|
|
type PowerLevel struct {
|
|
Dim int
|
|
Close int
|
|
PowerOff int
|
|
}
|
|
|
|
var PowerLevels map[string]*PowerLevel
|
|
|
|
var (
|
|
CurKeySet = "GameShell" // PC or GameShell
|
|
DontLeave = false
|
|
BackLight = "/proc/driver/backlight"
|
|
Battery = "/sys/class/power_supply/axp20x-battery/uevent"
|
|
MPD_socket = "/tmp/mpd.socket"
|
|
|
|
UPDATE_URL="https://raw.githubusercontent.com/cuu/CPI/master/launchergo_ver.json"
|
|
|
|
VERSION="0.22"
|
|
|
|
SKIN="default"
|
|
|
|
//load from dot files
|
|
CurPowerLevel= "performance"
|
|
Lang = "English"
|
|
|
|
)
|
|
|
|
|
|
|
|
func init() {
|
|
if PowerLevels == nil {
|
|
PowerLevels = make(map[string]*PowerLevel)
|
|
PowerLevels["supersaving"] = &PowerLevel{10, 30, 120}
|
|
PowerLevels["powersaving"] = &PowerLevel{40, 120, 300}
|
|
PowerLevels["server"] = &PowerLevel{40, 120, 0 }
|
|
PowerLevels["performance"] = &PowerLevel{40, 0, 0 }
|
|
}
|
|
}
|