]> git.saurik.com Git - wxWidgets.git/blame - include/wx/msw/sound.h
#undef things which require other, disabled, ones, instead of re-#defining them as 1
[wxWidgets.git] / include / wx / msw / sound.h
CommitLineData
2bda0e17 1/////////////////////////////////////////////////////////////////////////////
ddc5c471 2// Name: wx/msw/sound.h
bae90c4c 3// Purpose: wxSound class
2bda0e17
KB
4// Author: Julian Smart
5// Modified by:
6// Created: 01/02/97
7// RCS-ID: $Id$
bbcdf8bc 8// Copyright: (c) Julian Smart
57f4f925 9// Licence: wxWindows licence
2bda0e17
KB
10/////////////////////////////////////////////////////////////////////////////
11
bae90c4c
VS
12#ifndef _WX_SOUND_H_
13#define _WX_SOUND_H_
2bda0e17 14
12028905 15#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
bae90c4c 16#pragma interface "sound.h"
2bda0e17
KB
17#endif
18
bae90c4c 19#if wxUSE_SOUND
ea37d858 20
bae90c4c 21class WXDLLIMPEXP_ADV wxSound : public wxSoundBase
2bda0e17
KB
22{
23public:
ddc5c471
VZ
24 wxSound();
25 wxSound(const wxString& fileName, bool isResource = false);
26 wxSound(int size, const wxByte* data);
27 virtual ~wxSound();
2bda0e17 28
ddc5c471
VZ
29 // Create from resource or file
30 bool Create(const wxString& fileName, bool isResource = false);
321db4b6 31
ddc5c471
VZ
32 // Create from data
33 bool Create(int size, const wxByte* data);
57f4f925 34
ddc5c471
VZ
35 bool IsOk() const { return m_data != NULL; }
36
37 static void Stop();
2bda0e17
KB
38
39protected:
ddc5c471
VZ
40 void Init() { m_data = NULL; }
41 bool CheckCreatedOk();
42 void Free();
57f4f925 43
ddc5c471 44 virtual bool DoPlay(unsigned flags) const;
2bda0e17
KB
45
46private:
ddc5c471
VZ
47 // data of this object
48 class wxSoundData *m_data;
22f3361e 49
bae90c4c 50 DECLARE_NO_COPY_CLASS(wxSound)
2bda0e17 51};
ddc5c471
VZ
52
53#endif // wxUSE_SOUND
54
55#endif // _WX_SOUND_H_
2bda0e17 56