]> git.saurik.com Git - wxWidgets.git/blame - include/wx/motif/bmpmotif.h
fix the run-time behaviour after the last compilation fixing patch
[wxWidgets.git] / include / wx / motif / bmpmotif.h
CommitLineData
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
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
925f7740 9// Licence: wxWindows licence
aae91497
MB
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_BMPMOTIF_H_
13#define _WX_BMPMOTIF_H_
14
aae91497
MB
15#include "wx/defs.h"
16#include "wx/bitmap.h"
17
18class WXDLLEXPORT wxBitmapCache
19{
20public:
21 wxBitmapCache()
22 {
23 m_labelPixmap = (WXPixmap)NULL;
24 m_armPixmap = (WXPixmap)NULL;
25 m_insensPixmap = (WXPixmap)NULL;
26 m_image = (WXImage)NULL;
27 m_display = (WXDisplay*)NULL;
28 SetColoursChanged();
29 }
30
31 ~wxBitmapCache();
32
33 void SetColoursChanged();
34 void SetBitmap( const wxBitmap& bitmap );
35
36 WXPixmap GetLabelPixmap( WXWidget w );
37 WXPixmap GetInsensPixmap( WXWidget w = (WXWidget)NULL );
38 WXPixmap GetArmPixmap( WXWidget w );
39private:
40 void InvalidateCache();
41 void CreateImageIfNeeded( WXWidget w );
42
2263a14e
VZ
43 WXPixmap GetPixmapFromCache(WXWidget w);
44
aae91497
MB
45 struct
46 {
47 bool label : 1;
48 bool arm : 1;
49 bool insens : 1;
50 } m_recalcPixmaps;
51 wxBitmap m_bitmap;
52 WXDisplay* m_display;
53 WXPixmap m_labelPixmap, m_armPixmap, m_insensPixmap;
54 WXImage m_image;
55};
56
57#endif // _WX_BMPMOTIF_H_