#ifdef __VMS
#define XtDisplay XTDISPLAY
-#define XmNtoggleMode 0
-#define XmTOGGLE_INDETERMINATE 1
-#define XmTOGGLE_BOOLEAN 2
-#define XmUNSET 3
-#define XmSET 4
-#define XmINDETERMINATE 5
#endif
#include "wx/defs.h"
#pragma message enable nosimpint
#endif
+// define symbols that are missing in old versions of Motif.
+#if (XmVersion < 2000)
+#define XmNtoggleMode 0
+#define XmTOGGLE_INDETERMINATE 1
+#define XmTOGGLE_BOOLEAN 2
+#define XmUNSET 3
+#define XmSET 4
+#define XmINDETERMINATE 5
+#endif
+
+
#include "wx/motif/private.h"
void wxCheckBoxCallback (Widget w, XtPointer clientData,
{
if( !wxControl::CreateControl( parent, id, pos, size, style, validator,
name ) )
- return FALSE;
+ return false;
wxString label1(wxStripMenuCodes(label));
wxXmString text( label1 );
XmNvalueChangedCallback, (XtCallbackProc)wxCheckBoxCallback,
(XtPointer)this );
- XmToggleButtonSetState ((Widget) m_mainWidget, FALSE, TRUE);
+ XmToggleButtonSetState ((Widget) m_mainWidget, False, True);
AttachWidget( parent, m_mainWidget, (WXWidget)NULL,
pos.x, pos.y, size.x, size.y );
ChangeBackgroundColour();
- return TRUE;
+ return true;
}
void wxCheckBox::SetValue(bool val)
case wxCHK_UNCHECKED: value = XmUNSET; break;
case wxCHK_CHECKED: value = XmSET; break;
case wxCHK_UNDETERMINED: value = XmINDETERMINATE; break;
+ default: wxASSERT(0); return;
}
XtVaSetValues( (Widget) m_mainWidget,