blob: 9d891461b3f3cb9681711b0ad31b14458c92691d (
plain)
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
|
//===========================================
// Lumina-DE source code
// Copyright (c) 2014, Ken Moore
// Available under the 3-clause BSD license
// See the LICENSE file for full details
//===========================================
#ifdef __linux__
#include "LuminaOS.h"
#include <unistd.h>
#include <stdio.h> // Needed for BUFSIZ
// ==== ExternalDevicePaths() ====
QStringList LOS::ExternalDevicePaths(){
//Returns: QStringList[<type>::::<filesystem>::::<path>]
//Note: <type> = [USB, HDRIVE, DVD, SDCARD, UNKNOWN]
//Not implemented yet for Linux
return QStringList();
}
//Read screen brightness information
int LOS::ScreenBrightness(){
//Returns: Screen Brightness as a percentage (0-100, with -1 for errors)
return -1; //not implemented yet for Linux
}
//Set screen brightness
void LOS::setScreenBrightness(int percent){
//not implemented yet for Linux
}
//Read the current volume
int LOS::audioVolume(){ //Returns: audio volume as a percentage (0-100, with -1 for errors)
return -1; //Not implemented yet for Linux
}
//Set the current volume
void LOS::setAudioVolume(int percent){
//not implemented yet for Linux
}
//Change the current volume a set amount (+ or -)
void LOS::changeAudioVolume(int percentdiff){
//not implemented yet for Linux
}
//Check if a graphical audio mixer is installed
bool LOS::hasMixerUtility(){
return false; //not implemented yet for Linux
}
//Launch the graphical audio mixer utility
void LOS::startMixerUtility(){
//not implemented yet for Linux
}
//System Shutdown
void LOS::systemShutdown(){ //start poweroff sequence
QProcess::startDetached("shutdown -h now");
}
//System Restart
void LOS::systemRestart(){ //start reboot sequence
QProcess::startDetached("shutdown -r now");
}
//Battery Availability
bool LOS::hasBattery(){
return false; //not implemented yet for Linux
}
//Battery Charge Level
int LOS::batteryCharge(){ //Returns: percent charge (0-100), anything outside that range is counted as an error
return -1; //not implemented yet for Linux
}
//Battery Charging State
bool LOS::batteryIsCharging(){
return false; //not implemented yet for Linux
}
//Battery Time Remaining
int LOS::batterySecondsLeft(){ //Returns: estimated number of seconds remaining
return 0; //not implemented yet for Linux
}
#endif
|