Add new method PowerOnScreensaver. closes #114
[deb_libcec.git] / src / LibCecSharp / LibCecSharp.cpp
index 073ae774f926ea0b5e87a460a0437ae65409389f..562d13af8a5db27cb07b5f86bcf729df5ebb270a 100644 (file)
@@ -731,6 +731,24 @@ namespace CecSharp
       m_libCec->InitVideoStandalone();
     }
 
+    /// <summary>
+    /// Get the (virtual) USB vendor id
+    /// </summary>
+    /// <returns>The (virtual) USB vendor id</returns>
+    uint16_t GetAdapterVendorId()
+    {
+      return m_libCec->GetAdapterVendorId();
+    }
+
+    /// <summary>
+    /// Get the (virtual) USB product id
+    /// </summary>
+    /// <returns>The (virtual) USB product id</returns>
+    uint16_t GetAdapterProductId()
+    {
+      return m_libCec->GetAdapterProductId();
+    }
+
   private:
     !LibCecSharp(void)
     {
@@ -801,6 +819,12 @@ namespace CecSharp
       if (netConfig->ServerVersion >= CecServerVersion::Version1_6_3)
         config.bMonitorOnly = netConfig->MonitorOnlyClient ? 1 : 0;
 
+      if (netConfig->ServerVersion >= CecServerVersion::Version1_8_0)
+        config.cecVersion = (cec_version)netConfig->CECVersion;
+
+      if (netConfig->ServerVersion >= CecServerVersion::Version2_1_0)
+        config.bPowerOnScreensaver  = netConfig->PowerOnScreensaver ? 1 : 0;
+
       config.callbacks = &g_cecCallbacks;
     }