]> git.saurik.com Git - wxWidgets.git/blobdiff - src/motif/slider.cpp
removed unnecessarily overridden wxControl method
[wxWidgets.git] / src / motif / slider.cpp
index 5a141dc7cb07c5c1e2ea21cf8877adb6fee2bcda..369cecc720141c9e1cfaffc5bf2e0172f4541f95 100644 (file)
 #include "wx/slider.h"
 #include "wx/utils.h"
 
+#ifdef __VMS__
+#pragma message disable nosimpint
+#endif
 #include <Xm/Xm.h>
 #include <Xm/Label.h>
 #include <Xm/LabelG.h>
 #include <Xm/RowColumn.h>
 #include <Xm/Scale.h>
+#ifdef __VMS__
+#pragma message enable nosimpint
+#endif
 
-#include <wx/motif/private.h>
+#include "wx/motif/private.h"
 
 void wxSliderCallback (Widget widget, XtPointer clientData, XmScaleCallbackStruct * cbs);
 
-#if !USE_SHARED_LIBRARY
 IMPLEMENT_DYNAMIC_CLASS(wxSlider, wxControl)
 
 BEGIN_EVENT_TABLE(wxSlider, wxControl)
 END_EVENT_TABLE()
-#endif
 
 
 
@@ -93,12 +97,20 @@ bool wxSlider::Create(wxWindow *parent, wxWindowID id,
 
     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, XmNdragCallback, (XtCallbackProc) wxSliderCallback, (XtPointer) this);
 
@@ -288,6 +300,7 @@ void wxSliderCallback (Widget widget, XtPointer clientData, XmScaleCallbackStruc
             // Also send a wxCommandEvent for compatibility.
             wxCommandEvent event2(wxEVT_COMMAND_SLIDER_UPDATED, slider->GetId());
             event2.SetEventObject(slider);
+            event2.SetInt( event.GetInt() );
             slider->ProcessCommand(event2);
             break;
         }