Applied patch [ 621451 ] Fixed version of wxSlider class

Otto Wyss

This patch corrects several bugs in the wxSlider class
for the wxUniversal/MSW port. It affects the files
"slider.h", "slider.cpp", "win32.cpp" and "gtk.cpp"
(and others). The slider should now work as expected. A simple test
program can be downloaded from

"http://dpartialmirror.sourceforge.net/Test/".


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@18897 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2003-01-24 11:23:52 +00:00
parent 350777b68f
commit 6766e5d136
5 changed files with 486 additions and 314 deletions

View File

@@ -95,10 +95,14 @@ public:
{ return IsVert() ? wxVERTICAL : wxHORIZONTAL; }
// do we have labels?
bool HasLabels() const { return (GetWindowStyle() & wxSL_LABELS) != 0; }
bool HasLabels() const
{ return ((GetWindowStyle() & wxSL_LABELS) != 0) &
((GetWindowStyle() & (wxSL_TOP|wxSL_BOTTOM|wxSL_LEFT|wxSL_RIGHT)) != 0); }
// do we have ticks?
bool HasTicks() const { return (GetWindowStyle() & wxSL_TICKS) != 0; }
bool HasTicks() const
{ return ((GetWindowStyle() & wxSL_TICKS) != 0) &
((GetWindowStyle() & (wxSL_TOP|wxSL_BOTTOM|wxSL_LEFT|wxSL_RIGHT|wxSL_BOTH)) != 0); }
// implement wxControlWithThumb interface
virtual wxWindow *GetWindow() { return this; }