unit U_BaseDataLink;

interface

uses
  System.SysUtils, windows, forms, System.Classes, dxCore, cxClasses,
  cxLookAndFeels, dxSkinsForm, cxContainer, cxEdit, System.ImageList,
  Vcl.ImgList, Vcl.Controls, cxImageList, cxGraphics, cxStyles, cxLocalization,
  dxSkinsCore, dxSkinsDefaultPainters;

type
  TBaseDataLink = class(TDataModule)
    dxSkinController1: TdxSkinController;
    cxImageList_bar: TcxImageList;
    cxLocalizer1: TcxLocalizer;
    procedure DataModuleCreate(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  BaseDataLink: TBaseDataLink;

implementation

{%CLASSGROUP 'Vcl.Controls.TControl'}

{$R *.dfm}

procedure TBaseDataLink.DataModuleCreate(Sender: TObject);
var
  str: string;
  pathStr: string;
begin
  RootLookAndFeel.NativeStyle := False;
//  pathStr := ExtractFilePath(Application.ExeName) + '\AllSkins.skinres';
//  if FileExists(pathStr) then
//  begin
//    dxSkinsUserSkinLoadFromFile(pathStr, 'WXI');
//    RootLookAndFeel.SkinName := sdxSkinsUserSkinName;
//  end;
  if (fileexists(ExtractFilePath(Application.ExeName) + 'devchs.ini') = true) then
  begin
    cxLocalizer1.FileName := ExtractFilePath(Application.ExeName) + 'devchs.ini';
    cxLocalizer1.Active := true;
    cxLocalizer1.LanguageIndex := 1;
  end;
end;

end.

