Skip to content

Commit 1dae139

Browse files
committed
RDKEMW-1061: RDK-E Add COMRPC
Reason for change: Create the interface file for HdmiCecSource Test Procedure: Risks: low Priority: P1 Signed-off-by:Hayden Gfeller [email protected]
1 parent 0cd3685 commit 1dae139

File tree

2 files changed

+10
-8
lines changed

2 files changed

+10
-8
lines changed

HdmiCecSource/HdmiCecSourceImplementation.cpp

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -572,7 +572,9 @@ namespace WPEFramework
572572
uint32_t HdmiCecSourceImplementation::sendKeyPressEvent(const int logicalAddress, int keyCode)
573573
{
574574
if(!(_instance->smConnection))
575+
{
575576
return Core::ERROR_GENERAL;
577+
}
576578
LOGINFO(" SendKeyPressEvent logicalAddress 0x%x keycode 0x%x\n",logicalAddress,keyCode);
577579
switch(keyCode)
578580
{
@@ -1281,7 +1283,7 @@ namespace WPEFramework
12811283
}
12821284
}
12831285

1284-
uint32_t HdmiCecSourceImplementation::getDeviceList (IHdmiCecSource::IHdmiCecSourceDeviceListIterator *&deviceList)
1286+
uint32_t HdmiCecSourceImplementation::getDeviceList (IHdmiCecSource::IHdmiCecSourceDeviceListIterator *&deviceList, bool &success /* @out */)
12851287
{ //sample servicemanager response:
12861288
LOGINFOMETHOD();
12871289
std::vector<Exchange::HdmiCecSourceDevices> localDevices;
@@ -1290,7 +1292,7 @@ namespace WPEFramework
12901292
//Trigger CEC device poll here
12911293
pthread_cond_signal(&(_instance->m_condSig));
12921294

1293-
bool success = true;
1295+
success = true;
12941296
LOGINFO("getDeviceListWrapper m_numberOfDevices :%d \n", HdmiCecSourceImplementation::_instance->m_numberOfDevices);
12951297
try
12961298
{
@@ -1310,7 +1312,7 @@ namespace WPEFramework
13101312
success = false;
13111313
}
13121314
deviceList = (Core::Service<RPC::IteratorType<Exchange::IHdmiCecSource::IHdmiCecSourceDeviceListIterator>>::Create<Exchange::IHdmiCecSource::IHdmiCecSourceDeviceListIterator>(localDevices));
1313-
returnResponse(success);
1315+
return Core::ERROR_NONE;
13141316
}
13151317

13161318
bool HdmiCecSourceImplementation::pingDeviceUpdateList (int idev)
@@ -1603,7 +1605,7 @@ namespace WPEFramework
16031605
{
16041606
std::list<Exchange::IHdmiCecSource::INotification*>::const_iterator index(_hdmiCecSourceNotifications.begin());
16051607
while (index != _hdmiCecSourceNotifications.end()) {
1606-
(*index)->OnKeyReleaseMsgReceived(logicalAddress);
1608+
(*index)->SendKeyReleaseMsgEvent(logicalAddress);
16071609
index++;
16081610
}
16091611
}
@@ -1612,7 +1614,7 @@ namespace WPEFramework
16121614
{
16131615
std::list<Exchange::IHdmiCecSource::INotification*>::const_iterator index(_hdmiCecSourceNotifications.begin());
16141616
while (index != _hdmiCecSourceNotifications.end()) {
1615-
(*index)->OnKeyPressMsgReceived(logicalAddress,keyCode);
1617+
(*index)->SendKeyPressMsgEvent(logicalAddress,keyCode);
16161618
index++;
16171619
}
16181620
}

HdmiCecSource/HdmiCecSourceImplementation.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ namespace WPEFramework {
221221
int keyCode;
222222
}SendKeyInfo;
223223
BEGIN_INTERFACE_MAP(HdmiCecSourceImplementation)
224-
INTERFACE_ENTRY(Exchange::IAuthService)
224+
INTERFACE_ENTRY(Exchange::IHdmiCecSource)
225225
END_INTERFACE_MAP
226226

227227

@@ -327,10 +327,10 @@ namespace WPEFramework {
327327
uint32_t GetVendorId(string &vendorid, bool &success);
328328
uint32_t PerformOTPAction(bool &success);
329329
uint32_t SendStandbyMessage(bool &success);
330-
uint32_t SendKeyPressEvent(const int &logicalAddress, int keyCode, bool &success);
330+
uint32_t SendKeyPressEvent(const int &logicalAddress, int &keyCode, bool &success);
331331
uint32_t GetActiveSourceStatus(bool &isActiveSource, bool &success);
332332
uint32_t GetDeviceList(Exchange::IHdmiCecSource::IHdmiCecSourceDeviceListIterator*& deviceList, bool &success);
333-
uint32_t Configure(PluginHost::IShell*) override;
333+
uint32_t Configure(PluginHost::IShell* service) override;
334334
uint32_t Register(IHdmiCecSource::INotification *notification) override;
335335
uint32_t Unregister(IHdmiCecSource::INotification *notification) override;
336336

0 commit comments

Comments
 (0)