>*!* Put the shape on top so we can drag and drop on it >Thisform.shpDataLocator.ZOrder( 0 ) >This.Drag( 1 ) >>
>This.Drag( 2 ) >>
>*** See if we are re-sizing >IF LOWER( toSource.Name ) = 'shpsplitter' > Thisform.SizeControls( toSource, tnXCoord, tnYCoord ) > *!* Put the shape on the bottom after we have dropped > This.ZOrder( 1 ) >ELSE > DODEFAULT( toSource, tnXCoord, tnYCoord ) >ENDIF >>
>LPARAMETERS toBar, tnXCoord, tnYCoord >LOCAL lnBarLeft, lnTreeWidth, lnDataContainerLeft, lnDataContainerWidth > >ThisForm.LockScreen = .T. > >WITH ThisForm > *** Save the position of the bar's left position > lnBarLeft = tnXCoord > toBar.Left = lnBarLeft > *** Check for minimum widths of the tree and list > Thisform.CheckMinWidth( toBar, @lnBarLeft ) > *** If we have altered the bar position, do it here > IF lnBarLeft # toBar.Left > toBar.Left = lnBarLeft > ENDIF > *** Calculate the Left Position of the Data Container > lnDataContainerLeft = lnBarLeft + toBar.Width > *** Calculate the Width of the TreeView > lnTreeWidth = toBar.Left - .oTree.Left > *** Calculate the Width of the Data Container > lnDataContainerWidth = .Width - ( lnBarLeft + toBar.Width + 15 ) > > *** Now set the heights of the controls > .oTree.Width = lnTreeWidth > IF TYPE( 'Thisform.oDataContainer' ) = 'O' AND NOT ISNULL( Thisform.oDataContainer ) > .oDataContainer.Left = lnDataContainerLeft > .oDataContainer.Width = lnDataContainerWidth > ENDIF >ENDWITH >*!* And send the data locator shape to the back again >Thisform.shpDataLocator.ZOrder( 1 ) >ThisForm.LockScreen = .F. >