diff options
Diffstat (limited to 'include/media/JetPlayer.h')
-rw-r--r-- | include/media/JetPlayer.h | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/include/media/JetPlayer.h b/include/media/JetPlayer.h index 16764a9..6d53989 100644 --- a/include/media/JetPlayer.h +++ b/include/media/JetPlayer.h @@ -65,7 +65,6 @@ public: private: - static int renderThread(void*); int render(); void fireUpdateOnStatusChange(); void fireEventsFromJetQueue(); @@ -97,6 +96,28 @@ private: char mJetFilePath[256]; + class JetPlayerThread : public Thread { + public: + JetPlayerThread(JetPlayer *player) : mPlayer(player) { + } + + protected: + virtual ~JetPlayerThread() {} + + private: + JetPlayer *mPlayer; + + bool threadLoop() { + int result; + result = mPlayer->render(); + return false; + } + + JetPlayerThread(const JetPlayerThread &); + JetPlayerThread &operator=(const JetPlayerThread &); + }; + + sp<JetPlayerThread> mThread; }; // end class JetPlayer |