Changeset 192 for Docking/CoolDocking/UCDManager.pas
- Timestamp:
- Mar 11, 2011, 10:44:06 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Docking/CoolDocking/UCDManager.pas
r191 r192 26 26 FDockPanels: TCDPanels; 27 27 function GetDockSite: TWinControl; 28 function GetDockStyle: TCDStyleType;29 28 function GetHeaderPos: THeaderPos; 30 29 function GetMoveDuration: Integer; 31 procedure InsertControlPanel(Control: TControl; InsertAt: TAlign;32 DropCtl: TControl);33 30 procedure SetDockStyle(const AValue: TCDStyleType); 34 31 procedure SetHeaderPos(const AValue: THeaderPos); … … 43 40 procedure ChangeVisible(Control: TWinControl; Visible: Boolean); virtual; 44 41 procedure Assign(Source: TCDManager); virtual; 42 procedure InsertControlPanel(Control: TControl; InsertAt: TAlign; 43 DropCtl: TControl); virtual; 45 44 46 45 // Inherited from TDockManager … … 68 67 function CreateContainer(InsertAt: TAlign): TCDConjoinForm; 69 68 property DockPanels: TCDPanels read FDockPanels write FDockPanels; 70 property DockStyle: TCDStyleType read GetDockStyle write SetDockStyle;69 property DockStyle: TCDStyleType read FDockStyle write SetDockStyle; 71 70 property MoveDuration: Integer read GetMoveDuration write SetMoveDuration; 72 71 property DockSite: TWinControl read GetDockSite; … … 79 78 80 79 uses 81 UCD StyleRegions, UCDStyleTabs, UCDStylePopupRegions, UCDStylePopupTabs;80 UCDManagerRegions, UCDManagerTabs, UCDManagerRegionsPopup, UCDManagerTabsPopup; 82 81 83 82 { TCDManager } … … 100 99 end; 101 100 102 function TCDManager.GetDockStyle: TCDStyleType;103 begin104 if Self is TCDStyleRegions then Result := dsList105 else if Self is TCDStyleTabs then Result := dsTabs106 else if Self is TCDStylePopupRegions then Result := dsPopupList107 else if Self is TCDStylePopupTabs then Result := dsPopupTabs;108 end;109 110 101 function TCDManager.GetHeaderPos: THeaderPos; 111 102 begin … … 124 115 begin 125 116 inherited Create(ADockSite); 117 126 118 FDockSite := ADockSite; 127 119 FDockPanels := TCDPanels.Create; 128 120 129 FDockStyle := dsTabs; // To initialize style value have to be different 130 DockStyle := dsList; 121 FDockStyle := dsList; // dsNone 131 122 PopupMenu := TCDPopupMenu.Create(Self); 132 123 PopupMenu.Parent := ADockSite; … … 168 159 DropCtl: TControl); 169 160 begin 170 //DockStyleHandler.InsertControl(Control, InsertAt);171 161 end; 172 162 … … 325 315 FDockStyle := AValue; 326 316 if AValue = dsTabs then begin 327 NewManager := TCDStyleTabs.Create( Self);317 NewManager := TCDStyleTabs.Create(FDockSite); 328 318 TCDStyleTabs(Self).TabControlChange(Self); 329 319 end else 330 320 if AValue = dsList then begin 331 NewManager := TCDStyleRegions.Create( Self);321 NewManager := TCDStyleRegions.Create(FDockSite); 332 322 end else 333 323 if AValue = dsPopupList then begin 334 NewManager := TCDStylePopupRegions.Create( Self);324 NewManager := TCDStylePopupRegions.Create(FDockSite); 335 325 end else 336 326 if AValue = dsPopupTabs then begin 337 NewManager := TCDStylePopupTabs.Create( Self);327 NewManager := TCDStylePopupTabs.Create(FDockSite); 338 328 end; 339 329 if DockSite.DockManager is TCDManager then … … 364 354 procedure TCDManager.UpdateClientSize; 365 355 begin 366 // DockStyleHandler.UpdateClientSize;367 356 end; 368 357
Note:
See TracChangeset
for help on using the changeset viewer.