X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Flib%2Fimplementations%2FCECCommandHandler.cpp;h=5a2afb17143d9d95314de110a2068f1f95cc7ba1;hb=d3caa81bbff5c84e49cdc9c4c1de5d0b583eb45d;hp=3b0187a1c3edbc1ef6560143bc2cd652470d5b84;hpb=e4e827e620365d043ef94da8874d942f80aefb9b;p=deb_libcec.git diff --git a/src/lib/implementations/CECCommandHandler.cpp b/src/lib/implementations/CECCommandHandler.cpp index 3b0187a..5a2afb1 100644 --- a/src/lib/implementations/CECCommandHandler.cpp +++ b/src/lib/implementations/CECCommandHandler.cpp @@ -209,12 +209,13 @@ int CCECCommandHandler::HandleActiveSource(const cec_command &command) if (command.parameters.size == 2) { uint16_t iAddress = ((uint16_t)command.parameters[0] << 8) | ((uint16_t)command.parameters[1]); + m_processor->GetDevices()->SetActiveSource(iAddress); CCECBusDevice *device = m_processor->GetDeviceByPhysicalAddress(iAddress); if (device) - { device->MarkAsActiveSource(); - return COMMAND_HANDLED; - } + + m_processor->GetDevices()->SignalAll(command.opcode); + return COMMAND_HANDLED; } return CEC_ABORT_REASON_INVALID_OPERAND;