Changeset 95 for trunk


Ignore:
Timestamp:
Dec 21, 2014, 3:42:54 PM (10 years ago)
Author:
chronos
Message:
  • Added: Simple script to build linux deb package.
Location:
trunk
Files:
12 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Packages/CoolTranslator/UCoolTranslator.pas

    r33 r95  
    150150  I: Integer;
    151151  LocaleShort: string;
     152  Dir: string;
    152153begin
    153154  FPOFiles.Clear;
     
    157158    //ShowMessage(ExtractFileDir(Application.ExeName) +
    158159    //  DirectorySeparator + 'Languages' + ' ' + '*.' + LocaleShort + '.po');
    159     FileList := FindAllFiles(ExtractFileDir(UTF8Encode(Application.ExeName)) +
    160       DirectorySeparator + FPOFilesFolder, '*.' + LocaleShort + '.po');
     160    Dir := FPOFilesFolder;
     161    if Copy(Dir, 1, 1) <> DirectorySeparator then
     162      Dir := ExtractFileDir(UTF8Encode(Application.ExeName)) +
     163      DirectorySeparator + Dir;
     164    FileList := FindAllFiles(Dir, '*.' + LocaleShort + '.po');
    161165    for I := 0 to FileList.Count - 1 do begin
    162166      FileName := FileList[I];
     
    174178  FPoFilesFolder := AValue;
    175179  ReloadFiles;
     180  CheckLanguageFiles;
    176181end;
    177182
     
    359364  Languages := TLanguageList.Create;
    360365  POFilesFolder := 'Languages';
    361   CheckLanguageFiles;
    362366
    363367  // LCL
  • trunk/UCore.pas

    r94 r95  
    333333  I: Integer;
    334334begin
     335  {$IFDEF Linux}
     336  // If installed in Linux system then use installation directory for po files
     337  if Application.ExeName = '/usr/bin/xtactics' then
     338    CoolTranslator1.POFilesFolder := '/usr/share/xtactics/languages';
     339  {$ENDIF}
    335340  FInitialized := True;
    336341  LoadConfig;
Note: See TracChangeset for help on using the changeset viewer.