]>
Commit | Line | Data |
---|---|---|
aae91497 | 1 | ///////////////////////////////////////////////////////////////////////////// |
925f7740 | 2 | // Name: wx/motif/bmpmotif.h |
aae91497 MB |
3 | // Purpose: Motif-specific bitmap routines |
4 | // Author: Julian Smart, originally in bitmap.h | |
5 | // Modified by: | |
6 | // Created: 25/03/2003 | |
aae91497 | 7 | // Copyright: (c) Julian Smart |
925f7740 | 8 | // Licence: wxWindows licence |
aae91497 MB |
9 | ///////////////////////////////////////////////////////////////////////////// |
10 | ||
11 | #ifndef _WX_BMPMOTIF_H_ | |
12 | #define _WX_BMPMOTIF_H_ | |
13 | ||
aae91497 MB |
14 | #include "wx/defs.h" |
15 | #include "wx/bitmap.h" | |
16 | ||
53a2db12 | 17 | class WXDLLIMPEXP_CORE wxBitmapCache |
aae91497 MB |
18 | { |
19 | public: | |
20 | wxBitmapCache() | |
21 | { | |
22 | m_labelPixmap = (WXPixmap)NULL; | |
23 | m_armPixmap = (WXPixmap)NULL; | |
24 | m_insensPixmap = (WXPixmap)NULL; | |
25 | m_image = (WXImage)NULL; | |
d3b9f782 | 26 | m_display = NULL; |
aae91497 MB |
27 | SetColoursChanged(); |
28 | } | |
29 | ||
30 | ~wxBitmapCache(); | |
31 | ||
32 | void SetColoursChanged(); | |
33 | void SetBitmap( const wxBitmap& bitmap ); | |
34 | ||
35 | WXPixmap GetLabelPixmap( WXWidget w ); | |
36 | WXPixmap GetInsensPixmap( WXWidget w = (WXWidget)NULL ); | |
37 | WXPixmap GetArmPixmap( WXWidget w ); | |
38 | private: | |
39 | void InvalidateCache(); | |
40 | void CreateImageIfNeeded( WXWidget w ); | |
41 | ||
2263a14e VZ |
42 | WXPixmap GetPixmapFromCache(WXWidget w); |
43 | ||
aae91497 MB |
44 | struct |
45 | { | |
46 | bool label : 1; | |
47 | bool arm : 1; | |
48 | bool insens : 1; | |
49 | } m_recalcPixmaps; | |
50 | wxBitmap m_bitmap; | |
51 | WXDisplay* m_display; | |
52 | WXPixmap m_labelPixmap, m_armPixmap, m_insensPixmap; | |
53 | WXImage m_image; | |
54 | }; | |
55 | ||
56 | #endif // _WX_BMPMOTIF_H_ |