]> git.saurik.com Git - wxWidgets.git/blame - include/wx/mac/wave.h
avoid warning for duplicate defined wxEntry when compiling with the Apple
[wxWidgets.git] / include / wx / mac / wave.h
CommitLineData
0dbd6262
SC
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
af49c4b8 16#if defined(__GNUG__) && !defined(__APPLE__)
0dbd6262
SC
17#pragma interface "wave.h"
18#endif
19
20#include "wx/object.h"
21
d1a86313 22class WXDLLEXPORT wxWave : public wxObject
0dbd6262
SC
23{
24public:
25 wxWave();
26 wxWave(const wxString& fileName, bool isResource = FALSE);
d1a86313 27 wxWave(int size, const wxByte* data);
0dbd6262
SC
28 ~wxWave();
29
30public:
31 bool Create(const wxString& fileName, bool isResource = FALSE);
5b781a67 32 bool IsOk() const { return !m_sndname.IsEmpty(); }
0dbd6262
SC
33 bool Play(bool async = TRUE, bool looped = FALSE) const;
34
35protected:
4b651a46
GD
36 // prevent collision with some BSD definitions of macro Free()
37 bool FreeData();
0dbd6262
SC
38
39private:
5273bf2f 40 void* m_sndChan;
5b781a67
SC
41
42 wxString m_sndname;
5273bf2f 43 void* m_hSnd;
0dbd6262
SC
44 int m_waveLength;
45 bool m_isResource;
46};
47
48#endif
49 // _WX_WAVE_H_