Changeset 12


Ignore:
Timestamp:
Nov 15, 2012, 8:06:57 AM (12 years ago)
Author:
chronos
Message:
  • Přidáno: Další použité komponenty.
  • Přidáno: Modulární systém pro uživatelské zavádění součástí aplikace.
  • Opraveno: Ukládání nastavení do registrů.
Location:
trunk
Files:
124 added
13 edited

Legend:

Unmodified
Added
Removed
  • trunk/Dochazka.lpi

    r11 r12  
    7272      </local>
    7373    </RunParams>
    74     <RequiredPackages Count="4">
     74    <RequiredPackages Count="7">
    7575      <Item1>
     76        <PackageName Value="synapse"/>
     77        <DefaultFilename Value="Packages/synapse/synapse.lpk" Prefer="True"/>
     78      </Item1>
     79      <Item2>
     80        <PackageName Value="ModularSystem"/>
     81        <DefaultFilename Value="Packages/ModularSystem/ModularSystem.lpk" Prefer="True"/>
     82      </Item2>
     83      <Item3>
     84        <PackageName Value="TemplateGenerics"/>
     85        <DefaultFilename Value="Packages/TemplateGenerics/TemplateGenerics.lpk" Prefer="True"/>
     86      </Item3>
     87      <Item4>
    7688        <PackageName Value="CoolTranslator"/>
    7789        <DefaultFilename Value="Packages/CoolTranslator/CoolTranslator.lpk" Prefer="True"/>
    78       </Item1>
    79       <Item2>
     90      </Item4>
     91      <Item5>
    8092        <PackageName Value="Common"/>
    8193        <DefaultFilename Value="Packages/Common/Common.lpk" Prefer="True"/>
    82       </Item2>
    83       <Item3>
     94      </Item5>
     95      <Item6>
    8496        <PackageName Value="CoolWeb"/>
    8597        <DefaultFilename Value="Packages/CoolWeb/CoolWeb.lpk" Prefer="True"/>
    86       </Item3>
    87       <Item4>
     98      </Item6>
     99      <Item7>
    88100        <PackageName Value="LCL"/>
    89       </Item4>
     101      </Item7>
    90102    </RequiredPackages>
    91     <Units Count="11">
     103    <Units Count="13">
    92104      <Unit0>
    93105        <Filename Value="Dochazka.lpr"/>
     
    158170        <IsPartOfProject Value="True"/>
    159171        <ComponentName Value="FormConnection"/>
     172        <HasResources Value="True"/>
    160173        <ResourceBaseClass Value="Form"/>
    161174        <UnitName Value="UFormConnection"/>
    162175      </Unit10>
     176      <Unit11>
     177        <Filename Value="Application/URegistredModules.pas"/>
     178        <IsPartOfProject Value="True"/>
     179        <UnitName Value="URegistredModules"/>
     180      </Unit11>
     181      <Unit12>
     182        <Filename Value="Modules/Attendance/UModuleAttendance.pas"/>
     183        <IsPartOfProject Value="True"/>
     184        <ComponentName Value="DataModuleAttendance"/>
     185        <ResourceBaseClass Value="DataModule"/>
     186        <UnitName Value="UModuleAttendance"/>
     187      </Unit12>
    163188    </Units>
    164189  </ProjectOptions>
     
    170195    <SearchPaths>
    171196      <IncludeFiles Value="$(ProjOutDir)"/>
    172       <OtherUnitFiles Value="Forms;Common"/>
     197      <OtherUnitFiles Value="Forms;Common;Application;Modules/Attendance"/>
    173198      <UnitOutputDirectory Value="lib/$(TargetCPU)-$(TargetOS)"/>
    174199    </SearchPaths>
  • trunk/Dochazka.lpr

    r11 r12  
    99  Interfaces, // this includes the LCL widgetset
    1010  Forms, UFormMain, UCore, UAttendance, UPersistentForm, CoolWeb, Common,
    11   CoolTranslator, UFormSetting, SysUtils, UFormList, UFormEdit, UDataView,
    12 UFormConnection
     11  CoolTranslator, UFormSetting, SysUtils, UFormList, UFormEdit, UDataView,
     12  URegistredModules, TemplateGenerics, synapse, UFormConnection,
     13UModuleAttendance
    1314  { you can add units after this };
    1415
  • trunk/Forms/UFormConnection.lfm

    r11 r12  
    1515    Anchors = [akRight, akBottom]
    1616    Caption = 'Connect'
     17    Default = True
    1718    ModalResult = 1
    1819    TabOrder = 0
     
    6364    Top = 97
    6465    Width = 156
    65     TabOrder = 4
     66    TabOrder = 5
    6667  end
    6768  object Label3: TLabel
     
    8182    ParentColor = False
    8283  end
    83   object MaskEditPassword: TMaskEdit
     84  object EditPassword: TEdit
    8485    Left = 151
    8586    Height = 21
    8687    Top = 68
    8788    Width = 156
    88     CharCase = ecNormal
    89     MaxLength = 0
    90     TabOrder = 5
    91     SpaceChar = '_'
     89    EchoMode = emPassword
     90    PasswordChar = '*'
     91    TabOrder = 4
    9292  end
    9393end
  • trunk/Forms/UFormConnection.pas

    r11 r12  
    1919    EditUserName: TEdit;
    2020    EditSchema: TEdit;
     21    EditPassword: TEdit;
    2122    Label1: TLabel;
    2223    Label2: TLabel;
    2324    Label3: TLabel;
    2425    Label4: TLabel;
    25     MaskEditPassword: TMaskEdit;
    2626  private
    2727    { private declarations }
     
    4444  EditHostName.Text := Database.HostName;
    4545  EditUserName.Text := Database.UserName;
    46   MaskEditPassword.Text := '';
     46  EditPassword.Text := '';
    4747  EditSchema.Text := Database.Database;
    4848end;
     
    5252  Database.HostName := EditHostName.Text;
    5353  Database.UserName := EditUserName.Text;
    54   Database.Password := MaskEditPassword.Text;
     54  Database.Password := EditPassword.Text;
    5555  Database.Database := EditSchema.Text;
    5656end;
  • trunk/Forms/UFormList.lfm

    r8 r12  
    11object FormList: TFormList
    2   Left = 385
     2  Left = 356
    33  Height = 397
    4   Top = 172
     4  Top = 170
    55  Width = 588
    66  Caption = 'List'
  • trunk/Forms/UFormMain.lfm

    r11 r12  
    11object FormMain: TFormMain
    2   Left = 306
     2  Left = 194
    33  Height = 455
    4   Top = 127
     4  Top = 144
    55  Width = 733
    66  Caption = 'Attendance'
     
    6161        Action = ASetting
    6262      end
     63      object MenuItem5: TMenuItem
     64        Action = AModuleList
     65      end
    6366      object MenuItem2: TMenuItem
    6467        Action = AExit
     
    8689      ShortCut = 121
    8790    end
     91    object AModuleList: TAction
     92      Caption = 'Modules'
     93      Hint = 'Show module management'
     94      OnExecute = AModuleListExecute
     95    end
    8896  end
    8997  object ImageList1: TImageList
     
    9199    top = 168
    92100    Bitmap = {
    93       4C690F0000001000000010000000000000000000000000000000000000000000
     101      4C69140000001000000010000000000000000000000000000000000000000000
    94102      0000000000000000000000000000000000000000000000000000000000000000
    95103      000000000000000000000000000000000000000000008C8CBBFF000088FF8C8C
     
    571579      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
    572580      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
    573       FF00FFFFFF00FFFFFF00FFFFFF00
     581      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FCFDF5FF7474
     582      DBFF6B6BBAFFFFFFFF00FFFFFF00FFFFFF00FFFFFF00E0E0EBFF4646C2FFC7C7
     583      E2FFFFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00DDDEDFFF7B7AC7FF8C8C
     584      F7FF8382EEFF9792C4FFE1D9CBFFDED6D1FFD0CDCDFF6E6ED0FF9F9FF5FF6D6C
     585      DEFFBBBACFFFF8F9F6FFFFFFFF00FFFFFF00FFFFFF00ACA39BFF5D55B7FF8D8D
     586      FFFFE6E6FFFF5453E6FF9A94B7FFD8CCBEFF5855C4FF9595FAFFDDDEFFFF4240
     587      E4FF867892FFCDC7C3FFFFFFFF00FFFFFF00FAFAFAFFB9ADA7FFD2C0ABFF2E2B
     588      90FF4547EEFF9393FFFF4243EBFF3736CBFF6B6BFFFF8687FFFF2827D7FFB5A9
     589      C1FFCBB8A6FFC3BDBEFFFFFFFF00FFFFFF00E8E9EAFFB1A7A2FFE2D2C7FFB5AD
     590      9CFF5654BCFF3737F4FF5757FFFF4445FFFF3C3CFFFF1C1BDEFFA098ACFFFFF4
     591      E1FFC7B7B0FFB0AEACFFFEFEFFFFFFFFFF00E9EBEBFFB4A8A4FFE3CEC3FFFFED
     592      DAFFD0C2B3FF3D3BD7FF4546FEFF4546FEFF1516FEFF7F78BEFFF5E8C4FFF0E6
     593      DEFFCCBDB3FFA8A2A1FFFBFDFEFFFFFFFF00E1E2E3FFB9ADA6FFE6D0C1FFC6B3
     594      B0FF6867CFFF6161FDFF7070FFFF6768FFFF5757FFFF4C4BF2FFA79EBFFFF8EC
     595      D5FFD3C5BAFFA59F9EFFF7F8F9FFFFFFFF00D7D8D9FFBDB1A5FFCFBDB9FF6F69
     596      CDFF696BFFFF9D9EFFFF8581DCFF8680C3FF8283FAFF5656FFFF3737F0FFADA7
     597      CEFFDDCDBAFFA79F9DFFF2F5F5FFFFFFFF00D1D2D2FFBBAFA5FF655FD5FF5B5D
     598      FFFF9C9DFFFF9391E0FFBBAFBCFFEBDECEFFA49ED2FF7576F9FF3C3CFFFF2A2B
     599      F1FFA498ACFFACA39BFFEDF0F1FFFFFFFF00CBCCCCFFC2B5A9FFA69AC2FF7979
     600      EFFF8888E5FFBAB1BDFFF6E9DCFFF8ECE5FFECE1D4FFA19CD0FF5456F8FF6663
     601      D7FFCEC0BFFFA9A199FFE7E9EAFFFFFFFF00C7C7C7FFC3B5ACFFE8D3B8FFADA1
     602      AFFFAFA8BDFFF9F1E3FFF4EDE4FFF4EDE4FFFAF3E8FFEEE6E0FF9C95BBFFD0C4
     603      C1FFF2E1CFFFA69C96FFE3E4E5FFFFFFFF00CAC6C5FFCABFB7FFDECFC5FFEEE1
     604      D0FFF0E4D4FFF3E9DDFFF5ECE3FFF5ECE3FFF5ECE3FFF5ECE3FFFBF3E4FFEAE0
     605      D3FFEAE0D3FFAAA29CFFDFDFE0FFFFFFFF00CAC8C7FFBCB0A7FFCEC3B9FFC4B8
     606      B0FFC4B8B0FFC4B8B0FFC1B5ADFFC1B5ADFFC1B5ADFFC4B9B2FFCBC3BDFFD5C8
     607      C6FFE0D2CDFFA19C97FFE0E1E2FFFFFFFF00CFCAC8FF968581FF584444FF6D5B
     608      59FF816E6BFF8C7877FF766564FF6C5F5EFF7B6A65FF736663FFBCA9A3FF9CA1
     609      86FFB2B09AFFA0928FFFE0E1E2FFFFFFFF00CCCBCAFFBAAFADFFB5A6A7FFCBBD
     610      B8FFDFD1C9FFE7D6D7FFE0D2D3FFE0D2D3FFE3D7D2FFE3D7D2FFF4DFE1FFB0CB
     611      A3FFCDD5B8FFAB9C9EFFDFE0DFFFFFFFFF00E7E7E8FFA19E9DFF959392FF9593
     612      92FF959392FF959392FF959392FF959392FF959392FF959392FF918D8DFF958F
     613      8FFF8E8687FFA19F9FFFF7F8F8FFFFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     614      FF009AAF9AFF6DB26DFF6FB26FFF6FB26FFF6BB26BFF629D62FFC6C5C6FFFFFF
     615      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     616      FF0091B791FFFFFFFFFFFDFFFDFFFCFFFCFFFFFFFFFFB3D7B3FF9CAC9EFFFFFF
     617      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00D6D6D6FFC2B8B8FFC2B1
     618      B5FF84AC82FFDBFFDCFFD0FAD0FFCAF7CAFFD5FAD5FF96D396FF828F7CFFCFBA
     619      C5FFC0BEBFFFECEDEDFFFFFFFF00FFFFFF00FFFFFF00ADA9A8FFC5BAAEFFAEAB
     620      97FF8FC986FFA6F9A9FF8FF090FF86ED86FF8DE68EFF62C262FF8DB484FFC6C3
     621      B3FFBBAEA6FFC4C3C3FFFFFFFF00FFFFFF00FFFFFF00B6AAA6FFAFC8A1FFBBEA
     622      BEFF9DEA9DFF83F082FF59E759FF55E055FF5AD259FF51C151FF2FA330FF1382
     623      12FF929E7FFFCFC6CBFFFFFFFF00FFFFFF00FFFFFF00BAACA9FFC3C8AFFFACED
     624      AFFF90FA92FF4BE44BFF19D919FF16CA16FF14BA14FF0DA30DFF008600FF409D
     625      3BFFBDAFA4FFC6BFC1FFFFFFFF00FFFFFF00E7E9E9FFB5A9A8FFDCC7C0FF9FA9
     626      8BFF59CB56FF27E529FF00CF00FF00BE00FF00B200FF009600FF358C2FFFE1D2
     627      CEFFD4BFB9FFA7A2A1FFFBFCFDFFFFFFFF00E1E3E4FFBAAEA9FFD4C1B6FFC0A1
     628      A4FFA3A58EFF28C025FF00D000FF00C100FF00AF00FF4BA745FFC7B4B1FFE2CD
     629      CAFFD2C2B7FFA79F9EFFF6F8F9FFFFFFFF00DBDDDDFFBBAFAAFFE0CDBFFFE3D6
     630      C8FFE9CACFFF9FA88BFF10BB10FF00BA00FF42A83CFFDAC5C6FFF0DFDBFFF2E7
     631      DBFFDBCAC0FFA69D9BFFF2F4F5FFFFFFFF00D2D4D5FFC0B2ABFFEAD8CDFFEFE5
     632      DAFFEADED1FFF9E3E2FFC3D5B3FF87CA7DFFE8DBD7FFF7E6E1FFF7EEE7FFF7EE
     633      E7FFE4D2C6FFA69E9BFFEBEEEFFFFFFFFF00CCCCCDFFC4B7ADFFE1CCC0FFECDD
     634      D4FFF4EBE3FFF4EBE3FFFFEEEDFFFFEFF5FFFDEEEBFFF8F1EBFFF7EEE7FFEEE3
     635      D9FFEBDDD1FFA9A09AFFE5E7E8FFFFFFFF00C7C8C9FFC4B9B1FFD5C6BBFFE5D4
     636      C7FFEEDFD3FFF4E8DFFFF7EFE7FFF7EFE7FFF7EFE7FFF5EADFFFF2E6DBFFE2D5
     637      CDFFE8D8CFFFACA49DFFE0E1E2FFFFFFFF00CAC6C6FFC7BBB3FFE2D8CEFFD8CD
     638      C4FFD8CDC4FFD5C9C0FFD5C9C0FFD5C9C0FFD5C9C0FFDBD0C6FFE0D6CCFFE6D7
     639      D2FFEEDFD9FFA69F9AFFE0DFE0FFFFFFFF00D0C9C9FF9C8A85FF675955FF7668
     640      64FF867573FF907F7CFF7B6B68FF7B6B68FF766865FF7B6E6CFFB7A3A0FFA8A8
     641      8EFFB7B19EFF9C9291FFE1E1E1FFFFFFFF00CECCCBFFB7A9A7FFA99796FFC2B2
     642      AFFFD5C6C2FFDECFCBFFD6C5C4FFD6C5C4FFD6C5C4FFD8CAC9FFEFD9DCFFB1CF
     643      A5FFC7D6B7FFAA9EA2FFE1E2E2FFFFFFFF00E7E7E7FFA4A1A1FF948C8DFF948C
     644      8DFF948C8DFF948C8DFF989192FF989192FF989192FF989192FF928C8CFF928C
     645      8CFF8C8485FFA3A0A1FFF8F9F9FFF5FCF600F5FCF600F5FCF600F5FCF600F5FC
     646      F600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FC
     647      F600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FC
     648      F6008ED796FF75CE80FF72CB7CFF99D7A0FFF5FCF600F5FCF600F5FCF600F5FC
     649      F600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FC
     650      F60075CE80FF9BD9A6FF9BD9A6FF7BC782FFF5FCF600F5FCF600F5FCF600F5FC
     651      F600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FC
     652      F60075CE80FF98D8A3FF8ACF94FF8ACF94FFF5FCF600F5FCF600F5FCF600F5FC
     653      F600F5FCF600F5FCF600F5FCF600F5FCF60078D082FF78D082FF72CB7CFF72CB
     654      7CFF6CC376FF99D7A0FF94D59DFF6CBC74FF6CBC74FF68B970FF64B46BFFF5FC
     655      F600F5FCF600F5FCF600F5FCF600F5FCF60075CE80FF9BD9A6FF9BD9A6FF99D7
     656      A0FF94D59DFF94D59DFF94D59DFF8ACF94FF8ACF94FF8ACF94FF55AA5CFFF5FC
     657      F600F5FCF600F5FCF600F5FCF600F5FCF60072CB7CFF98D8A3FF98D8A3FF7BC7
     658      82FF6CC376FF64C071FF64C071FF64C071FF64C071FF8ACF94FF51A658FFF5FC
     659      F600F5FCF600F5FCF600F5FCF600F5FCF6006BC57BFF6CC376FF7BC782FF94D5
     660      9DFF64C071FF64C071FF5DBC69FF5DBC69FF5DBC69FF84CD8CFF64B46BFF4A9F
     661      50FF479C4DFF449648FFF5FCF600F5FCF600F5FCF600F5FCF60068B970FF8ED7
     662      96FF61BC6AFF61BC6AFF61BC6AFF58BA63FF58BA63FF64C071FF82CA88FF82CA
     663      88FF82CA88FF3F9243FFF5FCF600F5FCF600F5FCF600F5FCF60061BC6AFF8ACF
     664      94FF5DBC69FF5DBC69FF58BA63FF55B860FF55B860FF61BC6AFF82CA88FF82CA
     665      88FF7BC782FF3D9141FFF5FCF600F5FCF60061BC6AFF61BC6AFF71BF79FF8ACF
     666      94FF58BA63FF58BA63FF55B860FF50B55AFF50B55AFF82CA88FF5CAC62FF4496
     667      48FF3C8F41FF3C8F41FFF5FCF600F5FCF60064B46BFF8ACF94FF8ACF94FF64C0
     668      71FF84CD8CFF84CD8CFF84CD8CFF82CA88FF58BA63FF7BC782FF3F9243FFF5FC
     669      F600F5FCF600F5FCF600F5FCF600F5FCF6005DB364FF8ACF94FF55B860FF84CD
     670      8CFF64B46BFF4A9F50FF4A9F50FF5CAC62FF7BC782FF7BC782FF3C8F41FFF5FC
     671      F600F5FCF600F5FCF600F5FCF600F5FCF6005CAC62FF84CD8CFF84CD8CFF82CA
     672      88FF4A9F50FFF5FCF600F5FCF600449648FF7BC782FF75C27BFF388C3CFFF5FC
     673      F600F5FCF600F5FCF600F5FCF600F5FCF60055AA5CFF51A658FF4EA354FF4A9F
     674      50FF4A9F50FFF5FCF600F5FCF6003F9243FF3C8F41FF3F9243FF49954CFFF5FC
     675      F600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FC
     676      F600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FCF600F5FC
     677      F600F5FCF600F5FCF600F5FCF600FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     678      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     679      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     680      FF0078CF82D475CD80FF73CA7DFE70C77AB4FFFFFF00FFFFFF00FFFFFF00FFFF
     681      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF0077CF
     682      821278CD82FF9CD9A7FF98D8A2FF6DC476ECFFFFFF00FFFFFF00FFFFFF00FFFF
     683      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     684      FF0072C97CF497D8A2FF8DD297FF69C072BEFFFFFF00FFFFFF00FFFFFF00FFFF
     685      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF0079D083FF76CE81FF74CB7EFF71C9
     686      7BFF6FC678FE97D7A1FF93D59DFF65BC6EF062B86AED5FB567EF5BB163EFFFFF
     687      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF0076CE80FF9BD9A6FF99D8A4FF98D7
     688      A2FF96D7A1FF95D59EFF93D49CFF8FD198FF8CD095FF8ACF94FF57AD5EFFFFFF
     689      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF0073CB7DFF99D8A3FF97D7A1FF79CB
     690      87FF69C377FF65C273FF64C171FF67C273FF66C071FF8BCF94FF53A95AFFFFFF
     691      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF0070C77AFF6DC477FF7CC985FF93D4
     692      9CFF65C172FF62C06FFF5FBE6CFF5DBD69FF5ABB66FF88CF90FF66B56DFF4CA1
     693      52FF489D4EFF45994AFFFFFFFF00FFFFFF00FFFFFF00FFFFFF0066BD6FFF90D2
     694      99FF60BF6DFF5EBD6AFF5BBC68FF59BB64FF56BA61FF65BF6FFF83CC8BFF82CA
     695      89FF80CA88FF419646FFFFFFFF00FFFFFF00FFFFFF00FFFFFF0063B96BFF8DD1
     696      96FF5DBC69FF5ABB66FF58BA63FF55B960FF52B75DFF5EA96DFF5A976FFF4F8E
     697      66FF43875BFF368545FFFFFFFF00FFFFFF0065BC6EFF62B86AFF72C07AFF8BCF
     698      93FF58BB64FF56BA61FF53B85FFF51B65BFF50A261FF61AB81FF95D4B4FFBAE6
     699      D0FF6ABB8FFF2D8F57FF196B378CFFFFFF0062B86AFF8BCF95FF8ACF92FF69C1
     700      72FF86CD8EFF84CC8CFF83CB8AFF81CA88FF45895DFF90D3B1FF92D6B1FFFFFF
     701      FFFF65BC8CFF67BC8FFF196B37F7FFFFFF005EB465FF88CF91FF56B961FF85CD
     702      8DFF65B56CFF4CA152FF499E4FFF5DAD63FF317B4CFF9CD4B6FFFFFFFFFFFFFF
     703      FFFFFFFFFFFF95D2B2FF196B37FFFFFFFF005AAF61FF86CD8EFF84CC8CFF83CA
     704      89FF4CA152FFFFFFFF00FFFFFF00429647FF1E6F3BFF62BA8BFF60BA87FFFFFF
     705      FFFF60B987FF67BC8FFF196B37F7FFFFFF0056AB5DFF52A759FF4FA455FF4BA0
     706      51FF489C4DF7FFFFFF00FFFFFF003E9243FD297C3BFE288C53FF64BA8DFF95D2
     707      B2FF64BA8DFF288C53FF196B378CFFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     708      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00196B3788196B37F2196B
     709      37FF196B37F2196B3788FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     710      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     711      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     712      FF0078CF82D475CD80FF73CA7DFE70C77AB4FFFFFF00FFFFFF00FFFFFF00FFFF
     713      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF0077CF
     714      821278CD82FF9CD9A7FF98D8A2FF6DC476ECFFFFFF00FFFFFF00FFFFFF00FFFF
     715      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     716      FF0072C97CF497D8A2FF8DD297FF69C072BEFFFFFF00FFFFFF00FFFFFF00FFFF
     717      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF0079D083FF76CE81FF74CB7EFF71C9
     718      7BFF6FC678FE97D7A1FF93D59DFF65BC6EF062B86AED5FB567EF5BB163EFFFFF
     719      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF0076CE80FF9BD9A6FF99D8A4FF98D7
     720      A2FF96D7A1FF95D59EFF93D49CFF8FD198FF8CD095FF8ACF94FF57AD5EFFFFFF
     721      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF0073CB7DFF99D8A3FF97D7A1FF79CB
     722      87FF69C377FF65C273FF64C171FF67C273FF66C071FF8BCF94FF53A95AFFFFFF
     723      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF0070C77AFF6DC477FF7CC985FF93D4
     724      9CFF65C172FF62C06FFF5FBE6CFF5DBD69FF5ABB66FF88CF90FF66B56DFF4CA1
     725      52FF489D4EFF45994AFFFFFFFF00FFFFFF00FFFFFF00FFFFFF0066BD6FFF90D2
     726      99FF60BF6DFF5EBD6AFF5BBC68FF59BB64FF56BA61FF65BF6FFF83CC8BFF82CA
     727      89FF80CA88FF419646FFFFFFFF00FFFFFF00FFFFFF00FFFFFF0063B96BFF8DD1
     728      96FF5DBC69FF5ABB66FF58BA63FF55B960FF52B75DFF428D95FF1C5CB9FF0443
     729      BCFF1154B3FF226E7AFFFFFFFF00FFFFFF0065BC6EFF62B86AFF72C07AFF8BCF
     730      93FF58BB64FF56BA61FF53B85FFF51B65BFF38898BFF3A75CFFF8DB5F7FFB8D6
     731      FEFF72A8F5FF2D6BC9FF0443BA6DFFFFFF0062B86AFF8BCF95FF8ACF92FF69C1
     732      72FF86CD8EFF84CC8CFF83CB8AFF81CA88FF0F54AEFF8DB5F6FF4D92FFFF1177
     733      FFFF2186FFFF408AEBFF0344B9DEFFFFFF005EB465FF88CF91FF56B961FF85CD
     734      8DFF65B56CFF4CA152FF499E4FFF5DAD63FF0443BCFFAECDFEFFFFFFFFFFFFFF
     735      FFFFFFFFFFFF187FEFFF0442BCFEFFFFFF005AAF61FF86CD8EFF84CC8CFF83CA
     736      89FF4CA152FFFFFFFF00FFFFFF00429647FF1053B3FF639DF4FF187FFFFF0076
     737      F8FF0076EEFF0368E1FF0345B9E4FFFFFF0056AB5DFF52A759FF4FA455FF4BA0
     738      51FF489C4DF7FFFFFF00FFFFFF003E9243FD2A7382FE2565C7FF2177E6FF0579
     739      EAFF0164DDFF044DBDFC0345B87AFFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFF
     740      FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF001D57C4780345B9DF0442
     741      BCFE0345B9E30345B87AFFFFFF00
    574742    }
    575743  end
  • trunk/Forms/UFormMain.lrt

    r11 r12  
    77TFORMMAIN.ASETTING.HINT=Show global setting
    88TFORMMAIN.ACONNECTIONSETTINGS.CAPTION=Connection settings
     9TFORMMAIN.AMODULELIST.CAPTION=Modules
     10TFORMMAIN.AMODULELIST.HINT=Show module management
  • trunk/Forms/UFormMain.pas

    r11 r12  
    77uses
    88  Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ComCtrls,
    9   Menus, ActnList, UFormList, SpecializedList, UFormEdit;
     9  Menus, ActnList, UFormList, SpecializedList, UFormEdit, UFormModuleList;
    1010
    1111type
     
    1515  TFormMain = class(TForm)
    1616    AConnectionSettings: TAction;
     17    AModuleList: TAction;
    1718    ASetting: TAction;
    1819    AExit: TAction;
     
    2324    MenuItem3: TMenuItem;
    2425    MenuItem4: TMenuItem;
     26    MenuItem5: TMenuItem;
    2527    MenuItemSystem: TMenuItem;
    2628    MenuItem2: TMenuItem;
     
    3133    procedure AConnectionSettingsExecute(Sender: TObject);
    3234    procedure AExitExecute(Sender: TObject);
     35    procedure AModuleListExecute(Sender: TObject);
    3336    procedure ASettingExecute(Sender: TObject);
    3437    procedure FormClose(Sender: TObject; var CloseAction: TCloseAction);
     
    3841    procedure TabSheetShow(Sender: TObject);
    3942  private
     43    procedure FormModuleListDestroy(Sender: TObject);
    4044    procedure InitModules;
    4145    procedure ReloadPages;
     
    104108procedure TFormMain.FormDestroy(Sender: TObject);
    105109begin
    106   DataViewForms.Free;
    107   DataViewLists.Free;
     110  FreeAndNil(DataViewForms);
     111  FreeAndNil(DataViewLists);
    108112  Core.PersistentForm.Save(Self);
    109113  Core.Done;
     
    113117begin
    114118  Close;
     119end;
     120
     121procedure TFormMain.AModuleListExecute(Sender: TObject);
     122begin
     123  if not Assigned(Core.FormModuleList) then begin
     124    Core.FormModuleList := TFormModuleList.Create(FormMain);
     125    Core.FormModuleList.Manager := Core.ModuleManager;
     126    Core.FormModuleList.AddHandlerOnBeforeDestruction(FormModuleListDestroy);
     127    Core.CoolTranslator1.TranslateComponentRecursive(Core.FormModuleList)
     128  end;
     129  Core.FormModuleList.Show;
    115130end;
    116131
     
    145160    UpdateData;
    146161  end;
     162end;
     163
     164procedure TFormMain.FormModuleListDestroy(Sender: TObject);
     165begin
     166  if Assigned(Core.FormModuleList) then Core.FormModuleList := nil;
    147167end;
    148168
  • trunk/Forms/UFormSetting.lfm

    r6 r12  
    11object FormSetting: TFormSetting
    2   Left = 475
     2  Left = 365
    33  Height = 367
    4   Top = 142
     4  Top = 196
    55  Width = 532
    66  Caption = 'Setting'
  • trunk/Languages/Dochazka.cs.po

    r11 r12  
    180180msgstr "Zavřít aplikaci"
    181181
     182#: tformmain.amodulelist.caption
     183msgid "Modules"
     184msgstr "Moduly"
     185
     186#: tformmain.amodulelist.hint
     187msgid "Show module management"
     188msgstr "Ukázat správu modulů"
     189
    182190#: tformmain.asetting.caption
    183191msgctxt "tformmain.asetting.caption"
     
    340348msgid "Year"
    341349msgstr "Rok"
     350
     351#: umoduleattendance.sattendance
     352msgctxt "umoduleattendance.sattendance"
     353msgid "Attendance"
     354msgstr "Docházka"
  • trunk/Languages/Dochazka.po

    r11 r12  
    169169msgstr ""
    170170
     171#: tformmain.amodulelist.caption
     172msgid "Modules"
     173msgstr ""
     174
     175#: tformmain.amodulelist.hint
     176msgid "Show module management"
     177msgstr ""
     178
    171179#: tformmain.asetting.caption
    172180msgctxt "TFORMMAIN.ASETTING.CAPTION"
     
    329337msgstr ""
    330338
     339#: umoduleattendance.sattendance
     340msgctxt "umoduleattendance.sattendance"
     341msgid "Attendance"
     342msgstr ""
     343
  • trunk/UCore.lfm

    r6 r12  
    44  OldCreateOrder = False
    55  Height = 323
    6   HorizontalOffset = 526
    7   VerticalOffset = 197
     6  HorizontalOffset = 500
     7  VerticalOffset = 317
    88  Width = 324
    99  object ApplicationInfo1: TApplicationInfo
     
    1717    EmailContact = 'robie@centrum.cz'
    1818    AppName = 'Docházka'
    19     ReleaseDate = 41227
     19    ReleaseDate = 41228
    2020    RegistryKey = '\Software\Chronosoft\Dochazka'
    2121    RegistryRoot = rrKeyCurrentUser
     
    3535    top = 128
    3636  end
     37  object ModuleManager: TModuleManager
     38    OnUpdate = ModuleManagerUpdate
     39    Options = []
     40    left = 203
     41    top = 128
     42  end
    3743end
  • trunk/UCore.pas

    r7 r12  
    77uses
    88  Registry, Classes, SysUtils, FileUtil, USqlDatabase, URegistry, Forms,
    9   UApplicationInfo, UCoolTranslator, UPersistentForm;
     9  UApplicationInfo, UCoolTranslator, UPersistentForm, UModularSystem,
     10  UFormModuleList;
    1011
    1112type
     
    1718    CoolTranslator1: TCoolTranslator;
    1819    Database: TSqlDatabase;
     20    ModuleManager: TModuleManager;
    1921    procedure DataModuleCreate(Sender: TObject);
    2022    procedure DataModuleDestroy(Sender: TObject);
     23    procedure ModuleManagerUpdate(Sender: TObject);
    2124  private
     25    procedure ModuleManagerChange(Sender: TObject);
    2226  public
     27    FormModuleList: TFormModuleList;
    2328    FormList: TForm;
    2429    PersistentForm: TPersistentForm;
     30    RegistryContext: TRegistryContext;
    2531    procedure Init;
    2632    procedure Done;
    2733    procedure InitData;
    2834    procedure Connect;
    29     procedure LoadFromRegistry(Context: TRegistryContext);
    30     procedure SaveToRegistry(Context: TRegistryContext);
     35    procedure LoadFromRegistry(AContext: TRegistryContext);
     36    procedure SaveToRegistry(AContext: TRegistryContext);
    3137  end;
    3238
     
    3844{$R *.lfm}
    3945
     46uses
     47  URegistredModules;
     48
    4049
    4150{ TCore }
     
    4655  PersistentForm.RegistryContext := RegContext(HKEY(ApplicationInfo1.RegistryRoot),
    4756    ApplicationInfo1.RegistryKey + '\Forms');
     57  ModuleManager := TModuleManager.Create(nil);
     58  RegistryContext := RegContext(HKEY(ApplicationInfo1.RegistryRoot), ApplicationInfo1.RegistryKey);
    4859end;
    4960
    5061procedure TCore.DataModuleDestroy(Sender: TObject);
    5162begin
     63  if Assigned(FormModuleList) then FreeAndNil(FormModuleList);
     64  FreeAndNil(ModuleManager);
    5265  FreeAndNil(PersistentForm);
     66end;
     67
     68procedure TCore.ModuleManagerUpdate(Sender: TObject);
     69begin
     70  if Assigned(FormModuleList) then
     71    FormModuleList.Reload;
     72end;
     73
     74procedure TCore.ModuleManagerChange(Sender: TObject);
     75begin
     76
    5377end;
    5478
    5579procedure TCore.Init;
    5680begin
    57   LoadFromRegistry(RegContext(HKEY(ApplicationInfo1.RegistryRoot), ApplicationInfo1.RegistryKey));
    58 //  LoadFromRegistry(RegContext(HKEY_CURRENT_USER, '\Software\Chronosoft\Dochazka'));
     81  LoadFromRegistry(RegistryContext);
    5982
    60   Connect;
     83    // Init modules
     84    with TRegistryEx.Create do
     85    try
     86      Context := RegistryContext;
     87      RegisterModules(ModuleManager);
     88      if ReadBoolWithDefault('ModuleManagerInstalled', False) then
     89        ModuleManager.LoadFromRegistry(RegContext(RegistryContext.RootKey, RegistryContext.Key + '\Modules'))
     90        else begin
     91          ModuleManager.Modules.Perform([maEnable]);
     92          ModuleManager.SaveToRegistry(RegContext(RegistryContext.RootKey, RegistryContext.Key + '\Modules'));
     93          WriteBool('ModuleManagerInstalled', True);
     94        end;
     95    finally
     96      Free;
     97    end;
     98    ModuleManager.Modules.Perform([maStart], [mcEnabled]);
     99
     100    Connect;
    61101end;
    62102
    63103procedure TCore.Done;
    64104begin
    65   SaveToRegistry(RegContext(HKEY(ApplicationInfo1.RegistryRoot), ApplicationInfo1.RegistryKey));
     105  SaveToRegistry(RegistryContext);
    66106end;
    67107
     
    83123end;
    84124
    85 procedure TCore.LoadFromRegistry(Context: TRegistryContext);
     125procedure TCore.LoadFromRegistry(AContext: TRegistryContext);
    86126begin
    87127  with TRegistryEx.Create do
    88128  try
    89     RootKey := Context.RootKey;
    90     OpenKey('\Software\Chronosoft\Dochazka', True);
    91     //OpenKey(Context.Key, True);
     129    Context := AContext;
    92130    Database.HostName := ReadStringWithDefault('HostName', 'localhost');
    93131    Database.Database := ReadStringWithDefault('Schema', 'dochazka');
     
    100138end;
    101139
    102 procedure TCore.SaveToRegistry(Context: TRegistryContext);
     140procedure TCore.SaveToRegistry(AContext: TRegistryContext);
    103141begin
    104142  with TRegistryEx.Create do
    105143  try
    106     RootKey := Context.RootKey;
    107     OpenKey(Context.Key, True);
     144    Context := AContext;
    108145    WriteString('HostName', Database.HostName);
    109146    WriteString('Schema', Database.Database);
Note: See TracChangeset for help on using the changeset viewer.