repositories
/
deb_libcec.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1969b14
)
cec: send a keypress with 0 duration when a key is pressed and with a duration set...
author
Lars Op den Kamp
<lars@opdenkamp.eu>
Fri, 14 Oct 2011 14:17:08 +0000
(16:17 +0200)
committer
Lars Op den Kamp
<lars@opdenkamp.eu>
Fri, 14 Oct 2011 14:17:08 +0000
(16:17 +0200)
src/lib/LibCEC.cpp
patch
|
blob
|
blame
|
history
diff --git
a/src/lib/LibCEC.cpp
b/src/lib/LibCEC.cpp
index a1f2650f4198305561ae6943b33c449dce7bc47d..7c0f7927956126f088a9bb5ec443f9c04ebe086b 100644
(file)
--- a/
src/lib/LibCEC.cpp
+++ b/
src/lib/LibCEC.cpp
@@
-251,6
+251,13
@@
void CLibCEC::SetCurrentButton(cec_user_control_code iButtonCode)
{
m_iCurrentButton = iButtonCode;
m_buttontime = GetTimeMs();
+
+ /* push keypress to the keybuffer with 0 duration.
+ push another press to the keybuffer with the duration set when the button is released */
+ cec_keypress key;
+ key.duration = 0;
+ key.keycode = m_iCurrentButton;
+ m_keyBuffer.Push(key);
}
void * CECCreate(const char *strDeviceName, CEC::cec_logical_address iLogicalAddress /*= CEC::CECDEVICE_PLAYBACKDEVICE1 */, uint16_t iPhysicalAddress /* = CEC_DEFAULT_PHYSICAL_ADDRESS */)