diff --git a/public10/design/U_BaseDataLink.pas b/public10/design/U_BaseDataLink.pas index 2822d4e..c32b7fe 100644 --- a/public10/design/U_BaseDataLink.pas +++ b/public10/design/U_BaseDataLink.pas @@ -54,14 +54,39 @@ var str :String; pathStr:String; I: Integer; - thread:TThread; +// thread:TThread; begin /////////////////// - dxSkinController1.BeginUpdate; + // dxSkinController1.BeginUpdate; ////////////////////// - thread:=TThread.CreateAnonymousThread( - procedure - begin + // thread:=TThread.CreateAnonymousThread( + // procedure + // begin + +// if (fileexists(ExtractFilePath(Application.ExeName) + 'devchs.ini') = true) +// then +// begin +// cxLocalizer1.FileName := ExtractFilePath(Application.ExeName) + +// 'devchs.ini'; +// cxLocalizer1.Active := true; +// cxLocalizer1.LanguageIndex := 1; +// end; +// +// pathStr:=ExtractFilePath(Application.ExeName) + '\AllSkins.skinres'; +// if FileExists(pathStr) then +// begin +// dxSkinsUserSkinLoadFromFile(pathStr, 'WXI'); +// RootLookAndFeel.SkinName := sdxSkinsUserSkinName; +// end; + // end); + + // thread.FreeOnTerminate := True; + // thread.Start; + + dxSkinController1.BeginUpdate; + TRY + RootLookAndFeel.NativeStyle := FALSE; + gFontSize:=0; if (fileexists(ExtractFilePath(Application.ExeName) + 'devchs.ini') = true) then @@ -72,30 +97,6 @@ begin cxLocalizer1.LanguageIndex := 1; end; - pathStr:=ExtractFilePath(Application.ExeName) + '\AllSkins.skinres'; - if FileExists(pathStr) then - begin - dxSkinsUserSkinLoadFromFile(pathStr, 'WXI'); - RootLookAndFeel.SkinName := sdxSkinsUserSkinName; - end; - end); - - thread.FreeOnTerminate := True; - thread.Start; - - - RootLookAndFeel.NativeStyle := FALSE; - gFontSize:=0; - -// if (fileexists(ExtractFilePath(Application.ExeName) + 'devchs.ini') = true) -// then -// begin -// cxLocalizer1.FileName := ExtractFilePath(Application.ExeName) + -// 'devchs.ini'; -// cxLocalizer1.Active := true; -// cxLocalizer1.LanguageIndex := 1; -// end; - // getSystemIni(); if not gIsUseSkin then begin @@ -104,15 +105,16 @@ begin end else begin -// pathStr:=ExtractFilePath(Application.ExeName) + '\AllSkins.skinres'; -// if FileExists(pathStr) then -// begin -// dxSkinsUserSkinLoadFromFile(pathStr, 'WXI'); -// RootLookAndFeel.SkinName := sdxSkinsUserSkinName; -// end; + pathStr:=ExtractFilePath(Application.ExeName) + '\AllSkins.skinres'; + if FileExists(pathStr) then + begin + dxSkinsUserSkinLoadFromFile(pathStr, 'WXI'); + RootLookAndFeel.SkinName := sdxSkinsUserSkinName; + end; end; - - dxSkinController1.EndUpdate; + FINALLY + dxSkinController1.EndUpdate; + END; end;