diff options
author | Monroe Williams <monroe@lindenlab.com> | 2007-08-02 01:18:34 +0000 |
---|---|---|
committer | Monroe Williams <monroe@lindenlab.com> | 2007-08-02 01:18:34 +0000 |
commit | 7138fb673ac3df46b9cb5f23d0d74e70fdd2b6b3 (patch) | |
tree | 3c34a3a180b5275bd4166b0056765c5868f56447 /indra/newview/lloverlaybar.h | |
parent | f6a10b3214d79df4e8f5768acaa68edbd2de5620 (diff) |
Merge down from Branch_1-18-1:
svn merge --ignore-ancestry svn+ssh://svn.lindenlab.com/svn/linden/release@66449 svn+ssh://svn.lindenlab.com/svn/linden/branches/Branch_1-18-1@67131
Diffstat (limited to 'indra/newview/lloverlaybar.h')
-rw-r--r-- | indra/newview/lloverlaybar.h | 45 |
1 files changed, 29 insertions, 16 deletions
diff --git a/indra/newview/lloverlaybar.h b/indra/newview/lloverlaybar.h index 78f544df57..d7fff6ba1e 100644 --- a/indra/newview/lloverlaybar.h +++ b/indra/newview/lloverlaybar.h @@ -25,11 +25,10 @@ class LLUUID; class LLFrameTimer; class LLStatGraph; class LLSlider; -class LLVolumeSliderCtrl; +class LLVoiceRemoteCtrl; class LLOverlayBar -: public LLPanel, - public LLMediaRemoteCtrlObserver +: public LLPanel { public: LLOverlayBar(const std::string& name, const LLRect& rect ); @@ -38,14 +37,16 @@ public: virtual EWidgetType getWidgetType() const; virtual LLString getWidgetTag() const; - virtual void reshape(S32 width, S32 height, BOOL called_from_parent); - - void refresh(); + /*virtual*/ void refresh(); + /*virtual*/ void draw(); + /*virtual*/ void reshape(S32 width, S32 height, BOOL called_from_parent); void layoutButtons(); - /*virtual*/ void draw(); - + // helpers for returning desired state + BOOL mediaPlaying() { return mMediaState == PLAYING; } + BOOL musicPlaying() { return mMusicState == PLAYING; } + static void onClickIMReceived(void* data); static void onClickSetNotBusy(void* data); static void onClickReleaseKeys(void* data); @@ -53,23 +54,35 @@ public: static void onClickStandUp(void* data); static void onClickResetView(void* data); - // observer overrides - void onVolumeChange ( const LLMediaRemoteCtrlObserver::EventType& eventIn ); - void onStopButtonPressed ( const LLMediaRemoteCtrlObserver::EventType& eventIn ); - void onPlayButtonPressed ( const LLMediaRemoteCtrlObserver::EventType& eventIn ); - void onPauseButtonPressed ( const LLMediaRemoteCtrlObserver::EventType& eventIn ); - - LLMediaRemoteCtrl* getMusicRemoteControl () { return mMusicRemote; }; + //static media helper functions + static void mediaPlay(void*); + static void mediaPause(void*); + static void mediaStop(void*); + + static void musicPlay(void*); + static void musicPause(void*); + static void musicStop(void*); -protected: + static void toggleAudioVolumeFloater(void*); + + static void enableMediaButtons(LLPanel* panel); + static void enableMusicButtons(LLPanel* panel); +protected: + static void* createMasterRemote(void* userdata); static void* createMusicRemote(void* userdata); static void* createMediaRemote(void* userdata); + static void* createVoiceRemote(void* userdata); protected: + LLMediaRemoteCtrl* mMasterRemote; LLMediaRemoteCtrl* mMusicRemote; LLMediaRemoteCtrl* mMediaRemote; + LLVoiceRemoteCtrl* mVoiceRemote; BOOL isBuilt; + enum { STOPPED=0, PLAYING=1, PAUSED=2 }; + BOOL mMediaState; + BOOL mMusicState; }; extern LLOverlayBar* gOverlayBar; |