Merge branch 'master' of git.opendreambox.org:/git/enigma2
[enigma2.git] / lib / nav / pcore.h
index 018209bcb1e74f9cbe31abd6d360c407be77bf4a..c157e0dcc43f449902be4564b5ebe07fc9e1bbe2 100644 (file)
@@ -8,34 +8,27 @@
 
 class pNavigation: public iObject, public Object
 {
 
 class pNavigation: public iObject, public Object
 {
-DECLARE_REF(pNavigation);
+       DECLARE_REF(pNavigation);
 public:
        PSignal1<void, int> m_event;
 public:
        PSignal1<void, int> m_event;
-       
-       enum
-       {
-               evStopService,  /** the "current" service was just stopped and likes to be deallocated (clear refs!) */
-               evNewService,   /** a new "current" service was just started */
-               evPlayFailed,   /** the next service (in playlist) or the one given in playService failed to play */
-               evPlaylistDone, /** the last service in the playlist was just played */
-               evUpdatedEventInfo /** the "currently running" event info was updated */
-       };
-       
+       PSignal2<void, ePtr<iRecordableService>&, int> m_record_event;
+
        pNavigation();
        
        RESULT playService(const eServiceReference &service);
        pNavigation();
        
        RESULT playService(const eServiceReference &service);
-       RESULT recordService(const eServiceReference &service);
-       RESULT endRecording();
-       
-       RESULT enqueueService(const eServiceReference &service);
-       RESULT getCurrentService(ePtr<iPlayableService> &service);
-       RESULT getPlaylist(ePtr<ePlaylist> &playlist);
-       
+       RESULT stopService();
        RESULT pause(int p);
        RESULT pause(int p);
+       SWIG_VOID(RESULT) getCurrentService(ePtr<iPlayableService> &SWIG_OUTPUT);
+
+       SWIG_VOID(RESULT) recordService(const eServiceReference &ref, ePtr<iRecordableService> &SWIG_OUTPUT, bool simulate);
+       RESULT stopRecordService(ePtr<iRecordableService> &service);
+       PyObject *getRecordings(bool simulate=false);
+
 private:
        ePtr<eNavigation> m_core;
 private:
        ePtr<eNavigation> m_core;
-       ePtr<eConnection> m_nav_event_connection;
-       void navEvent(eNavigation *nav, int event);
+       ePtr<eConnection> m_nav_event_connection, m_nav_record_event_connection;
+       void navEvent(int event);
+       void navRecordEvent(ePtr<iRecordableService>, int event);
 };
 
 #endif
 };
 
 #endif