]> git.saurik.com Git - wxWidgets.git/blob - include/wx/generic/mask.h
remove unused variable assignment, closes #14928
[wxWidgets.git] / include / wx / generic / mask.h
1 ///////////////////////////////////////////////////////////////////////////////
2 // Name: wx/generic/mask.h
3 // Purpose: generic implementation of wxMask
4 // Author: Vadim Zeitlin
5 // Created: 2006-09-28
6 // RCS-ID: $Id$
7 // Copyright: (c) 2006 Vadim Zeitlin <vadim@wxwindows.org>
8 // Licence: wxWindows licence
9 ///////////////////////////////////////////////////////////////////////////////
10
11 #ifndef _WX_GENERIC_MASKG_H_
12 #define _WX_GENERIC_MASKG_H_
13
14 // ----------------------------------------------------------------------------
15 // generic wxMask implementation
16 // ----------------------------------------------------------------------------
17
18 class WXDLLIMPEXP_CORE wxMask : public wxMaskBase
19 {
20 public:
21 wxMask() { }
22 wxMask(const wxBitmap& bitmap, const wxColour& colour)
23 {
24 InitFromColour(bitmap, colour);
25 }
26
27 #if wxUSE_PALETTE
28 wxMask(const wxBitmap& bitmap, int paletteIndex)
29 {
30 Create(bitmap, paletteIndex);
31 }
32 #endif // wxUSE_PALETTE
33
34 wxMask(const wxBitmap& bitmap)
35 {
36 InitFromMonoBitmap(bitmap);
37 }
38
39 // implementation-only from now on
40 wxBitmap GetBitmap() const { return m_bitmap; }
41
42 private:
43 // implement wxMaskBase pure virtuals
44 virtual void FreeData();
45 virtual bool InitFromColour(const wxBitmap& bitmap, const wxColour& colour);
46 virtual bool InitFromMonoBitmap(const wxBitmap& bitmap);
47
48 wxBitmap m_bitmap;
49
50 DECLARE_DYNAMIC_CLASS(wxMask)
51 };
52
53 #endif // _WX_GENERIC_MASKG_H_
54