Changeset 191


Ignore:
Timestamp:
Mar 11, 2011, 10:07:38 AM (14 years ago)
Author:
george
Message:
  • Modified: Classes which iherits from TCDStyle changed to inherit from TCDManager. Now all styles will be different dock managers. Field DockStyleHanler of TCDManager removed and DockStyle property changes TCDManager descendends.
Location:
Docking/CoolDocking
Files:
3 deleted
13 edited

Legend:

Unmodified
Added
Removed
  • Docking/CoolDocking/CoolDocking.lpk

    r189 r191  
    2424    </CompilerOptions>
    2525    <Description Value="Set of components for docking of windows."/>
    26     <Version Minor="2"/>
    27     <Files Count="17">
     26    <License Value="GNU/GPL"/>
     27    <Version Minor="3"/>
     28    <Files Count="16">
    2829      <Item1>
    2930        <Filename Value="UCDClient.pas"/>
     
    6162      </Item8>
    6263      <Item9>
    63         <Filename Value="UCDStyle.pas"/>
    64         <UnitName Value="UCDStyle"/>
     64        <Filename Value="UCDClientPanel.pas"/>
     65        <UnitName Value="UCDClientPanel"/>
    6566      </Item9>
    6667      <Item10>
    67         <Filename Value="UCDClientPanel.pas"/>
    68         <UnitName Value="UCDClientPanel"/>
     68        <Filename Value="UCDPopupMenu.pas"/>
     69        <UnitName Value="UCDPopupMenu"/>
    6970      </Item10>
    7071      <Item11>
    71         <Filename Value="UCDPopupMenu.pas"/>
    72         <UnitName Value="UCDPopupMenu"/>
    73       </Item11>
    74       <Item12>
    7572        <Filename Value="UCDLayout.pas"/>
    7673        <HasRegisterProc Value="True"/>
    7774        <UnitName Value="UCDLayout"/>
     75      </Item11>
     76      <Item12>
     77        <Filename Value="URectangle.pas"/>
     78        <UnitName Value="URectangle"/>
    7879      </Item12>
    7980      <Item13>
    80         <Filename Value="URectangle.pas"/>
    81         <UnitName Value="URectangle"/>
     81        <Filename Value="UCDCommon.pas"/>
     82        <UnitName Value="UCDCommon"/>
    8283      </Item13>
    8384      <Item14>
    84         <Filename Value="UCDCommon.pas"/>
    85         <UnitName Value="UCDCommon"/>
     85        <Filename Value="UCDManager.pas"/>
     86        <UnitName Value="UCDManager"/>
    8687      </Item14>
    8788      <Item15>
    88         <Filename Value="UCDManager.pas"/>
    89         <UnitName Value="UCDManager"/>
     89        <Filename Value="UCDConjoinForm.pas"/>
     90        <UnitName Value="UCDConjoinForm"/>
    9091      </Item15>
    9192      <Item16>
    92         <Filename Value="UCDConjoinForm.pas"/>
    93         <UnitName Value="UCDConjoinForm"/>
    94       </Item16>
    95       <Item17>
    9693        <Filename Value="UCDMaster.pas"/>
    9794        <HasRegisterProc Value="True"/>
    9895        <UnitName Value="UCDMaster"/>
    99       </Item17>
     96      </Item16>
    10097    </Files>
    10198    <i18n>
  • Docking/CoolDocking/CoolDocking.pas

    r189 r191  
    99uses
    1010  UCDClient, UCDCustomize, UCDWindowList, UCDStyleTabs, UCDStyleRegions,
    11   UCDStylePopupTabs, UCDStylePopupRegions, UCDStyle, UCDClientPanel,
    12   UCDPopupMenu, UCDLayout, URectangle, UCDCommon, UCDManager, UCDConjoinForm,
    13   UCDMaster, LazarusPackageIntf;
     11  UCDStylePopupTabs, UCDStylePopupRegions, UCDClientPanel, UCDPopupMenu,
     12  UCDLayout, URectangle, UCDCommon, UCDManager, UCDConjoinForm, UCDMaster,
     13  LazarusPackageIntf;
    1414
    1515implementation
  • Docking/CoolDocking/Demo/IDE/IDE.lpi

    r190 r191  
    4343      </Item3>
    4444    </RequiredPackages>
    45     <Units Count="62">
     45    <Units Count="63">
    4646      <Unit0>
    4747        <Filename Value="IDE.lpr"/>
    4848        <IsPartOfProject Value="True"/>
    4949        <UnitName Value="IDE"/>
    50         <EditorIndex Value="30"/>
     50        <EditorIndex Value="32"/>
    5151        <WindowIndex Value="0"/>
    5252        <TopLine Value="1"/>
    5353        <CursorPos X="1" Y="1"/>
    54         <UsageCount Value="128"/>
     54        <UsageCount Value="129"/>
    5555        <Loaded Value="True"/>
    5656      </Unit0>
     
    6161        <ResourceBaseClass Value="Form"/>
    6262        <UnitName Value="UMainForm"/>
    63         <EditorIndex Value="31"/>
     63        <EditorIndex Value="33"/>
    6464        <WindowIndex Value="0"/>
    6565        <TopLine Value="1"/>
    6666        <CursorPos X="18" Y="3"/>
    67         <UsageCount Value="128"/>
     67        <UsageCount Value="129"/>
    6868        <Loaded Value="True"/>
    6969      </Unit1>
     
    7878        <TopLine Value="1"/>
    7979        <CursorPos X="31" Y="17"/>
    80         <UsageCount Value="128"/>
     80        <UsageCount Value="129"/>
    8181        <Loaded Value="True"/>
    8282      </Unit2>
     
    9191        <TopLine Value="4"/>
    9292        <CursorPos X="37" Y="17"/>
    93         <UsageCount Value="128"/>
     93        <UsageCount Value="129"/>
    9494        <Loaded Value="True"/>
    9595      </Unit3>
     
    104104        <TopLine Value="4"/>
    105105        <CursorPos X="37" Y="17"/>
    106         <UsageCount Value="128"/>
     106        <UsageCount Value="129"/>
    107107        <Loaded Value="True"/>
    108108      </Unit4>
    109109      <Unit5>
    110110        <Filename Value="E:\Projekty2\FreePascalManager\trunk\Instance\1\Lazarus\lcl\include\control.inc"/>
    111         <IsVisibleTab Value="True"/>
    112111        <EditorIndex Value="7"/>
    113112        <WindowIndex Value="0"/>
    114113        <TopLine Value="3176"/>
    115         <CursorPos X="1" Y="3189"/>
    116         <UsageCount Value="60"/>
     114        <CursorPos X="46" Y="3187"/>
     115        <UsageCount Value="61"/>
    117116        <Loaded Value="True"/>
    118117      </Unit5>
     
    127126        <TopLine Value="4"/>
    128127        <CursorPos X="24" Y="17"/>
    129         <UsageCount Value="128"/>
     128        <UsageCount Value="129"/>
    130129        <Loaded Value="True"/>
    131130      </Unit6>
     
    147146        <TopLine Value="4"/>
    148147        <CursorPos X="25" Y="17"/>
    149         <UsageCount Value="128"/>
     148        <UsageCount Value="129"/>
    150149        <Loaded Value="True"/>
    151150      </Unit8>
     
    160159        <TopLine Value="3"/>
    161160        <CursorPos X="37" Y="16"/>
    162         <UsageCount Value="128"/>
     161        <UsageCount Value="129"/>
    163162        <Loaded Value="True"/>
    164163        <LoadedDesigner Value="True"/>
     
    174173        <TopLine Value="5"/>
    175174        <CursorPos X="37" Y="18"/>
    176         <UsageCount Value="128"/>
     175        <UsageCount Value="129"/>
    177176        <Loaded Value="True"/>
    178177      </Unit10>
     
    187186        <TopLine Value="4"/>
    188187        <CursorPos X="26" Y="17"/>
    189         <UsageCount Value="128"/>
     188        <UsageCount Value="129"/>
    190189        <Loaded Value="True"/>
    191190      </Unit11>
     
    200199        <TopLine Value="5"/>
    201200        <CursorPos X="37" Y="18"/>
    202         <UsageCount Value="128"/>
     201        <UsageCount Value="129"/>
    203202        <Loaded Value="True"/>
    204203      </Unit12>
     
    213212        <TopLine Value="4"/>
    214213        <CursorPos X="37" Y="17"/>
    215         <UsageCount Value="128"/>
     214        <UsageCount Value="129"/>
    216215        <Loaded Value="True"/>
    217216      </Unit13>
     
    225224        <TopLine Value="6"/>
    226225        <CursorPos X="75" Y="7"/>
    227         <UsageCount Value="126"/>
     226        <UsageCount Value="127"/>
    228227      </Unit14>
    229228      <Unit15>
     
    232231        <EditorIndex Value="0"/>
    233232        <WindowIndex Value="0"/>
    234         <TopLine Value="8"/>
    235         <CursorPos X="12" Y="21"/>
    236         <UsageCount Value="63"/>
     233        <TopLine Value="1"/>
     234        <CursorPos X="25" Y="14"/>
     235        <UsageCount Value="64"/>
    237236        <Loaded Value="True"/>
    238237      </Unit15>
     
    240239        <Filename Value="..\..\UCDLayout.pas"/>
    241240        <UnitName Value="UCDLayout"/>
     241        <IsVisibleTab Value="True"/>
    242242        <EditorIndex Value="23"/>
    243243        <WindowIndex Value="0"/>
    244         <TopLine Value="130"/>
    245         <CursorPos X="18" Y="131"/>
    246         <UsageCount Value="63"/>
     244        <TopLine Value="45"/>
     245        <CursorPos X="45" Y="52"/>
     246        <UsageCount Value="64"/>
    247247        <Loaded Value="True"/>
    248248      </Unit16>
    249249      <Unit17>
    250250        <Filename Value="E:\Projekty2\FreePascalManager\trunk\Instance\1\FPC\rtl\objpas\classes\classesh.inc"/>
    251         <WindowIndex Value="0"/>
    252         <TopLine Value="1644"/>
    253         <CursorPos X="14" Y="1657"/>
     251        <EditorIndex Value="28"/>
     252        <WindowIndex Value="0"/>
     253        <TopLine Value="376"/>
     254        <CursorPos X="41" Y="389"/>
    254255        <UsageCount Value="35"/>
     256        <Loaded Value="True"/>
    255257      </Unit17>
    256258      <Unit18>
     
    276278        <TopLine Value="110"/>
    277279        <CursorPos X="18" Y="126"/>
    278         <UsageCount Value="26"/>
     280        <UsageCount Value="27"/>
    279281        <Loaded Value="True"/>
    280282      </Unit20>
     
    297299        <TopLine Value="2"/>
    298300        <CursorPos X="20" Y="15"/>
    299         <UsageCount Value="10"/>
     301        <UsageCount Value="11"/>
    300302        <Loaded Value="True"/>
    301303        <LoadedDesigner Value="True"/>
     
    304306        <Filename Value="E:\Projekty2\FreePascalManager\trunk\Instance\1\Lazarus\lcl\forms.pp"/>
    305307        <UnitName Value="Forms"/>
    306         <EditorIndex Value="27"/>
     308        <EditorIndex Value="29"/>
    307309        <WindowIndex Value="0"/>
    308310        <TopLine Value="1623"/>
    309311        <CursorPos X="24" Y="1636"/>
    310         <UsageCount Value="32"/>
     312        <UsageCount Value="33"/>
    311313        <Loaded Value="True"/>
    312314      </Unit23>
     
    343345        <Filename Value="E:\Projekty2\FreePascalManager\trunk\Instance\1\Lazarus\lcl\controls.pp"/>
    344346        <UnitName Value="Controls"/>
    345         <EditorIndex Value="29"/>
    346         <WindowIndex Value="0"/>
    347         <TopLine Value="497"/>
     347        <EditorIndex Value="31"/>
     348        <WindowIndex Value="0"/>
     349        <TopLine Value="521"/>
    348350        <CursorPos X="3" Y="504"/>
    349         <UsageCount Value="36"/>
     351        <UsageCount Value="37"/>
    350352        <Loaded Value="True"/>
    351353      </Unit28>
    352354      <Unit29>
    353355        <Filename Value="E:\Projekty2\FreePascalManager\trunk\Instance\1\Lazarus\lcl\include\wincontrol.inc"/>
    354         <WindowIndex Value="0"/>
    355         <TopLine Value="7763"/>
    356         <CursorPos X="1" Y="7776"/>
     356        <EditorIndex Value="27"/>
     357        <WindowIndex Value="0"/>
     358        <TopLine Value="5374"/>
     359        <CursorPos X="38" Y="5384"/>
    357360        <UsageCount Value="29"/>
     361        <Loaded Value="True"/>
    358362      </Unit29>
    359363      <Unit30>
     
    374378        <TopLine Value="36"/>
    375379        <CursorPos X="35" Y="49"/>
    376         <UsageCount Value="49"/>
     380        <UsageCount Value="50"/>
    377381        <Loaded Value="True"/>
    378382      </Unit31>
     
    382386        <EditorIndex Value="22"/>
    383387        <WindowIndex Value="0"/>
    384         <TopLine Value="1"/>
    385         <CursorPos X="15" Y="11"/>
    386         <UsageCount Value="54"/>
     388        <TopLine Value="7"/>
     389        <CursorPos X="30" Y="20"/>
     390        <UsageCount Value="55"/>
    387391        <Loaded Value="True"/>
    388392      </Unit32>
     
    392396        <EditorIndex Value="20"/>
    393397        <WindowIndex Value="0"/>
    394         <TopLine Value="20"/>
    395         <CursorPos X="15" Y="15"/>
    396         <UsageCount Value="48"/>
     398        <TopLine Value="237"/>
     399        <CursorPos X="25" Y="250"/>
     400        <UsageCount Value="49"/>
    397401        <Loaded Value="True"/>
    398402      </Unit33>
     
    444448        <Filename Value="..\..\UCDStyle.pas"/>
    445449        <UnitName Value="UCDStyle"/>
    446         <EditorIndex Value="17"/>
    447         <WindowIndex Value="0"/>
    448         <TopLine Value="22"/>
    449         <CursorPos X="13" Y="14"/>
     450        <WindowIndex Value="0"/>
     451        <TopLine Value="1"/>
     452        <CursorPos X="24" Y="16"/>
    450453        <UsageCount Value="37"/>
    451         <Loaded Value="True"/>
    452454      </Unit40>
    453455      <Unit41>
     
    456458        <EditorIndex Value="13"/>
    457459        <WindowIndex Value="0"/>
    458         <TopLine Value="14"/>
    459         <CursorPos X="27" Y="27"/>
    460         <UsageCount Value="37"/>
     460        <TopLine Value="92"/>
     461        <CursorPos X="15" Y="102"/>
     462        <UsageCount Value="38"/>
    461463        <Loaded Value="True"/>
    462464      </Unit41>
     
    474476        <EditorIndex Value="14"/>
    475477        <WindowIndex Value="0"/>
    476         <TopLine Value="336"/>
    477         <CursorPos X="18" Y="91"/>
    478         <UsageCount Value="36"/>
     478        <TopLine Value="8"/>
     479        <CursorPos X="32" Y="15"/>
     480        <UsageCount Value="37"/>
    479481        <Loaded Value="True"/>
    480482      </Unit43>
     
    507509        <EditorIndex Value="12"/>
    508510        <WindowIndex Value="0"/>
    509         <TopLine Value="1"/>
    510         <CursorPos X="23" Y="12"/>
    511         <UsageCount Value="35"/>
     511        <TopLine Value="195"/>
     512        <CursorPos X="1" Y="208"/>
     513        <UsageCount Value="36"/>
    512514        <Loaded Value="True"/>
    513515      </Unit47>
     
    515517        <Filename Value="..\..\UCDStylePopupTabs.pas"/>
    516518        <UnitName Value="UCDStylePopupTabs"/>
    517         <EditorIndex Value="15"/>
    518         <WindowIndex Value="0"/>
    519         <TopLine Value="41"/>
    520         <CursorPos X="20" Y="42"/>
    521         <UsageCount Value="26"/>
     519        <EditorIndex Value="16"/>
     520        <WindowIndex Value="0"/>
     521        <TopLine Value="1"/>
     522        <CursorPos X="17" Y="9"/>
     523        <UsageCount Value="27"/>
    522524        <Loaded Value="True"/>
    523525      </Unit48>
     
    568570        <TopLine Value="23"/>
    569571        <CursorPos X="15" Y="24"/>
    570         <UsageCount Value="29"/>
     572        <UsageCount Value="30"/>
    571573      </Unit54>
    572574      <Unit55>
    573575        <Filename Value="..\..\UCDStylePopupRegions.pas"/>
    574576        <UnitName Value="UCDStylePopupRegions"/>
    575         <EditorIndex Value="16"/>
    576         <WindowIndex Value="0"/>
    577         <TopLine Value="1"/>
    578         <CursorPos X="23" Y="11"/>
    579         <UsageCount Value="10"/>
     577        <EditorIndex Value="17"/>
     578        <WindowIndex Value="0"/>
     579        <TopLine Value="1"/>
     580        <CursorPos X="37" Y="8"/>
     581        <UsageCount Value="11"/>
    580582        <Loaded Value="True"/>
    581583      </Unit55>
     
    583585        <Filename Value="E:\Projekty2\FreePascalManager\trunk\Instance\1\FPC\packages\fcl-base\src\custapp.pp"/>
    584586        <UnitName Value="CustApp"/>
    585         <EditorIndex Value="28"/>
     587        <EditorIndex Value="30"/>
    586588        <WindowIndex Value="0"/>
    587589        <TopLine Value="13"/>
    588590        <CursorPos X="3" Y="26"/>
    589         <UsageCount Value="11"/>
     591        <UsageCount Value="12"/>
    590592        <Loaded Value="True"/>
    591593      </Unit56>
     
    595597        <EditorIndex Value="26"/>
    596598        <WindowIndex Value="0"/>
    597         <TopLine Value="59"/>
    598         <CursorPos X="12" Y="18"/>
    599         <UsageCount Value="11"/>
     599        <TopLine Value="325"/>
     600        <CursorPos X="7" Y="341"/>
     601        <UsageCount Value="12"/>
    600602        <Loaded Value="True"/>
    601603      </Unit57>
     
    607609        <TopLine Value="1"/>
    608610        <CursorPos X="17" Y="13"/>
    609         <UsageCount Value="10"/>
     611        <UsageCount Value="11"/>
    610612        <Loaded Value="True"/>
    611613      </Unit58>
     
    623625        <EditorIndex Value="18"/>
    624626        <WindowIndex Value="0"/>
    625         <TopLine Value="25"/>
    626         <CursorPos X="9" Y="59"/>
    627         <UsageCount Value="10"/>
     627        <TopLine Value="1"/>
     628        <CursorPos X="33" Y="8"/>
     629        <UsageCount Value="11"/>
    628630        <Loaded Value="True"/>
    629631      </Unit60>
     
    636638        <UsageCount Value="10"/>
    637639      </Unit61>
     640      <Unit62>
     641        <Filename Value="E:\Projekty2\FreePascalManager\trunk\Instance\1\Lazarus\lcl\comctrls.pp"/>
     642        <UnitName Value="ComCtrls"/>
     643        <EditorIndex Value="15"/>
     644        <WindowIndex Value="0"/>
     645        <TopLine Value="296"/>
     646        <CursorPos X="14" Y="309"/>
     647        <UsageCount Value="10"/>
     648        <Loaded Value="True"/>
     649      </Unit62>
    638650    </Units>
    639     <JumpHistory Count="30" HistoryIndex="29">
     651    <JumpHistory Count="28" HistoryIndex="26">
    640652      <Position1>
    641         <Filename Value="UObjectInspectorForm.pas"/>
    642         <Caret Line="18" Column="5" TopLine="5"/>
     653        <Filename Value="..\..\UCDPopupMenu.pas"/>
     654        <Caret Line="15" Column="15" TopLine="20"/>
    643655      </Position1>
    644656      <Position2>
    645         <Filename Value="UProjectManagerForm.pas"/>
    646         <Caret Line="9" Column="12" TopLine="1"/>
     657        <Filename Value="..\..\UCDPopupMenu.pas"/>
     658        <Caret Line="202" Column="18" TopLine="189"/>
    647659      </Position2>
    648660      <Position3>
    649         <Filename Value="UStructureForm.pas"/>
    650         <Caret Line="9" Column="13" TopLine="1"/>
     661        <Filename Value="..\..\UCDPopupMenu.pas"/>
     662        <Caret Line="214" Column="18" TopLine="201"/>
    651663      </Position3>
    652664      <Position4>
    653         <Filename Value="UMessagesForm.pas"/>
    654         <Caret Line="9" Column="12" TopLine="1"/>
     665        <Filename Value="..\..\UCDPopupMenu.pas"/>
     666        <Caret Line="226" Column="25" TopLine="213"/>
    655667      </Position4>
    656668      <Position5>
    657         <Filename Value="UMessagesForm.pas"/>
    658         <Caret Line="17" Column="25" TopLine="4"/>
     669        <Filename Value="..\..\UCDPopupMenu.pas"/>
     670        <Caret Line="238" Column="25" TopLine="225"/>
    659671      </Position5>
    660672      <Position6>
    661         <Filename Value="UCallStackForm.pas"/>
    662         <Caret Line="8" Column="77" TopLine="1"/>
     673        <Filename Value="..\..\UCDClientPanel.pas"/>
     674        <Caret Line="27" Column="27" TopLine="14"/>
    663675      </Position6>
    664676      <Position7>
    665         <Filename Value="ULocalVariablesForm.pas"/>
    666         <Caret Line="9" Column="5" TopLine="1"/>
     677        <Filename Value="..\..\UCDClientPanel.pas"/>
     678        <Caret Line="70" Column="14" TopLine="57"/>
    667679      </Position7>
    668680      <Position8>
    669         <Filename Value="UToDoListForm.pas"/>
    670         <Caret Line="9" Column="6" TopLine="1"/>
     681        <Filename Value="..\..\UCDClientPanel.pas"/>
     682        <Caret Line="86" Column="1" TopLine="73"/>
    671683      </Position8>
    672684      <Position9>
    673         <Filename Value="UToDoListForm.pas"/>
    674         <Caret Line="17" Column="37" TopLine="4"/>
     685        <Filename Value="..\..\UCDClientPanel.pas"/>
     686        <Caret Line="99" Column="1" TopLine="86"/>
    675687      </Position9>
    676688      <Position10>
    677         <Filename Value="UWatchListForm.pas"/>
    678         <Caret Line="9" Column="12" TopLine="1"/>
     689        <Filename Value="..\..\UCDClientPanel.pas"/>
     690        <Caret Line="100" Column="1" TopLine="87"/>
    679691      </Position10>
    680692      <Position11>
    681         <Filename Value="UThreadStatusForm.pas"/>
    682         <Caret Line="1" Column="1" TopLine="1"/>
     693        <Filename Value="..\..\UCDClientPanel.pas"/>
     694        <Caret Line="98" Column="16" TopLine="89"/>
    683695      </Position11>
    684696      <Position12>
    685         <Filename Value="..\..\UCDCustomize.pas"/>
    686         <Caret Line="49" Column="12" TopLine="46"/>
     697        <Filename Value="..\..\UCDStyleTabs.pas"/>
     698        <Caret Line="15" Column="27" TopLine="14"/>
    687699      </Position12>
    688700      <Position13>
    689         <Filename Value="..\..\UCDWindowList.pas"/>
    690         <Caret Line="36" Column="12" TopLine="25"/>
     701        <Filename Value="..\..\UCDManager.pas"/>
     702        <Caret Line="42" Column="47" TopLine="24"/>
    691703      </Position13>
    692704      <Position14>
    693         <Filename Value="..\..\UCDWindowList.pas"/>
    694         <Caret Line="15" Column="16" TopLine="11"/>
     705        <Filename Value="..\..\UCDClientPanel.pas"/>
     706        <Caret Line="98" Column="16" TopLine="89"/>
    695707      </Position14>
    696708      <Position15>
    697         <Filename Value="..\..\UCDStyleTabs.pas"/>
    698         <Caret Line="15" Column="11" TopLine="2"/>
     709        <Filename Value="..\..\UCDClientPanel.pas"/>
     710        <Caret Line="102" Column="15" TopLine="92"/>
    699711      </Position15>
    700712      <Position16>
    701         <Filename Value="..\..\UCDStyleRegions.pas"/>
    702         <Caret Line="12" Column="14" TopLine="5"/>
     713        <Filename Value="..\..\UCDStyleTabs.pas"/>
     714        <Caret Line="15" Column="32" TopLine="8"/>
    703715      </Position16>
    704716      <Position17>
    705         <Filename Value="..\..\UCDStylePopupTabs.pas"/>
    706         <Caret Line="14" Column="10" TopLine="1"/>
     717        <Filename Value="..\..\UCDManager.pas"/>
     718        <Caret Line="43" Column="78" TopLine="30"/>
    707719      </Position17>
    708720      <Position18>
    709         <Filename Value="..\..\UCDStylePopupTabs.pas"/>
    710         <Caret Line="42" Column="14" TopLine="22"/>
     721        <Filename Value="..\..\UCDMaster.pas"/>
     722        <Caret Line="59" Column="9" TopLine="25"/>
    711723      </Position18>
    712724      <Position19>
    713         <Filename Value="..\..\UCDStylePopupRegions.pas"/>
    714         <Caret Line="11" Column="8" TopLine="1"/>
     725        <Filename Value="..\..\UCDMaster.pas"/>
     726        <Caret Line="8" Column="33" TopLine="1"/>
    715727      </Position19>
    716728      <Position20>
    717         <Filename Value="..\..\UCDClientPanel.pas"/>
    718         <Caret Line="19" Column="7" TopLine="1"/>
     729        <Filename Value="..\..\UCDManager.pas"/>
     730        <Caret Line="340" Column="27" TopLine="327"/>
    719731      </Position20>
    720732      <Position21>
    721         <Filename Value="..\..\UCDClientPanel.pas"/>
    722         <Caret Line="35" Column="17" TopLine="22"/>
     733        <Filename Value="..\..\UCDManager.pas"/>
     734        <Caret Line="44" Column="15" TopLine="31"/>
    723735      </Position21>
    724736      <Position22>
    725         <Filename Value="..\..\UCDClientPanel.pas"/>
    726         <Caret Line="17" Column="6" TopLine="4"/>
     737        <Filename Value="..\..\UCDManager.pas"/>
     738        <Caret Line="382" Column="40" TopLine="375"/>
    727739      </Position22>
    728740      <Position23>
    729741        <Filename Value="..\..\UCDManager.pas"/>
    730         <Caret Line="308" Column="67" TopLine="295"/>
     742        <Caret Line="384" Column="16" TopLine="375"/>
    731743      </Position23>
    732744      <Position24>
    733         <Filename Value="..\..\UCDStyleTabs.pas"/>
    734         <Caret Line="15" Column="15" TopLine="2"/>
     745        <Filename Value="..\..\UCDManager.pas"/>
     746        <Caret Line="385" Column="33" TopLine="371"/>
    735747      </Position24>
    736748      <Position25>
    737         <Filename Value="..\..\UCDPopupMenu.pas"/>
    738         <Caret Line="15" Column="10" TopLine="1"/>
     749        <Filename Value="..\..\UCDManager.pas"/>
     750        <Caret Line="344" Column="21" TopLine="331"/>
    739751      </Position25>
    740752      <Position26>
    741753        <Filename Value="..\..\UCDManager.pas"/>
    742         <Caret Line="81" Column="20" TopLine="75"/>
     754        <Caret Line="343" Column="1" TopLine="331"/>
    743755      </Position26>
    744756      <Position27>
    745757        <Filename Value="..\..\UCDManager.pas"/>
    746         <Caret Line="18" Column="15" TopLine="11"/>
     758        <Caret Line="341" Column="7" TopLine="325"/>
    747759      </Position27>
    748760      <Position28>
    749         <Filename Value="..\..\UCDConjoinForm.pas"/>
    750         <Caret Line="13" Column="6" TopLine="1"/>
     761        <Filename Value="..\..\UCDLayout.pas"/>
     762        <Caret Line="596" Column="1" TopLine="571"/>
    751763      </Position28>
    752       <Position29>
    753         <Filename Value="..\..\UCDMaster.pas"/>
    754         <Caret Line="13" Column="9" TopLine="2"/>
    755       </Position29>
    756       <Position30>
    757         <Filename Value="UCallStackForm.pas"/>
    758         <Caret Line="16" Column="37" TopLine="3"/>
    759       </Position30>
    760764    </JumpHistory>
    761765  </ProjectOptions>
  • Docking/CoolDocking/UCDClient.pas

    r189 r191  
    1212  UCDCustomize, DOM, XMLWrite, XMLRead, UCDCommon,
    1313  DateUtils, UCDStyleTabs, UCDStyleRegions, UCDStylePopupTabs,
    14   UCDStylePopupRegions, UCDStyle, UCDClientPanel,
     14  UCDStylePopupRegions, UCDClientPanel,
    1515  UCDPopupMenu, UCDManager;
    1616
  • Docking/CoolDocking/UCDClientPanel.pas

    r189 r191  
    6868
    6969uses
    70   UCDClient, UCDStyle, UCDManager;
     70  UCDClient, UCDManager;
    7171
    7272{ TCDClientPanel }
     
    8484  Temp: TControl;
    8585  Temp2: TControl;
    86   Temp3: TCDStyle;
    8786begin
    8887  Temp := TControl(Sender);
     
    9897    if Assigned(OwnerDockManager) then
    9998    with TCDManager(OwnerDockManager) do
    100     if Assigned(DockStyleHandler) then
    101     with DockStyleHandler do begin
    102       Temp3 := DockStyleHandler;
     99    begin
    103100      //UpdateClientSize;
    104101      if ControlVisible then
  • Docking/CoolDocking/UCDLayout.pas

    r189 r191  
    2121    HostDockSiteName: string;
    2222    Caption: string;
    23     Visible: Boolean;
     23    Visible: boolean;
    2424    Rect: TRectangle;
    2525    RestoredRect: TRectangle;
     
    2727    UndockSize: TPoint;
    2828    DockStyle: TCDStyleType;
    29     Processed: Boolean;
     29    Processed: boolean;
    3030    procedure SaveToNode(Node: TDOMNode);
    3131    procedure LoadFromNode(Node: TDOMNode);
     
    7979function FindGlobalComponentDeep(Name: string): TComponent;
    8080var
    81   I: Integer;
    82 begin
    83   for I := 0 to Application.ComponentCount - 1 do begin
     81  I: integer;
     82begin
     83  for I := 0 to Application.ComponentCount - 1 do
     84  begin
    8485    Result := Application.Components[I];
    85     if Result.Name = Name then Exit
    86       else begin
    87         Result := Result.FindComponent(Name);
    88         if Assigned(Result) and (Result.Name = Name) then Exit;
    89       end;
     86    if Result.Name = Name then
     87      Exit
     88    else
     89    begin
     90      Result := Result.FindComponent(Name);
     91      if Assigned(Result) and (Result.Name = Name) then
     92        Exit;
     93    end;
    9094  end;
    9195end;
     
    116120    ReadXMLFile(Doc, Stream);
    117121    Items.Clear;
    118     with Doc.DocumentElement do begin
     122    with Doc.DocumentElement do
     123    begin
    119124      NewNode := FindNode('Items');
    120125      if Assigned(NewNode) then
    121       with NewNode do begin
    122         Child := FirstChild;
    123         while Assigned(Child) do begin
    124           NewItem := TCDLayout.Create;
    125           NewItem.LoadFromNode(Child);
    126           Items.Add(NewItem);
    127           Child := Child.NextSibling;
     126        with NewNode do
     127        begin
     128          Child := FirstChild;
     129          while Assigned(Child) do
     130          begin
     131            NewItem := TCDLayout.Create;
     132            NewItem.LoadFromNode(Child);
     133            Items.Add(NewItem);
     134            Child := Child.NextSibling;
     135          end;
    128136        end;
    129       end;
    130137    end;
    131138  finally
     
    138145  Doc: TXMLDocument;
    139146  RootNode: TDOMNode;
    140   I: Integer;
     147  I: integer;
    141148  NewNode: TDOMNode;
    142149  NewNode2: TDOMNode;
     
    144151  try
    145152    Doc := TXMLDocument.Create;
    146     with Doc do begin
     153    with Doc do
     154    begin
    147155      RootNode := CreateElement('CoolDockLayout');
    148156      AppendChild(RootNode);
    149       with RootNode do begin
     157      with RootNode do
     158      begin
    150159        NewNode := OwnerDocument.CreateElement('Items');
    151160        with NewNode do
    152         for I := 0 to Items.Count - 1 do begin
    153           NewNode2 := OwnerDocument.CreateElement('Layout');
    154           TCDLayout(Items[I]).SaveToNode(NewNode2);
    155           AppendChild(NewNode2);
    156          end;
     161          for I := 0 to Items.Count - 1 do
     162          begin
     163            NewNode2 := OwnerDocument.CreateElement('Layout');
     164            TCDLayout(Items[I]).SaveToNode(NewNode2);
     165            AppendChild(NewNode2);
     166          end;
    157167        AppendChild(NewNode);
    158168      end;
     
    181191begin
    182192  try
    183     if FileExistsUTF8(FileName) then Stream := TFileStream.Create(FileName, fmOpenReadWrite)
    184       else Stream := TFileStream.Create(FileName, fmCreate);
     193    if FileExistsUTF8(FileName) then
     194      Stream := TFileStream.Create(FileName, fmOpenReadWrite)
     195    else
     196      Stream := TFileStream.Create(FileName, fmCreate);
    185197    Stream.Size := 0;
    186198    SaveToStream(Stream);
     
    192204procedure TCDLayoutList.PopulateStringList(List: TStrings);
    193205var
    194   I: Integer;
     206  I: integer;
    195207begin
    196208  List.Clear;
     
    201213function TCDLayoutList.FindByName(Name: string): TCDLayout;
    202214var
    203   I: Integer;
     215  I: integer;
    204216begin
    205217  I := 0;
    206   while (I < Items.Count) and (TCDLayout(Items[I]).Name <> Name) do Inc(I);
    207   if I < Items.Count then Result := TCDLayout(Items[I])
    208     else Result := nil;
     218  while (I < Items.Count) and (TCDLayout(Items[I]).Name <> Name) do
     219    Inc(I);
     220  if I < Items.Count then
     221    Result := TCDLayout(Items[I])
     222  else
     223    Result := nil;
    209224end;
    210225
     
    215230  NewNode: TDOMNode;
    216231begin
    217   with Node do begin
     232  with Node do
     233  begin
    218234    NewNode := OwnerDocument.CreateElement('Name');
    219235    NewNode.TextContent := UTF8Decode(Name);
     
    232248    AppendChild(NewNode);
    233249    NewNode := OwnerDocument.CreateElement('WindowState');
    234     NewNode.TextContent := IntToStr(Integer(WindowState));
     250    NewNode.TextContent := IntToStr(integer(WindowState));
    235251    AppendChild(NewNode);
    236252    NewNode := OwnerDocument.CreateElement('UndockWidth');
     
    256272    AppendChild(NewNode);
    257273    NewNode := OwnerDocument.CreateElement('DockStyle');
    258     NewNode.TextContent := IntToStr(Integer(DockStyle));
     274    NewNode.TextContent := IntToStr(integer(DockStyle));
    259275    AppendChild(NewNode);
    260276    NewNode := OwnerDocument.CreateElement('RestoredWidth');
     
    277293  NewNode: TDOMNode;
    278294begin
    279   with TDOMElement(Node) do begin
     295  with TDOMElement(Node) do
     296  begin
    280297    NewNode := FindNode('Name');
    281298    if Assigned(NewNode) then
     
    349366  Rect.Width := Form.Width;
    350367  Rect.Height := Form.Height;
    351   if Form is TForm then begin
     368  if Form is TForm then
     369  begin
    352370    RestoredRect.Left := TForm(Form).RestoredLeft;
    353371    RestoredRect.Top := TForm(Form).RestoredTop;
     
    358376  if Assigned(Form.Parent) then
    359377    ParentName := Form.Parent.Name
    360     else ParentName := '';
    361   if Assigned(Form.HostDockSite) then begin
     378  else
     379    ParentName := '';
     380  if Assigned(Form.HostDockSite) then
     381  begin
    362382    if Assigned(Form.HostDockSite) then
    363383    begin
    364384      HostDockSiteName := Form.HostDockSite.Name;
    365       if not Assigned(Parent.FindByName(HostDockSiteName)) then begin
     385      if not Assigned(Parent.FindByName(HostDockSiteName)) then
     386      begin
    366387        NewItem := TCDLayoutItem.Create;
    367388        NewItem.Parent := Parent;
     
    371392      end;
    372393    end;
    373   end else HostDockSiteName := '';
     394  end
     395  else
     396    HostDockSiteName := '';
    374397end;
    375398
     
    381404begin
    382405  if Form is TForm then
    383   if WindowState = wsMaximized then begin
    384     TForm(Form).SetRestoredBounds(RestoredRect.Left, RestoredRect.Top,
    385       RestoredRect.Width, RestoredRect.Height);
    386     TForm(Form).WindowState := WindowState;
    387   end else begin
    388     TForm(Form).WindowState := WindowState;
    389     TForm(Form).SetRestoredBounds(RestoredRect.Left, RestoredRect.Top,
    390       RestoredRect.Width, RestoredRect.Height);
    391   end;
     406    if WindowState = wsMaximized then
     407    begin
     408      TForm(Form).SetRestoredBounds(RestoredRect.Left, RestoredRect.Top,
     409        RestoredRect.Width, RestoredRect.Height);
     410      TForm(Form).WindowState := WindowState;
     411    end
     412    else
     413    begin
     414      TForm(Form).WindowState := WindowState;
     415      TForm(Form).SetRestoredBounds(RestoredRect.Left, RestoredRect.Top,
     416        RestoredRect.Width, RestoredRect.Height);
     417    end;
    392418  Form.Name := Name;
    393419  Form.Caption := Caption;
     
    396422  Form.UndockHeight := UndockSize.Y;
    397423  Form.Visible := Visible;
    398   if HostDockSiteName <> '' then begin
     424  if HostDockSiteName <> '' then
     425  begin
    399426    ParentComponent := FindGlobalComponentDeep(HostDockSiteName);
    400     if not Assigned(ParentComponent) then begin
     427    if not Assigned(ParentComponent) then
     428    begin
    401429      ParentLayoutItem := Parent.FindByName(HostDockSiteName);
    402       if Assigned(ParentLayoutItem) then begin
    403         if ParentLayoutItem.StoredClassName <> '' then begin
     430      if Assigned(ParentLayoutItem) then
     431      begin
     432        if ParentLayoutItem.StoredClassName <> '' then
     433        begin
    404434          //ParentComponent := TComponent(FindClass(ParentLayoutItem.StoredClassName).Create);
    405           if (ParentLayoutItem.StoredClassName = 'TCoolDockConjoinForm') then begin
    406             FormClass := TFormClass(FindClass('TCoolDockConjoinForm'));
    407             if FormClass = TCDConjoinForm then begin
     435          if (ParentLayoutItem.StoredClassName = 'TCDConjoinForm') then
     436          begin
     437            FormClass := TFormClass(FindClass('TCDConjoinForm'));
     438            if FormClass = TCDConjoinForm then
     439            begin
    408440              ParentComponent := TCDManager(Form.DockManager).CreateContainer(alNone);
    409               TCDManager(TCDConjoinForm(ParentComponent).DockManager).DockStyle := ParentLayoutItem.DockStyle;
     441              TCDManager(TCDConjoinForm(ParentComponent).DockManager).DockStyle :=
     442                ParentLayoutItem.DockStyle;
    410443              ParentLayoutItem.Restore(TWinControl(ParentComponent));
    411444            end;
     
    439472  NewNode: TDOMNode;
    440473  NewNode2: TDOMNode;
    441   I: Integer;
    442 begin
    443   with Node do begin
     474  I: integer;
     475begin
     476  with Node do
     477  begin
    444478    NewNode := OwnerDocument.CreateElement('Name');
    445479    NewNode.TextContent := UTF8Decode(Name);
     
    447481    NewNode := OwnerDocument.CreateElement('Items');
    448482    with NewNode do
    449     for I := 0 to Items.Count - 1 do begin
    450       NewNode2 := OwnerDocument.CreateElement('Form');
    451       TCDLayoutItem(Items[I]).SaveToNode(NewNode2);
    452       AppendChild(NewNode2);
    453     end;
     483      for I := 0 to Items.Count - 1 do
     484      begin
     485        NewNode2 := OwnerDocument.CreateElement('Form');
     486        TCDLayoutItem(Items[I]).SaveToNode(NewNode2);
     487        AppendChild(NewNode2);
     488      end;
    454489    AppendChild(NewNode);
    455490  end;
     
    462497  NewItem: TCDLayoutItem;
    463498begin
    464   with Node do begin
     499  with Node do
     500  begin
    465501    NewNode := FindNode('Name');
    466502    if Assigned(NewNode) then
     
    468504    NewNode := FindNode('Items');
    469505    if Assigned(NewNode) then
    470     with NewNode do begin
    471       Child := FirstChild;
    472       while Assigned(Child) do begin
    473         NewItem := TCDLayoutItem.Create;
    474         NewItem.Parent := Self;
    475         NewItem.LoadFromNode(Child);
    476         Items.Add(NewItem);
    477         Child := Child.NextSibling;
     506      with NewNode do
     507      begin
     508        Child := FirstChild;
     509        while Assigned(Child) do
     510        begin
     511          NewItem := TCDLayoutItem.Create;
     512          NewItem.Parent := Self;
     513          NewItem.LoadFromNode(Child);
     514          Items.Add(NewItem);
     515          Child := Child.NextSibling;
     516        end;
    478517      end;
    479     end;
    480518  end;
    481519end;
     
    483521function TCDLayout.FindByName(Name: string): TCDLayoutItem;
    484522var
    485   I: Integer;
     523  I: integer;
    486524begin
    487525  I := 0;
    488   while (I < Items.Count) and (TCDLayoutItem(Items[I]).Name <> Name) do Inc(I);
    489   if I < Items.Count then Result := TCDLayoutItem(Items[I])
    490     else Result := nil;
     526  while (I < Items.Count) and (TCDLayoutItem(Items[I]).Name <> Name) do
     527    Inc(I);
     528  if I < Items.Count then
     529    Result := TCDLayoutItem(Items[I])
     530  else
     531    Result := nil;
    491532end;
    492533
     
    504545procedure TCDLayout.Store;
    505546var
    506   I: Integer;
     547  I: integer;
    507548  Form: TForm;
    508549  NewItem: TCDLayoutItem;
     
    510551  Items.Clear;
    511552  for I := 0 to Application.ComponentCount - 1 do
    512   if (Application.Components[I] is TForm) then begin
    513     Form := (Application.Components[I] as TForm);
    514     NewItem := TCDLayoutItem.Create;
    515     NewItem.Parent := Self;
    516     NewItem.Store(Form);
    517     Items.Add(NewItem);
    518   end;
     553    if (Application.Components[I] is TForm) then
     554    begin
     555      Form := (Application.Components[I] as TForm);
     556      NewItem := TCDLayoutItem.Create;
     557      NewItem.Parent := Self;
     558      NewItem.Store(Form);
     559      Items.Add(NewItem);
     560    end;
    519561end;
    520562
     
    522564var
    523565  Form: TForm;
    524   I: Integer;
     566  I: integer;
    525567begin
    526568  // Undock all forms
    527569  I := 0;
    528   while (I < Application.ComponentCount) do begin
    529     if (Application.Components[I] is TForm) then begin
     570  while (I < Application.ComponentCount) do
     571  begin
     572    if (Application.Components[I] is TForm) then
     573    begin
    530574      Form := (Application.Components[I] as TForm);
    531575      if Assigned(Form.HostDockSite) then
    532         Form.ManualFloat(Rect(Form.Left, Form.Top, Form.Left + Form.Width, Form.Top + Form.Height));
     576        Form.ManualFloat(Rect(Form.Left, Form.Top, Form.Left +
     577          Form.Width, Form.Top + Form.Height));
    533578    end;
    534579    Inc(I);
     
    536581
    537582  for I := 0 to Items.Count - 1 do
    538   with TCDLayoutItem(Items[I]) do
    539     Processed := False;
     583    with TCDLayoutItem(Items[I]) do
     584      Processed := False;
    540585
    541586  for I := 0 to Items.Count - 1 do
    542   with TCDLayoutItem(Items[I]) do begin
    543     Form := TForm(Application.FindComponent(Name));
    544     if Assigned(Form) and (not Assigned(Form.HostDockSite)) and (not Processed) then Restore(Form);
    545   end;
     587    with TCDLayoutItem(Items[I]) do
     588    begin
     589      Form := TForm(Application.FindComponent(Name));
     590      if Assigned(Form) and (not Assigned(Form.HostDockSite)) and (not Processed) then
     591        Restore(Form);
     592    end;
    546593end;
    547594
  • Docking/CoolDocking/UCDManager.pas

    r189 r191  
    77uses
    88  Classes, SysUtils, UCDCommon, Controls, Contnrs, UCDClientPanel,
    9   UCDStyle, UCDPopupMenu, LCLType, LMessages, Graphics,
    10   UCDConjoinForm, Menus, StdCtrls, ExtCtrls, Forms,
    11   UCDStyleRegions, UCDStyleTabs, UCDStylePopupRegions,
    12   UCDStylePopupTabs;
     9  UCDPopupMenu, LCLType, LMessages, Graphics,
     10  UCDConjoinForm, Menus, StdCtrls, ExtCtrls, Forms;
    1311
    1412type
     
    2826    FDockPanels: TCDPanels;
    2927    function GetDockSite: TWinControl;
     28    function GetDockStyle: TCDStyleType;
    3029    function GetHeaderPos: THeaderPos;
    3130    function GetMoveDuration: Integer;
     
    3635    procedure SetMoveDuration(const AValue: Integer);
    3736    procedure SetVisible(const AValue: Boolean);
    38     procedure UpdateClientSize;
    3937  public
    40     DockStyleHandler: TCDStyle;
    4138    PopupMenu: TCDPopupMenu;
    4239    constructor Create(ADockSite: TWinControl); override;
    4340    destructor Destroy; override;
     41    procedure UpdateClientSize; virtual;
     42    procedure Switch(Index: Integer); virtual;
     43    procedure ChangeVisible(Control: TWinControl; Visible: Boolean); virtual;
     44    procedure Assign(Source: TCDManager); virtual;
    4445
    4546    // Inherited from TDockManager
     
    6768    function CreateContainer(InsertAt: TAlign): TCDConjoinForm;
    6869    property DockPanels: TCDPanels read FDockPanels write FDockPanels;
    69     property DockStyle: TCDStyleType read FDockStyle write SetDockStyle;
     70    property DockStyle: TCDStyleType read GetDockStyle write SetDockStyle;
    7071    property MoveDuration: Integer read GetMoveDuration write SetMoveDuration;
    7172    property DockSite: TWinControl read GetDockSite;
     
    7677
    7778implementation
     79
     80uses
     81  UCDStyleRegions, UCDStyleTabs, UCDStylePopupRegions, UCDStylePopupTabs;
    7882
    7983{ TCDManager }
     
    96100end;
    97101
     102function TCDManager.GetDockStyle: TCDStyleType;
     103begin
     104  if Self is TCDStyleRegions then Result := dsList
     105  else if Self is TCDStyleTabs then Result := dsTabs
     106  else if Self is TCDStylePopupRegions then Result := dsPopupList
     107  else if Self is TCDStylePopupTabs then Result := dsPopupTabs;
     108end;
     109
    98110function TCDManager.GetHeaderPos: THeaderPos;
    99111begin
     
    124136begin
    125137  PopupMenu.Free;
    126   DockStyleHandler.Free;
    127138  FDockPanels.Free;
    128139  inherited Destroy;
     
    157168  DropCtl: TControl);
    158169begin
    159   DockStyleHandler.InsertControl(Control, InsertAt);
     170  //DockStyleHandler.InsertControl(Control, InsertAt);
    160171end;
    161172
     
    250261  ClientPanel: TCDClientPanel;
    251262begin
    252   DockStyleHandler.RemoveControl(Control);
     263  //DockStyleHandler.RemoveControl(Control);
    253264  //inherited;
    254265(*  if Control.HostDockSite = Self.FDockSite then begin
     
    309320var
    310321  I: Integer;
     322  NewManager: TCDManager;
    311323begin
    312324  if FDockStyle <> AValue then begin
    313325    FDockStyle := AValue;
    314     FreeAndNil(DockStyleHandler);
    315326    if AValue = dsTabs then begin
    316       DockStyleHandler := TCDStyleTabs.Create(Self);
    317       TCDStyleTabs(DockStyleHandler).TabControlChange(Self);
     327      NewManager := TCDStyleTabs.Create(Self);
     328      TCDStyleTabs(Self).TabControlChange(Self);
    318329    end else
    319330    if AValue = dsList then begin
    320       DockStyleHandler := TCDStyleRegions.Create(Self);
     331      NewManager := TCDStyleRegions.Create(Self);
    321332    end else
    322333    if AValue = dsPopupList then begin
    323       DockStyleHandler := TCDStylePopupRegions.Create(Self);
     334      NewManager := TCDStylePopupRegions.Create(Self);
    324335    end else
    325336    if AValue = dsPopupTabs then begin
    326       DockStyleHandler := TCDStylePopupTabs.Create(Self);
    327     end;
     337      NewManager := TCDStylePopupTabs.Create(Self);
     338    end;
     339    if DockSite.DockManager is TCDManager then
     340      NewManager.Assign(TCDManager(DockSite.DockManager));
     341    DockSite.DockManager := NewManager;
    328342  end;
    329343  UpdateClientSize;
     
    343357  I: Integer;
    344358begin
    345   DockStyleHandler.Visible := AValue;
     359  Visible := AValue;
    346360//  for I := 0 to DockPanels.Count - 1 do
    347361//    TCDClientPanel(DockPanels[I]).Visible := AValue;
     
    350364procedure TCDManager.UpdateClientSize;
    351365begin
    352   DockStyleHandler.UpdateClientSize;
     366//  DockStyleHandler.UpdateClientSize;
     367end;
     368
     369procedure TCDManager.Switch(Index: Integer);
     370begin
     371
     372end;
     373
     374procedure TCDManager.ChangeVisible(Control: TWinControl; Visible: Boolean);
     375begin
     376
     377end;
     378
     379procedure TCDManager.Assign(Source: TCDManager);
     380begin
     381  FDockStyle := Source.FDockStyle;
     382  FDockSite := Source.FDockSite;
    353383end;
    354384
  • Docking/CoolDocking/UCDMaster.pas

    r189 r191  
    66
    77uses
    8   Classes, SysUtils, UCDCommon, UCDStyle, UCDClientPanel;
     8  Classes, SysUtils, UCDCommon, UCDClientPanel;
    99
    1010type
  • Docking/CoolDocking/UCDPopupMenu.pas

    r189 r191  
    200200  if PopupComponent is TPageControl then
    201201  with TPageControl(PopupComponent) do begin
    202     TCDStyleTabs(TCDManager(Manager).DockStyleHandler).TabsPos := hpAuto;
     202    TCDStyleTabs(Manager).TabsPos := hpAuto;
    203203  end else
    204204  if PopupComponent is TCDHeader then
     
    212212  if PopupComponent is TPageControl then
    213213  with TPageControl(PopupComponent) do begin
    214     TCDStyleTabs(TCDManager(Manager).DockStyleHandler).TabsPos := hpLeft;
     214    TCDStyleTabs(Manager).TabsPos := hpLeft;
    215215  end else
    216216  if PopupComponent is TCDHeader then
     
    224224  if PopupComponent is TPageControl then
    225225  with TPageControl(PopupComponent) do begin
    226     TCDStyleTabs(TCDManager(Manager).DockStyleHandler).TabsPos := hpRight;
     226    TCDStyleTabs(Manager).TabsPos := hpRight;
    227227  end else
    228228  if PopupComponent is TCDHeader then
     
    236236  if PopupComponent is TPageControl then
    237237  with TPageControl(PopupComponent) do begin
    238     TCDStyleTabs(TCDManager(Manager).DockStyleHandler).TabsPos := hpTop;
     238    TCDStyleTabs(Manager).TabsPos := hpTop;
    239239  end else
    240240  if PopupComponent is TCDHeader then
     
    248248  if PopupComponent is TPageControl then
    249249  with TPageControl(PopupComponent) do begin
    250     TCDStyleTabs(TCDManager(Manager).DockStyleHandler).TabsPos := hpBottom;
     250    TCDStyleTabs(Manager).TabsPos := hpBottom;
    251251  end else
    252252  if PopupComponent is TCDHeader then
  • Docking/CoolDocking/UCDStylePopupRegions.pas

    r189 r191  
    66
    77uses
    8   Classes, SysUtils, UCDStyleRegions, UCDStyle;
     8  Classes, SysUtils, UCDStyleRegions;
    99
    1010type
  • Docking/CoolDocking/UCDStylePopupTabs.pas

    r189 r191  
    77uses
    88  Classes, Controls, SysUtils, ComCtrls, ExtCtrls, UCDCommon,
    9   UCDStyleTabs, UCDStyle, UCDClientPanel;
     9  UCDStyleTabs, UCDClientPanel;
    1010
    1111type
  • Docking/CoolDocking/UCDStyleRegions.pas

    r189 r191  
    66
    77uses
    8   Classes, SysUtils, Controls, ExtCtrls, StdCtrls, UCDStyle, Forms,
    9   Graphics, Contnrs, Buttons, UCDClientPanel, UCDCommon;
     8  Classes, SysUtils, Controls, ExtCtrls, StdCtrls, Forms,
     9  Graphics, Contnrs, Buttons, UCDClientPanel, UCDCommon, UCDManager;
    1010
    1111type
     
    1616  { TCDStyleRegions }
    1717
    18   TCDStyleRegions = class(TCDStyle)
     18  TCDStyleRegions = class(TCDManager)
    1919  private
    2020    function GetDirection(InsertAt: TAlign): TCDDirection;
     
    2222    FDockDirection: TCDDirection;
    2323    //Panels: TObjectList; // TObjectList<TCDStyleRegionsPanel>
    24     procedure InsertControl(AControl: TControl; InsertAt: TAlign); override;
     24    procedure InsertControl(Control: TControl; InsertAt: TAlign;
     25      DropCtl: TControl); override;
    2526    procedure RemoveControl(Control: TControl); override;
    26     function GetHeaderPos: THeaderPos; override;
    27     procedure SetHeaderPos(const AValue: THeaderPos); override;
    2827    constructor Create(AManager: TCDManagerBase);
    2928    destructor Destroy; override;
    3029    procedure UpdateClientSize; override;
    31     procedure SetVisible(const AValue: Boolean); override;
    32     procedure ChangeVisible(Control: TWinControl; Visible: Boolean); override;
     30    procedure DoSetVisible(const AValue: Boolean);
     31    procedure ChangeVisible(Control: TWinControl; Visible: Boolean);
    3332    property DockDirection: TCDDirection read FDockDirection
    3433      write FDockDirection;
     
    3837
    3938uses
    40   UCDClient, UCDConjoinForm, UCDManager;
     39  UCDClient, UCDConjoinForm;
    4140
    4241
     
    5453end;
    5554
    56 procedure TCDStyleRegions.InsertControl(AControl: TControl; InsertAt: TAlign);
     55procedure TCDStyleRegions.InsertControl(Control: TControl; InsertAt: TAlign;
     56  DropCtl: TControl);
    5757var
    5858  NewPanel: TCDClientPanel;
     
    6363begin
    6464  inherited;
    65   with TCDManager(Manager) do begin
     65  begin
    6666    if DockSite.DockClientCount <= 2 then FDockDirection := GetDirection(InsertAt)
    6767    else
     
    7474        // FDockSite.ManualFloat(FDockSite.BoundsRect);
    7575        NewConjoinDockForm.ManualDock(NewDockSite);
    76         AControl.ManualDock(NewConjoinDockForm, nil, InsertAt);
     76        Control.ManualDock(NewConjoinDockForm, nil, InsertAt);
    7777        if DockSite is TForm then
    7878          DockSite.ManualDock(NewConjoinDockForm)
     
    8787    NewPanel := TCDClientPanel.Create(nil);
    8888    with NewPanel do begin
    89       Parent := TCDManager(Manager).DockSite;
    90       OwnerDockManager := Manager;
     89      Parent := Self.DockSite;
     90      OwnerDockManager := Self;
    9191      if DockStyle = dsList then Visible := True;
    92       Header.PopupMenu := TCDManager(Manager).PopupMenu;
     92      Header.PopupMenu := Self.PopupMenu;
    9393      //PopupMenu.Parent := Self.DockSite;
    9494    end;
    95     if (AControl is TForm) and Assigned((AControl as TForm).Icon) then
    96       NewPanel.Header.Icon.Picture.Assign((AControl as TForm).Icon);
    97 
    98     NewPanel.Control := AControl;
    99     AControl.AddHandlerOnVisibleChanged(NewPanel.VisibleChange);
    100     AControl.Parent := NewPanel.ClientAreaPanel;
    101     AControl.Align := alClient;
     95    if (Control is TForm) and Assigned((Control as TForm).Icon) then
     96      NewPanel.Header.Icon.Picture.Assign((Control as TForm).Icon);
     97
     98    NewPanel.Control := Control;
     99    Control.AddHandlerOnVisibleChanged(NewPanel.VisibleChange);
     100    Control.Parent := NewPanel.ClientAreaPanel;
     101    Control.Align := alClient;
    102102    if (InsertAt = alTop) or (InsertAt = alLeft) then
    103103      DockPanels.Insert(0, NewPanel)
     
    112112  ClientCount: Integer;
    113113begin
    114   ClientPanel := TCDManager(Manager).FindControlInPanels(Control);
     114  ClientPanel := FindControlInPanels(Control);
    115115  Control.RemoveHandlerOnVisibleChanged(ClientPanel.VisibleChange);
    116116
    117   TCDManager(Manager).DockPanels.Remove(ClientPanel);
    118   ClientCount := TCDManager(Manager).DockPanels.Count;
     117  DockPanels.Remove(ClientPanel);
     118  ClientCount := DockPanels.Count;
    119119
    120120  //if TCDManager(Manager).DockSite.DockClientCount = 2 then FDockDirection := ddNone;
    121121  if ClientCount = 1 then begin
    122122    // Last removed control => Free parent if it is TCDConjoinForm
    123     if TCDManager(Manager).DockSite is TCDConjoinForm then
    124     with TCDConjoinForm(TCDManager(Manager).DockSite) do begin
     123    if Self.DockSite is TCDConjoinForm then
     124    with TCDConjoinForm(Self.DockSite) do begin
    125125      if Assigned(Parent) then begin
    126         TCDClientPanel(TCDManager(Manager).DockPanels[0]).Control.ManualDock(HostDockSite);
    127       end else TCDClientPanel(TCDManager(Manager).DockPanels[0]).Control.ManualFloat(Rect(Left, Top, Left + Width, Top + Height));
     126        TCDClientPanel(DockPanels[0]).Control.ManualDock(HostDockSite);
     127      end else TCDClientPanel(DockPanels[0]).Control.ManualFloat(Rect(Left, Top, Left + Width, Top + Height));
    128128      ManualFloat(Rect(Left, Top, Left + Width, Top + Height));
    129129      Free;
     
    134134end;
    135135
    136 function TCDStyleRegions.GetHeaderPos: THeaderPos;
    137 begin
    138 //  Result := TCDManager(Manager).;
    139 end;
    140 
    141 procedure TCDStyleRegions.SetHeaderPos(const AValue: THeaderPos);
    142 begin
    143   inherited SetHeaderPos(AValue);
    144 end;
    145 
    146136constructor TCDStyleRegions.Create(AManager: TCDManagerBase);
    147137var
    148138  I: Integer;
    149139begin
    150   inherited;
     140 // inherited;
    151141  //Panels := TObjectList.Create;
    152142
     
    181171  SplitterLeft := 0;
    182172  SplitterTop := 0;
    183   with TCDManager(Manager) do
    184173  for I := 0 to DockPanels.Count - 1 do
    185174  with TCDClientPanel(DockPanels[I]) do begin
    186175    Left := SplitterLeft;
    187176    Top := SplitterTop;
    188     Height := TCDManager(Manager).DockSite.Height div
    189       TCDManager(Manager).DockSite.DockClientCount;
    190     Width := TCDManager(Manager).DockSite.Width div
    191       TCDManager(Manager).DockSite.DockClientCount;
     177    Height := Self.DockSite.Height div
     178      Self.DockSite.DockClientCount;
     179    Width := Self.DockSite.Width div
     180      SElf.DockSite.DockClientCount;
    192181    //TCDClientPanel(FDockPanels[I]).DockPanelPaint(Self);
    193182    if I < (DockPanels.Count - 1) then Align := BaseAlign
     
    198187    Splitter.Left := SplitterLeft;
    199188    Splitter.Top := SplitterTop;
    200     Splitter.Parent := TCDManager(Manager).DockSite;
     189    Splitter.Parent := SElf.DockSite;
    201190    Splitter.Align := BaseAlign;
    202191    Splitter.Visible := I < (DockPanels.Count - 1);
     
    212201end;
    213202
    214 procedure TCDStyleRegions.SetVisible(const AValue: Boolean);
    215 var
    216   I: Integer;
    217 begin
    218   inherited SetVisible(AValue);
    219   with TCDManager(Manager) do
     203procedure TCDStyleRegions.DoSetVisible(const AValue: Boolean);
     204var
     205  I: Integer;
     206begin
     207//  inherited SetVisible(AValue);
    220208  for I := 0 to DockPanels.Count - 1 do
    221209
  • Docking/CoolDocking/UCDStyleTabs.pas

    r189 r191  
    77uses
    88  Classes, Controls, ExtCtrls, ComCtrls, SysUtils, Dialogs,
    9   Menus, UCDStyle, Forms, UCDClientPanel, UCDCommon;
     9  Menus, Forms, UCDClientPanel, UCDCommon, UCDManager;
    1010
    1111type
     
    1313  { TCDStyleTabs }
    1414
    15   TCDStyleTabs = class(TCDStyle)
     15  TCDStyleTabs = class(TCDManager)
     16  public
    1617    MouseDown: Boolean;
    1718    MouseButton: TMouseButton;
     
    2526    procedure TabControlMouseUp(Sender: TObject; Button: TMouseButton;
    2627      Shift: TShiftState; X, Y: Integer);
    27     procedure InsertControl(AControl: TControl; InsertAt: TAlign); override;
     28    procedure InsertControl(AControl: TControl; InsertAt: TAlign;
     29      DropCtl: TControl); override;
    2830    procedure UpdateClientSize; override;
    2931  private
     
    3335  public
    3436    constructor Create(AManager: TCDManagerBase);
    35     procedure SetVisible(const AValue: Boolean); override;
     37    procedure DoSetVisible(const AValue: Boolean);
    3638    destructor Destroy; override;
    3739    procedure ChangeVisible(Control: TWinControl; Visible: Boolean); override;
     
    4547
    4648uses
    47   UCDClient, UCDManager;
     49  UCDClient;
    4850
    4951{ TCDStyleTabs }
     
    5254begin
    5355  if Assigned(PageControl.ActivePage) then
    54     TCDClientPanel(TCDManager(Manager).DockPanels[PageControl.TabIndex]).Control.Hide;
     56    TCDClientPanel(DockPanels[PageControl.TabIndex]).Control.Hide;
    5557end;
    5658
     
    5860begin
    5961  if MouseDown then
    60   with TCDManager(Manager) do
    6162  if Assigned(PageControl.ActivePage) then begin
    6263    TCDClientPanel(DockPanels[PageControl.TabIndex]).ClientAreaPanel.DockSite := False;
     
    7172begin
    7273  // Hide all clients
    73   with TCDManager(Manager) do
    7474  for I := 0 to DockPanels.Count - 1 do
    7575    if TCDClientPanel(DockPanels[I]).Control.Visible
     
    9393
    9494  // Show selected
    95   with TCDManager(Manager) do
    9695  if (PageControl.TabIndex <> -1) and (DockPanels.Count > PageControl.TabIndex)
    9796//  and not TCDClientPanel(DockPanels[PageControl.TabIndex]).Control.Visible
     
    144143  NewTabSheet: TTabSheet;
    145144begin
    146   inherited;
    147145
    148146  TabImageList := TImageList.Create(TCDManager(AManager).DockSite); //FDockSite);
    149147  with TabImageList do begin
    150     Name := TCDManager(Manager).DockSite.Name + '_' + 'ImageList';
     148    Name := DockSite.Name + '_' + 'ImageList';
    151149  end;
    152150  PageControl := TPageControl.Create(TCDManager(AManager).DockSite); //FDockSite);
    153151  with PageControl do begin
    154     Parent := TCDManager(Manager).DockSite;
    155     Name := TCDManager(Manager).DockSite.Name + '_' + 'TabControl';
     152    Parent := Self.DockSite;
     153    Name := Self.DockSite.Name + '_' + 'TabControl';
    156154    Visible := False;
    157155    Align := alTop;
     
    160158    OnChange := TabControlChange;
    161159    MultiLine := True;
    162     PopupMenu := TCDManager(Manager).PopupMenu;
     160    PopupMenu := Self.PopupMenu;
    163161    OnMouseLeave := TabControlMouseLeave;
    164162    OnMouseDown := TabControlMouseDown;
     
    174172  PageControl.Visible := True;
    175173  //TabImageList.Clear;
    176   with TCDManager(Manager) do
    177174  for I := 0 to DockPanels.Count - 1 do
    178175    Self.InsertControlNoUpdate(TCDClientPanel(DockPanels[I]).Control, alNone);
     
    189186procedure TCDStyleTabs.Switch(Index: Integer);
    190187begin
    191   inherited Switch(Index);
    192188  PageControl.TabIndex := Index;
    193189end;
     
    199195begin
    200196  inherited;
    201   with TCDManager(Manager) do begin
     197  begin
    202198    NewPanel := TCDClientPanel.Create(nil);
    203199    with NewPanel do begin
    204       Parent := TCDManager(Manager).DockSite;
    205       OwnerDockManager := TCDManager(Manager);
     200      Parent := Self.DockSite;
     201      OwnerDockManager := Self;
    206202      if DockStyle = dsList then Visible := True;
    207203      Align := alClient;
    208       Header.PopupMenu := TCDManager(Manager).PopupMenu;
     204      Header.PopupMenu := Self.PopupMenu;
    209205      //PopupMenu.Parent := Self.DockSite;
    210206    end;
     
    241237end;
    242238
    243 procedure TCDStyleTabs.InsertControl(AControl: TControl; InsertAt: TAlign);
     239procedure TCDStyleTabs.InsertControl(AControl: TControl; InsertAt: TAlign;
     240  DropCtl: TControl);
    244241var
    245242  NewTabSheet: TTabSheet;
     
    255252begin
    256253  inherited UpdateClientSize;
    257   with TCDManager(Manager) do
    258254  for I := 0 to DockPanels.Count - 1 do begin
    259255    //TCDClientPanel(DockPanels[I]).ClientAreaPanel.Width := DockSite.Width;
     
    263259end;
    264260
    265 procedure TCDStyleTabs.SetVisible(const AValue: Boolean);
    266 begin
    267   inherited SetVisible(AValue);
    268   with TCDManager(Manager) do
     261procedure TCDStyleTabs.DoSetVisible(const AValue: Boolean);
     262begin
    269263    if (PageControl.TabIndex >= 0) and (PageControl.TabIndex < DockPanels.Count) then
    270264      with TCDClientPanel(DockPanels[PageControl.TabIndex]) do begin
     
    288282    //if Assigned(TWinControl(Control).DockManager) then
    289283    //with TCDManager(TWinControl(Control).DockManager) do
    290     if Assigned(Manager) then
    291     with TCDManager(Manager) do
    292284    begin
    293285//    ShowMessage(IntToStr(TabControl.TabIndex) + ' ' + IntToStr(DockPanels.Count));
     
    312304//    if Assigned(TWinControl(Control).DockManager) then
    313305//    with TCDManager(TWinControl(Control).DockManager) do
    314     if Assigned(Manager) then
    315     with TCDManager(Manager) do
    316306    begin
    317307//      if Control.Tag = 0 then begin
Note: See TracChangeset for help on using the changeset viewer.