IMPLEMENT_DYNAMIC_CLASS(wxSplitterWindow, wxWindow)
/*
- TODO PROPERTIES
- style wxSP_3D
- sashpos (long , 0 )
- minsize (long -1 )
- object, object_ref
- orientation
+ TODO PROPERTIES
+ style wxSP_3D
+ sashpos (long , 0 )
+ minsize (long -1 )
+ object, object_ref
+ orientation
*/
IMPLEMENT_DYNAMIC_CLASS(wxSplitterEvent, wxNotifyEvent)
SizeWindows();
return; // it won't needUpdating in this case
}
-
+
if (m_needUpdating)
SizeWindows();
}
{
// Start the drag now
m_dragMode = wxSPLIT_DRAG_DRAGGING;
-
+
// Capture mouse and set the cursor
CaptureMouse();
SetResizeCursor();
{
// We can stop dragging now and see what we've got.
m_dragMode = wxSPLIT_DRAG_NONE;
-
+
// Release mouse and unset the cursor
ReleaseMouse();
SetCursor(* wxSTANDARD_CURSOR);
int z = m_splitMode == wxSPLIT_VERTICAL ? x : y;
int hitMin = m_sashPosition - tolerance;
int hitMax = m_sashPosition + GetSashSize() + tolerance;
-
+
return z >= hitMin && z <= hitMax;
}
// Set pane for unsplit window
void wxSplitterWindow::Initialize(wxWindow *window)
{
- wxASSERT_MSG( window && window->GetParent() == this,
+ wxASSERT_MSG( (!window || (window && window->GetParent() == this)),
_T("windows in the splitter should have it as parent!") );
m_windowOne = window;
// right now (e.g. because the window is too small)
m_requestedSashPosition = sashPosition;
m_checkRequestedSashPosition = false;
-
+
DoSetSashPosition(ConvertSashPosition(sashPosition));
SizeWindows();
// right now (e.g. because the window is too small)
m_requestedSashPosition = position;
m_checkRequestedSashPosition = false;
-
+
DoSetSashPosition(ConvertSashPosition(position));
if ( redraw )