fixes to handling of 0 and negative splitter position when splitting it initially

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14344 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2002-02-22 00:48:02 +00:00
parent 689fceb7a7
commit 74c57d1ff6
3 changed files with 59 additions and 25 deletions

View File

@@ -186,6 +186,7 @@ MyFrame::MyFrame()
m_right->Show(FALSE);
m_splitter->Initialize(m_left);
#else
// you can also try -100
m_splitter->SplitVertically(m_left, m_right, 100);
#endif
@@ -210,6 +211,8 @@ void MyFrame::SplitHorizontal(wxCommandEvent& WXUNUSED(event) )
m_left->Show(TRUE);
m_right->Show(TRUE);
m_splitter->SplitHorizontally( m_left, m_right );
SetStatusText(_T("Splitter split horizontally"), 1);
}
void MyFrame::SplitVertical(wxCommandEvent& WXUNUSED(event) )
@@ -219,6 +222,8 @@ void MyFrame::SplitVertical(wxCommandEvent& WXUNUSED(event) )
m_left->Show(TRUE);
m_right->Show(TRUE);
m_splitter->SplitVertically( m_left, m_right );
SetStatusText(_T("Splitter split vertically"), 1);
}
void MyFrame::Unsplit(wxCommandEvent& WXUNUSED(event) )