Made wxSplitterWindow conform to the docs with respect to using a
negative sash position in the Split* methods. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@9905 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
29f45f85e9
commit
00a32dc1fb
@ -314,7 +314,7 @@ void wxSplitterWindow::OnMouseEvent(wxMouseEvent& event)
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (new_sash_position == m_sashPosition)
|
||||
return;
|
||||
|
||||
@ -698,7 +698,7 @@ void wxSplitterWindow::SizeWindows()
|
||||
if ( GetBorderSize() > 0 )
|
||||
DrawBorders(dc);
|
||||
DrawSash(dc);
|
||||
|
||||
|
||||
SetNeedUpdating(FALSE);
|
||||
}
|
||||
|
||||
@ -727,7 +727,7 @@ bool wxSplitterWindow::SplitVertically(wxWindow *window1, wxWindow *window2, int
|
||||
if ( sashPosition > 0 )
|
||||
m_sashPosition = sashPosition;
|
||||
else if ( sashPosition < 0 )
|
||||
m_sashPosition = w - sashPosition;
|
||||
m_sashPosition = w + sashPosition; // It's negative so adding is subtracting
|
||||
else // default
|
||||
m_sashPosition = w/2;
|
||||
|
||||
@ -750,7 +750,7 @@ bool wxSplitterWindow::SplitHorizontally(wxWindow *window1, wxWindow *window2, i
|
||||
if ( sashPosition > 0 )
|
||||
m_sashPosition = sashPosition;
|
||||
else if ( sashPosition < 0 )
|
||||
m_sashPosition = h - sashPosition;
|
||||
m_sashPosition = h + sashPosition; // It's negative so adding is subtracting
|
||||
else // default
|
||||
m_sashPosition = h/2;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user