repositories
/
deb_libcec.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
LG: newer firmwares don't send a second power status request after it's been requeste...
[deb_libcec.git]
/
src
/
lib
/
implementations
/
SLCommandHandler.cpp
diff --git
a/src/lib/implementations/SLCommandHandler.cpp
b/src/lib/implementations/SLCommandHandler.cpp
index 7c9579d8ea6b24254af43679ef656562f04d89c9..73a27f5e63cd2b3a6f6c63dc6b79b187e84f0308 100644
(file)
--- a/
src/lib/implementations/SLCommandHandler.cpp
+++ b/
src/lib/implementations/SLCommandHandler.cpp
@@
-1,7
+1,7
@@
/*
* This file is part of the libCEC(R) library.
*
/*
* This file is part of the libCEC(R) library.
*
- * libCEC(R) is Copyright (C) 2011-201
2
Pulse-Eight Limited. All rights reserved.
+ * libCEC(R) is Copyright (C) 2011-201
3
Pulse-Eight Limited. All rights reserved.
* libCEC(R) is an original work, containing original code.
*
* libCEC(R) is a trademark of Pulse-Eight Limited.
* libCEC(R) is an original work, containing original code.
*
* libCEC(R) is a trademark of Pulse-Eight Limited.
@@
-86,6
+86,9
@@
bool CSLCommandHandler::InitHandler(void)
return true;
m_bHandlerInited = true;
return true;
m_bHandlerInited = true;
+ if (m_busDevice->GetLogicalAddress() != CECDEVICE_TV)
+ return true;
+
CCECBusDevice *primary = m_processor->GetPrimaryDevice();
if (primary && primary->GetLogicalAddress() != CECDEVICE_UNREGISTERED)
{
CCECBusDevice *primary = m_processor->GetPrimaryDevice();
if (primary && primary->GetLogicalAddress() != CECDEVICE_UNREGISTERED)
{
@@
-191,6
+194,10
@@
void CSLCommandHandler::HandleVendorCommand01(const cec_command &command)
{
m_processor->GetPrimaryDevice()->SetPowerStatus(CEC_POWER_STATUS_IN_TRANSITION_STANDBY_TO_ON);
TransmitVendorCommand0205(command.destination, command.initiator);
{
m_processor->GetPrimaryDevice()->SetPowerStatus(CEC_POWER_STATUS_IN_TRANSITION_STANDBY_TO_ON);
TransmitVendorCommand0205(command.destination, command.initiator);
+
+ CCECBusDevice* dev = m_processor->GetDevice(command.destination);
+ if (dev && dev->IsHandledByLibCEC() && dev->IsActiveSource())
+ dev->TransmitActiveSource(false);
}
void CSLCommandHandler::TransmitVendorCommand0205(const cec_logical_address iSource, const cec_logical_address iDestination)
}
void CSLCommandHandler::TransmitVendorCommand0205(const cec_logical_address iSource, const cec_logical_address iDestination)
@@
-201,6
+208,7
@@
void CSLCommandHandler::TransmitVendorCommand0205(const cec_logical_address iSou
response.PushBack(SL_COMMAND_TYPE_HDDRECORDER);
Transmit(response, false, true);
response.PushBack(SL_COMMAND_TYPE_HDDRECORDER);
Transmit(response, false, true);
+ SetSLInitialised();
}
void CSLCommandHandler::HandleVendorCommandPowerOn(const cec_command &command)
}
void CSLCommandHandler::HandleVendorCommandPowerOn(const cec_command &command)
@@
-224,6
+232,8
@@
void CSLCommandHandler::HandleVendorCommandPowerOn(const cec_command &command)
CLockObject lock(m_SLMutex);
m_bActiveSourceSent = false;
}
CLockObject lock(m_SLMutex);
m_bActiveSourceSent = false;
}
+ if (device->IsActiveSource())
+ ActivateSource();
}
}
void CSLCommandHandler::HandleVendorCommandPowerOnStatus(const cec_command &command)
}
}
void CSLCommandHandler::HandleVendorCommandPowerOnStatus(const cec_command &command)
@@
-400,7
+410,7
@@
bool CSLCommandHandler::PowerOn(const cec_logical_address iInitiator, const cec_
cec_command command;
if (!m_bSLEnabled)
cec_command command;
if (!m_bSLEnabled)
- TransmitVendorID(CECDEVICE_TV, CEC_VENDOR_LG, false);
+ TransmitVendorID(CECDEVICE_TV,
iDestination,
CEC_VENDOR_LG, false);
cec_command::Format(command, CECDEVICE_TV, iDestination, CEC_OPCODE_VENDOR_COMMAND);
command.PushBack(SL_COMMAND_POWER_ON);
cec_command::Format(command, CECDEVICE_TV, iDestination, CEC_OPCODE_VENDOR_COMMAND);
command.PushBack(SL_COMMAND_POWER_ON);