X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Flib%2Fimplementations%2FCECCommandHandler.cpp;h=05f5606b93b50fd5032a13e6a63fc7f766f5bc39;hb=7b01619d3e08506efea013b3bd34b0148803a120;hp=46edf983c39e0ef71a6a1ac88a9c599c8fda9b04;hpb=880f082e02a4d031ce226e7182a1c93c6e4e9652;p=deb_libcec.git diff --git a/src/lib/implementations/CECCommandHandler.cpp b/src/lib/implementations/CECCommandHandler.cpp index 46edf98..05f5606 100644 --- a/src/lib/implementations/CECCommandHandler.cpp +++ b/src/lib/implementations/CECCommandHandler.cpp @@ -1121,10 +1121,15 @@ bool CCECCommandHandler::ActivateSource(bool bTransmitDelayedCommandsOnly /* = f // update the power state and menu state m_busDevice->SetPowerStatus(CEC_POWER_STATUS_ON); - m_busDevice->SetMenuState(CEC_MENU_STATE_ACTIVATED); // TODO: LG + m_busDevice->SetMenuState(CEC_MENU_STATE_ACTIVATED); + + // vendor specific hook + VendorPreActivateSourceHook(); // power on the TV - bool bActiveSourceFailed = !m_busDevice->TransmitImageViewOn(); + bool bActiveSourceFailed(false); + if (m_processor->GetDevice(CECDEVICE_TV)->GetPowerStatus(m_busDevice->GetLogicalAddress()) != CEC_POWER_STATUS_ON) + bActiveSourceFailed = !m_busDevice->TransmitImageViewOn(); // check if we're allowed to switch sources bool bSourceSwitchAllowed = SourceSwitchAllowed();