From 72689600b9622fd55a53d9a95b8af42823d00356 Mon Sep 17 00:00:00 2001 From: Lars Op den Kamp Date: Fri, 9 Dec 2011 12:36:04 +0100 Subject: [PATCH] cec: fixed - transmit an active source message when the stream path has been set to a device that is handled by libcec --- src/lib/implementations/CECCommandHandler.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/lib/implementations/CECCommandHandler.cpp b/src/lib/implementations/CECCommandHandler.cpp index 57233fd..11d550c 100644 --- a/src/lib/implementations/CECCommandHandler.cpp +++ b/src/lib/implementations/CECCommandHandler.cpp @@ -463,6 +463,14 @@ bool CCECCommandHandler::HandleSetStreamPath(const cec_command &command) CStdString strLog; strLog.Format(">> %i sets stream path to physical address %04x", command.initiator, iStreamAddress); m_busDevice->AddLog(CEC_LOG_DEBUG, strLog.c_str()); + + /* one of the device handled by libCEC has been made active */ + CCECBusDevice *device = GetDeviceByPhysicalAddress(iStreamAddress); + if (device && m_busDevice->MyLogicalAddressContains(device->GetLogicalAddress())) + { + device->SetActiveSource(); + device->TransmitActiveSource(); + } } return false; } -- 2.34.1