rev 16487 - in trunk/packages/kdebase-workspace/debian: . patches
Xavier Vello
wdgt-guest at alioth.debian.org
Sat Dec 26 18:20:59 UTC 2009
Author: wdgt-guest
Date: 2009-12-26 18:20:58 +0000 (Sat, 26 Dec 2009)
New Revision: 16487
Modified:
trunk/packages/kdebase-workspace/debian/changelog
trunk/packages/kdebase-workspace/debian/patches/90_work_with_hal_0.5.14_svn_r1062504.diff
Log:
Hopefully fix the issue with hal for people with no software backlight.
Only tested that it doesn't break things for me and I can't reproduce
the issue.
Modified: trunk/packages/kdebase-workspace/debian/changelog
===================================================================
--- trunk/packages/kdebase-workspace/debian/changelog 2009-12-26 05:29:52 UTC (rev 16486)
+++ trunk/packages/kdebase-workspace/debian/changelog 2009-12-26 18:20:58 UTC (rev 16487)
@@ -1,3 +1,9 @@
+kdebase-workspace (4:4.3.4-3) unstable; urgency=high
+
+ * Backport parts of r1035622/r1057980 to fix 90_work_with_hal_0.5.14_svn_r1062504.diff
+
+ -- Xavier Vello <xavier.vello at gmail.com> Sat, 26 Dec 2009 17:22:05 +0100
+
kdebase-workspace (4:4.3.4-2) unstable; urgency=high
[ Modestas Vainius ]
Modified: trunk/packages/kdebase-workspace/debian/patches/90_work_with_hal_0.5.14_svn_r1062504.diff
===================================================================
--- trunk/packages/kdebase-workspace/debian/patches/90_work_with_hal_0.5.14_svn_r1062504.diff 2009-12-26 05:29:52 UTC (rev 16486)
+++ trunk/packages/kdebase-workspace/debian/patches/90_work_with_hal_0.5.14_svn_r1062504.diff 2009-12-26 18:20:58 UTC (rev 16487)
@@ -1,5 +1,5 @@
---- a/libs/solid/control/powermanager.cpp 2009/12/14 22:57:55 1062503
-+++ b/libs/solid/control/powermanager.cpp 2009/12/14 23:02:52 1062504
+--- a/libs/solid/control/powermanager.cpp
++++ b/libs/solid/control/powermanager.cpp
@@ -196,7 +196,7 @@
else
{
@@ -8,4 +8,46 @@
+ false, brightness(controls.keys(Solid::Control::PowerManager::Screen).at(0)));
}
}
- else
\ No newline at end of file
+ else
+--- a/solid/hal/halpower.cpp
++++ b/solid/hal/halpower.cpp
+@@ -375,7 +375,8 @@
+ float HalPower::brightness(const QString &device)
+ {
+ float brightness;
+- if(m_halManager.call("FindDeviceByCapability", "laptop_panel").arguments().at(0).toStringList().contains(device))
++ QDBusReply<QStringList> reply = m_halManager.call("FindDeviceByCapability", "laptop_panel");
++ if(reply.isValid() && reply.value().contains(device))
+ {
+ QDBusInterface deviceInterface("org.freedesktop.Hal", device, "org.freedesktop.Hal.Device.LaptopPanel", QDBusConnection::systemBus());
+ brightness = deviceInterface.call("GetBrightness").arguments().at(0).toDouble();
+@@ -390,7 +391,8 @@
+ return (float)(100*(brightness/(levels-1)));
+ }
+ }
+- if(m_halManager.call("FindDeviceByCapability", "keyboard_backlight").arguments().at(0).toStringList().contains(device))
++ reply = m_halManager.call("FindDeviceByCapability", "keyboard_backlight");
++ if(reply.isValid() && reply.value().contains(device))
+ {
+ QDBusInterface deviceInterface("org.freedesktop.Hal", device, "org.freedesktop.Hal.Device.KeyboardBacklight", QDBusConnection::systemBus()); //TODO - I do not have a backlight enabled keyboard, so I'm guessing a bit here. Could someone please check this.
+ brightness = deviceInterface.call("GetBrightness").arguments().at(0).toDouble();
+@@ -410,7 +412,8 @@
+
+ bool HalPower::setBrightness(float brightness, const QString &device)
+ {
+- if(m_halManager.call("FindDeviceByCapability", "laptop_panel").arguments().at(0).toStringList().contains(device))
++ QDBusReply<QStringList> reply = m_halManager.call("FindDeviceByCapability", "laptop_panel");
++ if(reply.isValid() && reply.value().contains(device))
+ {
+ QDBusInterface propertyInterface("org.freedesktop.Hal", device, "org.freedesktop.Hal.Device", QDBusConnection::systemBus());
+ int levels = propertyInterface.call("GetProperty", "laptop_panel.num_levels").arguments().at(0).toInt();
+@@ -422,7 +425,8 @@
+ return true;
+ }
+ }
+- if(m_halManager.call("FindDeviceByCapability", "keyboard_backlight").arguments().at(0).toStringList().contains(device))
++ reply = m_halManager.call("FindDeviceByCapability", "keyboard_backlight");
++ if(reply.isValid() && reply.value().contains(device))
+ {
+ QDBusInterface propertyInterface("org.freedesktop.Hal", device, "org.freedesktop.Hal.Device", QDBusConnection::systemBus());
+ int levels = propertyInterface.call("GetProperty", "keyboard_backlight.num_levels").arguments().at(0).toInt();
More information about the pkg-kde-commits
mailing list