cec: split up CEC processing and the public interface. removed obsolete methods from...
[deb_libcec.git] / src / lib / AdapterDetection.cpp
similarity index 97%
rename from src/lib/CECDetect.cpp
rename to src/lib/AdapterDetection.cpp
index a8aa7e1cd531c29adbfb94572f8fabfdeaf06395..747ea16d24565f882e1890a9cad50c07326007f5 100644 (file)
  *     http://www.pulse-eight.net/
  */
 
-#include "CECDetect.h"
+#include "AdapterDetection.h"
 #include "libPlatform/os-dependent.h"
 #include "util/StdString.h"
-#include <string.h>
 
 #if !defined(__WINDOWS__)
 #include <dirent.h>
@@ -101,7 +100,7 @@ bool FindComPort(CStdString &strLocation)
 }
 #endif
 
-int CCECDetect::FindDevices(vector<cec_device> &deviceList, const char *strDevicePath /* = NULL */)
+int CAdapterDetection::FindAdapters(vector<cec_adapter> &deviceList, const char *strDevicePath /* = NULL */)
 {
   int iFound(0);
 
@@ -146,7 +145,7 @@ int CCECDetect::FindDevices(vector<cec_device> &deviceList, const char *strDevic
       CStdString strComm(strPath);
       if (FindComPort(strComm))
       {
-        cec_device foundDev;
+        cec_adapter foundDev;
         foundDev.path = strPath;
         foundDev.comm = strComm;
         deviceList.push_back(foundDev);
@@ -244,7 +243,7 @@ int CCECDetect::FindDevices(vector<cec_device> &deviceList, const char *strDevic
       if (_tcslen(strPortName) > 3 && _tcsnicmp(strPortName, _T("COM"), 3) == 0 &&
         _ttoi(&(strPortName[3])) > 0)
       {
-        cec_device foundDev;
+        cec_adapter foundDev;
         foundDev.path = devicedetailData->DevicePath;
         foundDev.comm = strPortName;
         deviceList.push_back(foundDev);