
Lithium Power Manager
Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net
Lithium is a power manager application that lives in the system tray. It is designed to be similar to KPowersave and guidance-power-manager.
REQUIREMENTS:
Cmake v2.4+
KDE 4.X
On (K)Ubuntu install:
libxss-dev
libxcb-dpms0-dev
kdebase-workspace-dev
On Gentoo:
libXScrnSaver
libxcb
INSTALLING:
Extract the tarball
$ cd li-0.1.1
$ cmake .
$ make
# make install
12 years ago
v0.1.1:
* Added DPMS Support
* Added Presentation and Acoustic Power schemes
* Changed config dialog
* Added Battery details dialog when left clicking on the system tray icon.
12 years ago
v0.1.1:
* Added DPMS Support
* Added Presentation and Acoustic Power schemes
* Changed config dialog
* Added Battery details dialog when left clicking on the system tray icon.
Beno1
12 years ago
Report
Hamburger1984
12 years ago
Second: a request - could you incorporate some disk power management features? (goal: reducing spin down cycles for laptop-hdds)
http://en.opensuse.org/Disk_Power_Management
Thanks and keep up the good work!
Andreas
Report
manik
11 years ago
--manik
Report
google01103
12 years ago
Report
duanmaotu
12 years ago
one problem:
there's no idle action for selection, it only shows "no action". Did I miss some depencies?
Report
Rebelyouth
12 years ago
I compiled the new KDE 4 Power Management package “Lithium” for Kubuntu Hardy x86.
Visit me !!!
http://rebelyouth.wordpress.com
Report
google01103
12 years ago
Report
jaem
12 years ago
Report
explinux83
12 years ago
Regard
Report
friendly-demon
12 years ago
Report
chapter78
12 years ago
Report
kevin79
12 years ago
Quote:[ 16%] Generating ui_config.h
Generating lithium.moc
Scanning dependencies of target li
[ 33%] Building CXX object CMakeFiles/li.dir/li_automoc.o
[ 50%] Building CXX object CMakeFiles/li.dir/lithium.o
In file included from /home/kevin/plasmoids/li/lithium.cpp:46:
/home/kevin/plasmoids/li/lithium.h:24:40: error: solid/control/powermanager.h: No such file or directory
In file included from /home/kevin/plasmoids/li/lithium.cpp:48:
/home/kevin/plasmoids/li/powerscheme.h:129:7: warning: no newline at end of file
/home/kevin/plasmoids/li/lithium.cpp:330:40: error: kworkspace/kdisplaymanager.h: No such file or directory
/home/kevin/plasmoids/li/lithium.cpp:333:2: warning: #warning Replace this hack after KRunner is fixed
In file included from /home/kevin/plasmoids/li/lithium.cpp:46:
/home/kevin/plasmoids/li/lithium.h:26: error: ‘Solid::Control’ has not been declared
/home/kevin/plasmoids/li/lithium.h:26: error: ‘PowerManager’ is not a namespace-name
/home/kevin/plasmoids/li/lithium.h:26: error: expected namespace-name before ‘;’ token
/home/kevin/plasmoids/li/lithium.h:81: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.h:81: error: expected ‘,’ or ‘...’ before ‘method’
/home/kevin/plasmoids/li/lithium.h: In member function ‘int Lithium::brightness() const’:
/home/kevin/plasmoids/li/lithium.h:57: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.h: In member function ‘void Lithium::setBrightness(int)’:
/home/kevin/plasmoids/li/lithium.h:74: error: ‘PM’ has not been declared
In file included from /home/kevin/plasmoids/li/lithium.cpp:48:
/home/kevin/plasmoids/li/powerscheme.h: At global scope:
/home/kevin/plasmoids/li/powerscheme.h:27: error: ‘Solid::Control’ has not been declared
/home/kevin/plasmoids/li/powerscheme.h:27: error: ‘PowerManager’ is not a namespace-name
/home/kevin/plasmoids/li/powerscheme.h:27: error: expected namespace-name before ‘;’ token
/home/kevin/plasmoids/li/powerscheme.h:45: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/powerscheme.h:45: error: ISO C++ forbids declaration of ‘SuspendMethod’ with no type
/home/kevin/plasmoids/li/powerscheme.h:45: error: expected ‘;’ before ‘autoSuspendMethod’
/home/kevin/plasmoids/li/powerscheme.h:46: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/powerscheme.h:46: error: expected ‘,’ or ‘...’ before ‘method’
/home/kevin/plasmoids/li/powerscheme.h:110: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/powerscheme.h:110: error: ISO C++ forbids declaration of ‘CpuFreqPolicy’ with no type
/home/kevin/plasmoids/li/powerscheme.h:110: error: expected ‘;’ before ‘cpuFreqPolicy’
/home/kevin/plasmoids/li/powerscheme.h:111: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/powerscheme.h:111: error: expected ‘,’ or ‘...’ before ‘policy’
/home/kevin/plasmoids/li/powerscheme.h:121: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/powerscheme.h:121: error: ISO C++ forbids declaration of ‘CpuFreqPolicy’ with no type
/home/kevin/plasmoids/li/powerscheme.h:121: error: expected ‘;’ before ‘m_policy’
/home/kevin/plasmoids/li/powerscheme.h:122: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/powerscheme.h:122: error: ISO C++ forbids declaration of ‘SuspendMethod’ with no type
/home/kevin/plasmoids/li/powerscheme.h:122: error: expected ‘;’ before ‘m_suspendMethod’
/home/kevin/plasmoids/li/lithium.cpp: In constructor ‘PowerInfoTooltip::PowerInfoTooltip(QSystemTrayIcon*)’:
/home/kevin/plasmoids/li/lithium.cpp:67: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:67: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp: In member function ‘void PowerInfoTooltip::addBatteryInfo(QWidget*, QBoxLayout*)’:
/home/kevin/plasmoids/li/lithium.cpp:145: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:147: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:147: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:148: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp: In constructor ‘Lithium::Lithium(KAboutData*)’:
/home/kevin/plasmoids/li/lithium.cpp:245: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:245: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:246: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:247: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:248: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp: In member function ‘void Lithium::detectedActivity()’:
/home/kevin/plasmoids/li/lithium.cpp:316: warning: unused variable ‘scheme’
/home/kevin/plasmoids/li/lithium.cpp: In member function ‘void Lithium::checkIdle()’:
/home/kevin/plasmoids/li/lithium.cpp:378: error: ‘class PowerScheme’ has no member named ‘autoSuspendMethod’
/home/kevin/plasmoids/li/lithium.cpp:384: error: ‘class PowerScheme’ has no member named ‘autoSuspendMethod’
/home/kevin/plasmoids/li/lithium.cpp: In member function ‘void Lithium::initSchemes()’:
/home/kevin/plasmoids/li/lithium.cpp:422: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:423: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:423: error: expected `;' before ‘method’
/home/kevin/plasmoids/li/lithium.cpp:424: error: ‘method’ was not declared in this scope
/home/kevin/plasmoids/li/lithium.cpp:427: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:428: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:428: error: expected `;' before ‘policy’
/home/kevin/plasmoids/li/lithium.cpp:429: error: ‘policy’ was not declared in this scope
/home/kevin/plasmoids/li/lithium.cpp:442: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:443: error: expected type-specifier before ‘PM’
/home/kevin/plasmoids/li/lithium.cpp:443: error: expected `>' before ‘PM’
/home/kevin/plasmoids/li/lithium.cpp:443: error: expected `(' before ‘PM’
/home/kevin/plasmoids/li/lithium.cpp:443: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:443: error: expected `)' before ‘;’ token
/home/kevin/plasmoids/li/lithium.cpp:451: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:452: error: expected type-specifier before ‘PM’
/home/kevin/plasmoids/li/lithium.cpp:452: error: expected `>' before ‘PM’
/home/kevin/plasmoids/li/lithium.cpp:452: error: expected `(' before ‘PM’
/home/kevin/plasmoids/li/lithium.cpp:452: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:452: error: expected `)' before ‘;’ token
/home/kevin/plasmoids/li/lithium.cpp: In member function ‘void Lithium::initContextMenu()’:
/home/kevin/plasmoids/li/lithium.cpp:468: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:468: error: expected `;' before ‘sMethods’
/home/kevin/plasmoids/li/lithium.cpp:470: error: ‘PM’ was not declared in this scope
/home/kevin/plasmoids/li/lithium.cpp:470: error: template argument 1 is invalid
/home/kevin/plasmoids/li/lithium.cpp:470: error: invalid type in declaration before ‘;’ token
/home/kevin/plasmoids/li/lithium.cpp:471: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:472: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:473: error: ‘PM’ is not a class or namespace
/usr/include/qt4/QtCore/qglobal.h: At global scope:
/usr/include/qt4/QtCore/qglobal.h: In instantiation of ‘QForeachContainer<int>’:
/home/kevin/plasmoids/li/lithium.cpp:477: instantiated from here
/usr/include/qt4/QtCore/qglobal.h:1977: error: ‘int’ is not a class, struct, or union type
/usr/include/qt4/QtCore/qglobal.h:1977: error: ‘int’ is not a class, struct, or union type
/home/kevin/plasmoids/li/lithium.cpp: In member function ‘void Lithium::initContextMenu()’:
/home/kevin/plasmoids/li/lithium.cpp:477: error: ‘class QForeachContainer<int>’ has no member named ‘i’
/home/kevin/plasmoids/li/lithium.cpp:477: error: ‘class QForeachContainer<int>’ has no member named ‘e’
/home/kevin/plasmoids/li/lithium.cpp:477: error: ‘class QForeachContainer<int>’ has no member named ‘i’
/home/kevin/plasmoids/li/lithium.cpp:477: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:477: error: expected `;' before ‘method’
/home/kevin/plasmoids/li/lithium.cpp:478: error: ‘sMethods’ was not declared in this scope
/home/kevin/plasmoids/li/lithium.cpp:478: error: ‘method’ was not declared in this scope
/home/kevin/plasmoids/li/lithium.cpp:483: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:487: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:491: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:495: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:510: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:510: error: expected `;' before ‘current’
/home/kevin/plasmoids/li/lithium.cpp:511: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:511: error: expected `;' before ‘policies’
/home/kevin/plasmoids/li/lithium.cpp:513: error: ‘PM’ cannot appear in a constant-expression
/home/kevin/plasmoids/li/lithium.cpp:513: error: template argument 1 is invalid
/home/kevin/plasmoids/li/lithium.cpp:513: error: invalid type in declaration before ‘;’ token
/home/kevin/plasmoids/li/lithium.cpp:514: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:515: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:516: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:517: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:518: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:522: error: ‘class QForeachContainer<int>’ has no member named ‘i’
/home/kevin/plasmoids/li/lithium.cpp:522: error: ‘class QForeachContainer<int>’ has no member named ‘e’
/home/kevin/plasmoids/li/lithium.cpp:522: error: ‘class QForeachContainer<int>’ has no member named ‘i’
/home/kevin/plasmoids/li/lithium.cpp:522: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:522: error: expected `;' before ‘policy’
/home/kevin/plasmoids/li/lithium.cpp:523: error: ‘policies’ was not declared in this scope
/home/kevin/plasmoids/li/lithium.cpp:523: error: ‘policy’ was not declared in this scope
/home/kevin/plasmoids/li/lithium.cpp:528: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:531: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:534: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:537: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:540: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:543: error: ‘PM’ is not a class or namespace
/home/kevin/plasmoids/li/lithium.cpp:549: error: ‘current’ was not declared in this scope
/home/kevin/plasmoids/li/lithium.cpp: In member function ‘void Lithium::setCpuFreq(QAction*)’:
/home/kevin/plasmoids/li/lithium.cpp:604: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:604: error: expected `;' before ‘policy’
/home/kevin/plasmoids/li/lithium.cpp:605: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:605: error: ‘policy’ was not declared in this scope
/home/kevin/plasmoids/li/lithium.cpp: At global scope:
/home/kevin/plasmoids/li/lithium.cpp:602: warning: unused parameter ‘action’
/home/kevin/plasmoids/li/lithium.cpp: In member function ‘void Lithium::setPowerScheme(PowerScheme*)’:
/home/kevin/plasmoids/li/lithium.cpp:618: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:620: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:622: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:652: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:652: error: ‘class PowerScheme’ has no member named ‘cpuFreqPolicy’
/home/kevin/plasmoids/li/lithium.cpp:654: error: ‘class PowerScheme’ has no member named ‘cpuFreqPolicy’
/home/kevin/plasmoids/li/lithium.cpp: In member function ‘void Lithium::suspend(QAction*)’:
/home/kevin/plasmoids/li/lithium.cpp:663: error: ‘PM’ has not been declared
/home/kevin/plasmoids/li/lithium.cpp:663: error: expected `;' before ‘method’
/home/kevin/plasmoids/li/lithium.cpp:664: error: ‘method’ was not declared in this scope
/home/kevin/plasmoids/li/lithium.cpp: At global scope:
/home/kevin/plasmoids/li/lithium.cpp:661: warning: unused parameter ‘action’
/home/kevin/plasmoids/li/lithium.cpp:667: error: variable or field ‘suspend’ declared void
/home/kevin/plasmoids/li/lithium.cpp:667: error: ‘PM’ has not been declared
In file included from /home/kevin/plasmoids/li/lithium.cpp:983:
/usr/include/qt4/QtCore/qglobal.h: In constructor ‘QForeachContainer<T>::QForeachContainer(const T&) [with T = int]’:
/home/kevin/plasmoids/li/lithium.cpp:477: instantiated from here
/usr/include/qt4/QtCore/qglobal.h:1974: error: using invalid field ‘QForeachContainer<T>::i’
/usr/include/qt4/QtCore/qglobal.h:1974: error: request for member ‘begin’ in ‘((QForeachContainer<int>*)this)->QForeachContainer<int>::c’, which is of non-class type ‘const int’
/usr/include/qt4/QtCore/qglobal.h:1974: error: using invalid field ‘QForeachContainer<T>::e’
/usr/include/qt4/QtCore/qglobal.h:1974: error: request for member ‘end’ in ‘((QForeachContainer<int>*)this)->QForeachContainer<int>::c’, which is of non-class type ‘const int’
make[2]: *** [CMakeFiles/li.dir/lithium.o] Error 1
make[1]: *** [CMakeFiles/li.dir/all] Error 2
make: *** [all] Error 2
Report
dilettante
12 years ago
Report
Mar91
12 years ago
Report
Fall
12 years ago
Get it at http://aur.archlinux.org/packages.php?ID=19054 or via yaourt.
Enjoy :-)
Report
f3lip3
12 years ago
I have a similar application, but in very aplha state, if you interesting see this link http://kde-apps.org/content/show.php/PowerManager?content=86544&PHPSESSID=fc1baacc336fd1ed36d9297d5cb9e844. Now I wanted to make a plasmoid for my application.
Report
dilettante
12 years ago
Report
f3lip3
12 years ago
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
X11_Xscreensaver_LIB (ADVANCED)
Maybe X11_Xscreensaver_LIB should be written in uppercase? I try this and cmake works but make show me this error:
CMakeFiles/li.dir/lithium.o: In function `Lithium::checkIdle()':
/home/f3lip3/apps/li/lithium.cpp:347: undefined reference to `XScreenSaverAllocInfo'
/home/f3lip3/apps/li/lithium.cpp:348: undefined reference to `XScreenSaverQueryInfo'
collect2: ld returned 1 exit status
make[2]: *** [li] Error 1
make[1]: *** [CMakeFiles/li.dir/all] Error 2
make: *** [all] Error 2
I try to add #include <X11/extensions/scrnsaver.h> but I got many errors.
Report
dilettante
12 years ago
On Gentoo this is provided by libXScrnSaver. I'm looking for the corresponding debian package. What distro are you using?
Report
dilettante
12 years ago
Report
KopfEnton
12 years ago
Report
dilettante
12 years ago
Report