added WIP support for energy units and current units
[qbat.git] / common.h
blobe88937f233f0f01fc9a8867b99285c434b19dbe9
1 //
2 // C++ Interface: common
3 //
4 // Author: Oliver Groß <z.o.gross@gmx.de>, (C) 2008
5 //
6 // Copyright: See COPYING file that comes with this distribution
7 //
8 #ifndef QBAT_COMMON_H
9 #define QBAT_COMMON_H
11 #include <string>
12 #include <QColor>
13 #include "constants.h"
15 namespace qbat {
16 struct Settings {
17 quint16 pollingRate;
18 bool mergeBatterys;
19 bool handleCritical;
20 quint8 criticalCapacity;
21 bool executeCommand;
22 QString criticalCommand;
23 QRgb colors[UI_COUNT_COLORS];
24 bool showBalloon;
25 /* QRgb textColor;
26 QRgb mainEmptyColor;
27 QRgb mainChargedColor;
28 QRgb poleColor;
29 QRgb textFullColor;
30 QRgb mainFullColor;
31 QRgb poleFullColor;*/
34 std::string readStringSysFile(const char * fileName);
35 int readIntSysFile(const char * fileName);
36 int toStatusInt(std::string status);
39 #endif