// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
-#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
-#pragma implementation "slider.h"
-#endif
-
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#include "wx/motif/private.h"
-void wxSliderCallback (Widget widget, XtPointer clientData, XmScaleCallbackStruct * cbs);
+static void wxSliderCallback (Widget widget, XtPointer clientData, XmScaleCallbackStruct * cbs);
IMPLEMENT_DYNAMIC_CLASS(wxSlider, wxControl)
m_mainWidget = (WXWidget) sliderWidget;
-#ifdef __VMS__
-#pragma message disable codcauunr
- // VMS gives here the compiler warning :
- // statement either is unreachable or causes unreachable code
-#endif
- if(style & wxSL_NOTIFY_DRAG)
- XtAddCallback (sliderWidget, XmNdragCallback,
- (XtCallbackProc) wxSliderCallback, (XtPointer) this);
- else
- XtAddCallback (sliderWidget, XmNvalueChangedCallback,
- (XtCallbackProc) wxSliderCallback, (XtPointer) this);
-#ifdef __VMS__
-#pragma message enable codcauunr
-#endif
-
+ XtAddCallback (sliderWidget, XmNvalueChangedCallback, (XtCallbackProc) wxSliderCallback, (XtPointer) this);
XtAddCallback (sliderWidget, XmNdragCallback, (XtCallbackProc) wxSliderCallback, (XtPointer) this);
ChangeFont(false);
}
wxScrollEvent event(scrollEvent, slider->GetId());
- XtVaGetValues (widget, XmNvalue, &event.m_commandInt, NULL);
+ int commandInt = event.GetInt();
+ XtVaGetValues (widget, XmNvalue, &commandInt, NULL);
+ event.SetInt(commandInt);
event.SetEventObject(slider);
slider->GetEventHandler()->ProcessEvent(event);