return bReturn;
if (!m_logicalAddresses.empty() && m_busDevices[m_logicalAddresses.primary])
- {
- SetStreamPath(m_busDevices[m_logicalAddresses.primary]->GetPhysicalAddress());
- bReturn = m_busDevices[m_logicalAddresses.primary]->TransmitActiveSource();
- }
- return false;
+ bReturn = SetStreamPath(m_busDevices[m_logicalAddresses.primary]->GetPhysicalAddress());
+
+ return bReturn;
}
bool CCECProcessor::SetStreamPath(uint16_t iStreamPath)
{
+ bool bReturn(false);
+
CCECBusDevice *device = GetDeviceByPhysicalAddress(iStreamPath);
if (device)
{
m_busDevices[iPtr]->m_bActiveSource = false;
device->m_bActiveSource = true;
- return true;
+
+ if (m_logicalAddresses.isset(device->m_iLogicalAddress))
+ bReturn = device->TransmitActiveSource();
+ else
+ bReturn = true;
}
- return false;
+ return bReturn;
}
bool CCECProcessor::SetInactiveView(void)
{
int streamaddr = ((uint16_t)command.parameters[0] << 8) | ((uint16_t)command.parameters[1]);
CStdString strLog;
- strLog.Format(">> %i requests stream path from physical address %04x", command.initiator, streamaddr);
+ strLog.Format(">> %i sets stream path to physical address %04x", command.initiator, streamaddr);
m_busDevice->AddLog(CEC_LOG_DEBUG, strLog.c_str());
- CCECBusDevice *device = GetDeviceByPhysicalAddress(streamaddr);
- if (device)
- return device->TransmitActiveSource();
+
+ return m_busDevice->GetProcessor()->SetStreamPath(streamaddr);
}
return true;
}