]> git.saurik.com Git - wxWidgets.git/blob - include/wx/mac/wave.h
Fixed typo in my last commit (it did break socket detection code :-( ).
[wxWidgets.git] / include / wx / mac / wave.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wave.h
3 // Purpose: wxWave class (loads and plays short Windows .wav files).
4 // Optional on non-Windows platforms.
5 // Author: AUTHOR
6 // Modified by:
7 // Created: ??/??/98
8 // RCS-ID: $Id$
9 // Copyright: (c) AUTHOR
10 // Licence: wxWindows licence
11 /////////////////////////////////////////////////////////////////////////////
12
13 #ifndef _WX_WAVE_H_
14 #define _WX_WAVE_H_
15
16 #ifdef __GNUG__
17 #pragma interface "wave.h"
18 #endif
19
20 #include "wx/object.h"
21
22 class WXDLLEXPORT wxWave : public wxObject
23 {
24 public:
25 wxWave();
26 wxWave(const wxString& fileName, bool isResource = FALSE);
27 wxWave(int size, const wxByte* data);
28 ~wxWave();
29
30 public:
31 bool Create(const wxString& fileName, bool isResource = FALSE);
32 bool IsOk() const { return !m_sndname.IsEmpty(); }
33 bool Play(bool async = TRUE, bool looped = FALSE) const;
34
35 protected:
36 bool Free();
37
38 private:
39 void* m_sndChan;
40
41 wxString m_sndname;
42 void* m_hSnd;
43 int m_waveLength;
44 bool m_isResource;
45 };
46
47 #endif
48 // _WX_WAVE_H_