implementing docking denial
Posted on 2000-05-01
I have a TControlBar with 1 memo sitting on it. Align=top.
I have a second TControlBar with 3 toolbars on it. Align=bottom.
TControlbar is autosize=true
he memo & toolbars: dragkind=auto, dragmode=docksite
I want the memo to be able to be dragged away but not into the other TControlBar. I intercepted one TcontrolBar's DockOver event and thought that by interrogating
that I could distinguish what object was attempting to dock, and deny it/allow it.
Unfortunately the TDragDockObject doesn't have many properties, and I cannot determine if what is actually being dragged is memo2 or toolbar2 or toolbar3 etc. which are components with names etc.
How do I get from the skimpy TDragDockObject parameter to knowing which component/control is being dragged in order to deny the dock operations etc. ?
I am using Delphi 4