diff options
-rw-r--r-- | .gitmodules | 4 | ||||
-rw-r--r-- | src/kpowersave.cpp | 11 |
2 files changed, 9 insertions, 6 deletions
diff --git a/.gitmodules b/.gitmodules index 4fce771..5a9a136 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,6 +1,6 @@ [submodule "admin"] path = admin - url = http://[email protected]/scm/git/tde-common-admin + url = http://scm.trinitydesktop.org/scm/git/tde-common-admin [submodule "cmake"] path = cmake - url = http://[email protected]/scm/git/tde-common-cmake + url = http://scm.trinitydesktop.org/scm/git/tde-common-cmake diff --git a/src/kpowersave.cpp b/src/kpowersave.cpp index d6d98c2..b372245 100644 --- a/src/kpowersave.cpp +++ b/src/kpowersave.cpp @@ -361,10 +361,11 @@ void kpowersave::loadIcon(bool forceReload){ if ((pixmap_name_tmp != pixmap_name) || (forceReload)) { pixmap_name = pixmap_name_tmp; if (pixmap_name.startsWith("ERROR")) { - pixmap = SmallIcon("laptoppower", width(), TDEIcon::DisabledState); + pixmap = SmallIcon("laptoppower", isShown() ? width() : 22, TDEIcon::DisabledState); + } + else { + pixmap = SmallIcon(pixmap_name, isShown() ? width() : 22); } - else - pixmap = SmallIcon(pixmap_name, width()); } kdDebugFuncOut(trace); @@ -435,7 +436,9 @@ void kpowersave::drawIcon(){ } } quit: - image = image.smoothScale(width(), height()); + if (isShown()) { + image = image.smoothScale(width(), height()); + } fullIcon.convertFromImage(image); setPixmap(fullIcon); |