better solution to add possibility to delete eSocketNotifiers,
[vuplus_dvbapp] / lib / dvb / frontend.h
index 111e715..61ea3bc 100644 (file)
@@ -13,6 +13,7 @@ class eDVBFrontendParameters: public iDVBFrontendParameters
                eDVBFrontendParametersTerrestrial terrestrial;
        };
        int m_type;
+       int m_flags;
 public:
        eDVBFrontendParameters();
        ~eDVBFrontendParameters()
@@ -32,6 +33,9 @@ public:
 
        RESULT getHash(unsigned long &) const;
        RESULT calcLockTimeout(unsigned int &) const;
+
+       RESULT getFlags(unsigned int &flags) const { flags = m_flags; return 0; }
+       RESULT setFlags(unsigned int flags) { m_flags = flags; return 0; }
 };
 
 #ifndef SWIG
@@ -43,6 +47,9 @@ class eDVBFrontend: public iDVBFrontend, public Object
 {
 public:
        enum {
+               NEW_CSW,
+               NEW_UCSW,
+               NEW_TONEBURST,
                CSW,                  // state of the committed switch
                UCSW,                 // state of the uncommitted switch
                TONEBURST,            // current state of toneburst switch
@@ -61,6 +68,7 @@ public:
        Signal1<void,iDVBFrontend*> m_stateChanged;
 private:
        DECLARE_REF(eDVBFrontend);
+       bool m_simulate;
        bool m_enabled;
        int m_type;
        int m_dvbid;
@@ -77,7 +85,7 @@ private:
        FRONTENDPARAMETERS parm;
        int m_state;
        ePtr<iDVBSatelliteEquipmentControl> m_sec;
-       eSocketNotifier *m_sn;
+       ePtr<eSocketNotifier> m_sn;
        int m_tuning;
        eTimer *m_timeout;
        eTimer *m_tuneTimer;
@@ -97,10 +105,9 @@ private:
        void tuneLoop();  // called by m_tuneTimer
        void setFrontend();
        bool setSecSequencePos(int steps);
-       void setRotorData(int pos, int cmd);
        static int PriorityOrder;
 public:
-       eDVBFrontend(int adap, int fe, int &ok);        
+       eDVBFrontend(int adap, int fe, int &ok, bool simulate=false);
        virtual ~eDVBFrontend();
 
        int readInputpower();
@@ -135,6 +142,7 @@ public:
        int openFrontend();
        int closeFrontend(bool force=false);
        const char *getDescription() const { return m_description; }
+       bool is_simulate() const { return m_simulate; }
 };
 
 #endif // SWIG