git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@4590
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
m_dragMode = wxSPLIT_DRAG_DRAGGING;
if ((GetWindowStyleFlag() & wxSP_LIVE_UPDATE) == 0)
m_dragMode = wxSPLIT_DRAG_DRAGGING;
if ((GetWindowStyleFlag() & wxSP_LIVE_UPDATE) == 0)
- {
- DrawSashTracker(x, y);
- }
+ {
+ DrawSashTracker(x, y);
+ }
// Erase old tracker
if ((GetWindowStyleFlag() & wxSP_LIVE_UPDATE) == 0)
// Erase old tracker
if ((GetWindowStyleFlag() & wxSP_LIVE_UPDATE) == 0)
DrawSashTracker(m_oldX, m_oldY);
DrawSashTracker(m_oldX, m_oldY);
// Obtain window size. We are only interested in the dimension the sash
// splits up
// Obtain window size. We are only interested in the dimension the sash
// splits up
// Erase old tracker
if ((GetWindowStyleFlag() & wxSP_LIVE_UPDATE) == 0)
// Erase old tracker
if ((GetWindowStyleFlag() & wxSP_LIVE_UPDATE) == 0)
DrawSashTracker(m_oldX, m_oldY);
DrawSashTracker(m_oldX, m_oldY);
if (m_splitMode == wxSPLIT_VERTICAL)
x = new_sash_position;
if (m_splitMode == wxSPLIT_VERTICAL)
x = new_sash_position;
// Draw new one
if ((GetWindowStyleFlag() & wxSP_LIVE_UPDATE) == 0)
// Draw new one
if ((GetWindowStyleFlag() & wxSP_LIVE_UPDATE) == 0)
DrawSashTracker(m_oldX, m_oldY);
DrawSashTracker(m_oldX, m_oldY);
m_sashPosition = new_sash_position;
m_sashPosition = new_sash_position;
- m_needUpdating = TRUE;
- }
+ m_needUpdating = TRUE;
+ }
}
else if ( event.LeftDClick() )
{
}
else if ( event.LeftDClick() )
{
dc.SetBrush(*wxTRANSPARENT_BRUSH);
dc.SetPen(*m_lightShadowPen);
dc.SetBrush(*wxTRANSPARENT_BRUSH);
dc.SetPen(*m_lightShadowPen);
- int xShadow = m_borderSize ? m_borderSize - 1 : 0 ;
+ int xShadow = m_borderSize ? m_borderSize - 1 : 0 ;
dc.DrawLine(m_sashPosition, xShadow , m_sashPosition, h-m_borderSize);
dc.SetPen(*m_hilightPen);
dc.DrawLine(m_sashPosition+1, m_borderSize - 2, m_sashPosition+1, h - m_borderSize+2);
dc.SetPen(*m_mediumShadowPen);
dc.DrawLine(m_sashPosition, xShadow , m_sashPosition, h-m_borderSize);
dc.SetPen(*m_hilightPen);
dc.DrawLine(m_sashPosition+1, m_borderSize - 2, m_sashPosition+1, h - m_borderSize+2);
dc.SetPen(*m_mediumShadowPen);
- int yMedium = m_borderSize ? h-m_borderSize+1 : h ;
+ int yMedium = m_borderSize ? h-m_borderSize+1 : h ;
dc.DrawLine(m_sashPosition+m_sashSize-2, xShadow, m_sashPosition+m_sashSize-2, yMedium);
dc.SetPen(*m_darkShadowPen);
dc.DrawLine(m_sashPosition+m_sashSize-2, xShadow, m_sashPosition+m_sashSize-2, yMedium);
dc.SetPen(*m_darkShadowPen);
- if ( m_borderSize > 0 )
- DrawBorders(dc);
+ if ( m_borderSize > 0 )
+ DrawBorders(dc);
// for compatibility, call the virtual function
OnDoubleClickSash(event.GetX(), event.GetY());
// for compatibility, call the virtual function
OnDoubleClickSash(event.GetX(), event.GetY());
- if ( GetMinimumPaneSize() == 0
- || m_permitUnsplitAlways)
+ if ( GetMinimumPaneSize() == 0 || m_permitUnsplitAlways )
{
wxWindow *win = event.GetWindowBeingRemoved();
{
wxWindow *win = event.GetWindowBeingRemoved();
+ // do it before calling OnUnsplit() which may delete the window
+ win->Show(FALSE);
+
// for compatibility, call the virtual function
OnUnsplit(win);
// for compatibility, call the virtual function
OnUnsplit(win);