fix typo in drawing slider ticks; added assert to check for it (slightly modified patch 646256)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@18069 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
		@@ -655,7 +655,7 @@ public:
 | 
				
			|||||||
                                 int step = 1,
 | 
					                                 int step = 1,
 | 
				
			||||||
                                 int flags = 0)
 | 
					                                 int flags = 0)
 | 
				
			||||||
        { m_renderer->DrawSliderTicks(dc, rect, sizeThumb, orient,
 | 
					        { m_renderer->DrawSliderTicks(dc, rect, sizeThumb, orient,
 | 
				
			||||||
                                      start, end, start, flags); }
 | 
					                                      start, end, step, flags); }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    virtual void DrawMenuBarItem(wxDC& dc,
 | 
					    virtual void DrawMenuBarItem(wxDC& dc,
 | 
				
			||||||
                                 const wxRect& rect,
 | 
					                                 const wxRect& rect,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -2771,6 +2771,9 @@ void wxWin32Renderer::DrawSliderTicks(wxDC& dc,
 | 
				
			|||||||
        return;
 | 
					        return;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    // this would lead to an infinite loop below
 | 
				
			||||||
 | 
					    wxCHECK_RET( step > 1, _T("invalid step in wxRenderer::DrawSliderTicks") );
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    // the variable names correspond to horizontal case, but they can be used
 | 
					    // the variable names correspond to horizontal case, but they can be used
 | 
				
			||||||
    // for both orientations
 | 
					    // for both orientations
 | 
				
			||||||
    wxCoord x1, x2, y1, y2, len, widthThumb;
 | 
					    wxCoord x1, x2, y1, y2, len, widthThumb;
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user