aboutsummaryrefslogtreecommitdiff
path: root/multimedia/plexhometheater/files/patch-libcec22
diff options
context:
space:
mode:
Diffstat (limited to 'multimedia/plexhometheater/files/patch-libcec22')
-rw-r--r--multimedia/plexhometheater/files/patch-libcec2252
1 files changed, 52 insertions, 0 deletions
diff --git a/multimedia/plexhometheater/files/patch-libcec22 b/multimedia/plexhometheater/files/patch-libcec22
new file mode 100644
index 000000000000..1473f9ac7016
--- /dev/null
+++ b/multimedia/plexhometheater/files/patch-libcec22
@@ -0,0 +1,52 @@
+Origin: https://github.com/xbmc/xbmc/pull/5610
+
+--- system/peripherals.xml.orig 2014-08-25 20:29:00.000000000 +0800
++++ system/peripherals.xml 2014-12-31 07:15:34.972922137 +0800
+@@ -28,7 +28,7 @@
+ <setting key="device_type" type="int" value="1" configurable="0" />
+ <setting key="wake_devices_advanced" type="string" value="" configurable="0" />
+ <setting key="standby_devices_advanced" type="string" value="" configurable="0" />
+- <setting key="double_tap_timeout_ms" type="int" min="0" value="2000" configurable="0" />
++ <setting key="double_tap_timeout_ms" type="int" min="0" value="300" configurable="0" />
+ </peripheral>
+
+ <peripheral vendor_product="2548:1001,2548:1002" bus="usb" name="Pulse-Eight CEC Adapter" mapTo="cec">
+--- xbmc/peripherals/bus/virtual/PeripheralBusCEC.cpp.orig 2014-08-25 20:29:00.000000000 +0800
++++ xbmc/peripherals/bus/virtual/PeripheralBusCEC.cpp 2014-12-31 07:15:34.976923956 +0800
+@@ -101,6 +101,8 @@
+ break;
+ case ADAPTERTYPE_RPI:
+ result.m_mappedBusType = PERIPHERAL_BUS_RPI;
++ // the Pi's adapter cannot be removed, no need to rescan
++ m_bNeedsPolling = false;
+ break;
+ default:
+ break;
+--- xbmc/peripherals/devices/PeripheralCecAdapter.cpp.orig 2014-08-25 20:29:00.000000000 +0800
++++ xbmc/peripherals/devices/PeripheralCecAdapter.cpp 2014-12-31 07:15:34.986923118 +0800
+@@ -1302,8 +1302,8 @@
+
+ void CPeripheralCecAdapter::SetConfigurationFromSettings(void)
+ {
+- // use the same client version as libCEC version
+- m_configuration.clientVersion = CEC_CLIENT_VERSION_CURRENT;
++ // client version matches the version of libCEC that we originally used the API from
++ m_configuration.clientVersion = CEC_CLIENT_VERSION_2_2_0;
+
+ // device name 'XBMC'
+ snprintf(m_configuration.strDeviceName, 13, "%s", GetSettingString("device_name").c_str());
+@@ -1378,8 +1378,13 @@
+ m_configuration.bPowerOffOnStandby = iStandbyAction == 13011 ? 1 : 0;
+ m_configuration.bShutdownOnStandby = iStandbyAction == 13005 ? 1 : 0;
+
+- // double tap prevention timeout in ms
++#if defined(CEC_DOUBLE_TAP_TIMEOUT_MS_OLD)
++ // double tap prevention timeout in ms. libCEC uses 50ms units for this in 2.2.0, so divide by 50
++ m_configuration.iDoubleTapTimeout50Ms = GetSettingInt("double_tap_timeout_ms") / 50;
++#else
++ // backwards compatibility. will be removed once the next major release of libCEC is out
+ m_configuration.iDoubleTapTimeoutMs = GetSettingInt("double_tap_timeout_ms");
++#endif
+ }
+
+ void CPeripheralCecAdapter::ReadLogicalAddresses(const CStdString &strString, cec_logical_addresses &addresses)