/////////////////////////////////////////////////////////////////////////////
-// Name: bitmap.cpp
+// Name: src/motif/bmpmotif.cpp
// Purpose: wxBitmap
// Author: Julian Smart, originally in bitmap.cpp
// Modified by:
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
-#ifdef __VMS
-#define XtParent XTPARENT
-#define XtDisplay XTDISPLAY
-#endif
-
-#include "wx/defs.h"
#include "wx/motif/bmpmotif.h"
+#ifndef WX_PRECOMP
+ #include "wx/math.h"
+#endif
+
#ifdef __VMS__
#pragma message disable nosimpint
#endif
#include <X11/xpm.h>
#endif
-#include "wx/math.h"
-
Pixmap XCreateInsensitivePixmap( Display *display, Pixmap pixmap );
static inline wxCharBuffer GetCacheImageName(WXImage image)
void wxBitmapCache::SetBitmap( const wxBitmap& bitmap )
{
- if( m_bitmap != bitmap )
+ if ( !m_bitmap.IsSameAs(bitmap) )
{
InvalidateCache();
m_bitmap = bitmap;
{
XmUninstallImage( (XImage*)m_image );
XtFree( (char*)(XImage*)m_image );
- m_image = (WXImage*)NULL;
+ m_image = NULL;
}
}
}
while( XmIsGadget( widget ) )
widget = XtParent( widget );
- Pixel fg, bg;
+ WXPixel fg, bg;
XtVaGetValues( widget,
XmNbackground, &bg,
XmNforeground, &fg,
stipple = XCreateBitmapFromData( display, pixmap, stipple_data, 16, 16 );
if ( 0 != stipple )
{
- gc = XCreateGC( display, pixmap, (XtGCMask)0, (XGCValues*)NULL );
+ gc = XCreateGC( display, pixmap, (XtGCMask)0, NULL );
if ( NULL != gc )
{
/* Create an identical copy of the argument pixmap.