Problem with transfer mode, xine plugin and ActualDevice

Message ID 4368FE50.5000601@ventoso.org
State New
Headers

Commit Message

Luca Olivetti Nov. 2, 2005, 5:58 p.m. UTC
  En/na Reinhard Nissl ha escrit:

> Please provide me a showcase with femon. I could hack vdr-xine for
> multiple devices and try to reproduce this problem here too.

Btw, this is the patch I'm using now (against original 0.7.6), and it
seems to work, but I'm not sure it's due to simple luck or it is working
by design (e.g. if I switch the order of cControl::Shutdown() and
Skins.Message in the OnClientConnect handler it won't work).

Bye
  

Patch

--- xineDevice.c.orig	2005-11-01 23:22:33.373053917 +0100
+++ xineDevice.c	2005-11-02 01:10:01.790392026 +0100
@@ -2630,8 +2630,13 @@ 
     {
       cDevice *primaryDevice = cDevice::PrimaryDevice();
       if (this != primaryDevice)
+      {
+        Skins.Message(mtInfo, tr("Switching primary DVB to vdr-xine..."));
+        cControl::Shutdown();
         SetPrimaryDevice(1 + DeviceNumber());
-      originalPrimaryDevice = primaryDevice;
+        originalPrimaryDevice = primaryDevice;
+      }
+
     }
 
     if (m_settings.ShallSwitchSkin())
@@ -2647,7 +2652,11 @@ 
       && originalPrimaryDevice)
     {
       if (this != originalPrimaryDevice)
+      {
+        cControl::Shutdown();
         SetPrimaryDevice(1 + originalPrimaryDevice->DeviceNumber());
+        Skins.Message(mtInfo, tr("Switched primary DVB back from vdr-xine"));
+      }
     }
   }