+ if (m_bmpDisabledOriginal.Ok())
+ {
+ if (m_bmpDisabledOriginal.GetMask())
+ {
+ int backgroundPixel;
+ XtVaGetValues((Widget) m_mainWidget,
+ XmNbackground, &backgroundPixel,
+ NULL);
+
+ wxColour col;
+ col.SetPixel(backgroundPixel);
+
+ wxBitmap newBitmap =
+ wxCreateMaskedBitmap(m_bmpDisabledOriginal, col);
+ m_bmpDisabled = newBitmap;
+
+ insensPixmap = (Pixmap) m_bmpDisabled.GetDrawable();
+ }
+ else
+ insensPixmap = (Pixmap) m_bitmapCache.GetInsensPixmap(m_mainWidget);
+ }
+ else
+ insensPixmap = (Pixmap) m_bitmapCache.GetInsensPixmap(m_mainWidget);
+
+ // Now make the bitmap representing the armed state
+ if (m_bmpSelectedOriginal.Ok())
+ {
+ if (m_bmpSelectedOriginal.GetMask())
+ {
+ int backgroundPixel;
+ XtVaGetValues((Widget) m_mainWidget,
+ XmNarmColor, &backgroundPixel,
+ NULL);
+
+ wxColour col;
+ col.SetPixel(backgroundPixel);
+
+ wxBitmap newBitmap =
+ wxCreateMaskedBitmap(m_bmpSelectedOriginal, col);
+ m_bmpSelected = newBitmap;
+
+ armPixmap = (Pixmap) m_bmpSelected.GetDrawable();
+ }
+ else
+ armPixmap = (Pixmap) m_bitmapCache.GetArmPixmap(m_mainWidget);
+ }