Changeset 46 for DockManager/Lazarus/UCustomDockManager.pas
- Timestamp:
- Sep 17, 2010, 8:02:32 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
DockManager/Lazarus/UCustomDockManager.pas
r45 r46 31 31 Control: TControl; 32 32 Splitter: TSplitter; 33 ClientAreaPanel: TPanel; 33 34 constructor Create(TheOwner: TComponent); override; 34 35 destructor Destroy; override; … … 177 178 end; 178 179 NewPanel.Control := Control; 179 Control.Parent := NewPanel; 180 Control.Parent := NewPanel.ClientAreaPanel; 181 Control.Align := alClient; 180 182 FDockPanels.Add(NewPanel); 181 183 … … 202 204 NewConjoinDockForm := TConjoinDockForm.Create(nil); 203 205 NewConjoinDockForm.Visible := True; 206 NewConjoinDockForm.BoundsRect := FDockSite.BoundsRect; 204 207 Control.ManualDock(NewConjoinDockForm.Panel); 205 208 FDockSite.ManualDock(NewConjoinDockForm.Panel); 206 209 end else begin 207 NewPanel := TPanel.Create(nil); 208 NewPanel.Parent := FDockSite.Parent; 209 NewPanel.Visible := True; 210 NewPanel.Left := FDockSite.Left; 211 NewPanel.Top := FDockSite.Top; 212 NewPanel.Width := FDockSite.Width; 213 NewPanel.Height := FDockSite.Height; 214 NewPanel.UseDockManager := True; 215 NewPanel.DockSite := True; 216 NewPanel.Color := clGreen; 217 NewPanel.ManualDock(FDockSite.HostDockSite); 218 // FDockSite.Parent := nil; 219 Control.ManualDock(NewPanel); 220 FDockSite.ManualDock(NewPanel); 210 Control.ManualDock(FDockSite.Parent); 221 211 end; 222 212 end else 223 if FDockSite is TPanelthen begin213 if (FDockSite is TPanel) or (FDockSite is TDockClientPanel) then begin 224 214 InsertControlPanel(Control, InsertAt, DropCtl); 225 215 end; … … 332 322 OnClick := CloseButtonClick; 333 323 end; 324 ClientAreaPanel := TPanel.Create(Self); 325 with ClientAreaPanel do begin 326 Parent := Self; 327 Visible := True; 328 DockSite := True; 329 UseDockManager := True; 330 Left := 0; 331 Top := GrabberSize; 332 Width := Self.Width; 333 Height := Self.Height; 334 Anchors := [akTop, akBottom, akLeft, akRight]; 335 BevelInner := bvNone; 336 BevelOuter := bvNone; 337 end; 334 338 OnPaint := DockPanelPaint; 335 339 OnMouseDown := DockPanelMouseDown;
Note:
See TracChangeset
for help on using the changeset viewer.