From: <aka...@us...> - 2024-07-07 11:40:48
|
Revision: 4284 http://sourceforge.net/p/gexperts/code/4284 Author: akalwahome Date: 2024-07-07 11:40:46 +0000 (Sun, 07 Jul 2024) Log Message: ----------- Reverted some recent changes to make it compile with Delphi 2007 Modified Paths: -------------- trunk/Source/CodeProofreader/GX_ProofreaderConfig.pas trunk/Source/Framework/GX_ConfigurationInfo.pas trunk/Source/Utils/GX_IdeUtils.pas trunk/Source/Utils/GX_OtaUtils.pas Modified: trunk/Source/CodeProofreader/GX_ProofreaderConfig.pas =================================================================== --- trunk/Source/CodeProofreader/GX_ProofreaderConfig.pas 2024-07-06 20:24:59 UTC (rev 4283) +++ trunk/Source/CodeProofreader/GX_ProofreaderConfig.pas 2024-07-07 11:40:46 UTC (rev 4284) @@ -231,8 +231,7 @@ cbLanguage.Items.Add(ReplacementSourceText[i]); // Initialize option settings - btnSelectFile.Top := eCustomBeep.Top - 1; // Ord(IsThemingEnabled); - btnSelectFile.Height := eCustomBeep.Height + 2; // * Ord(IsThemingEnabled); + TButton_AlignVerticallyTo(btnSelectFile, eCustomBeep); cbBeep.Checked := FProofreaderData.BeepOnReplace; eCustomBeep.Text := FProofreaderData.CustomBeepSound; cbReplacerActive.Checked := FProofreaderData.ReplacerActive; Modified: trunk/Source/Framework/GX_ConfigurationInfo.pas =================================================================== --- trunk/Source/Framework/GX_ConfigurationInfo.pas 2024-07-06 20:24:59 UTC (rev 4283) +++ trunk/Source/Framework/GX_ConfigurationInfo.pas 2024-07-07 11:40:46 UTC (rev 4284) @@ -1018,12 +1018,15 @@ OrigTop: Integer; OrigWidth: Integer; OrigHeight: Integer; - OrigDpi: Integer; NewLeft: Integer; NewTop: Integer; NewWidth: Integer; NewHeight: Integer; +{$IFDEF GX_IDE_IS_HIDPI_AWARE} + OrigDpi: Integer; NewDpi: Integer; +{$ENDIF} + begin if Section = '' then StorageSection := Form.ClassName @@ -1032,10 +1035,8 @@ {$IFDEF GX_IDE_IS_HIDPI_AWARE} OrigDpi := TScreen_GetDpiForForm(Form); -{$ELSE} - OrigDpi := USER_DEFAULT_SCREEN_DPI; // 96 + NewDPI := OrigDPI; {$ENDIF} - NewDPI := OrigDPI; R := Form.BoundsRect; OrigLeft := R.Left; Modified: trunk/Source/Utils/GX_IdeUtils.pas =================================================================== --- trunk/Source/Utils/GX_IdeUtils.pas 2024-07-06 20:24:59 UTC (rev 4283) +++ trunk/Source/Utils/GX_IdeUtils.pas 2024-07-07 11:40:46 UTC (rev 4284) @@ -856,20 +856,20 @@ end; function IsThemingEnabled: Boolean; -{$IFNDEF GX_DELPHI_RIO_UP} +{$IFDEF GX_DELPHI_RIO_UP} // Delphi 10.3 Rio +begin + Result := GX_OtaUtils.GxOtaThemingEnabled; +end; +{$ELSE} var reg: TRegistry; -{$ENDIF} begin + Result := False; if CompilerVersion < CompilerVersionDelphiX103 then begin - Result := False; Exit; //==> end; -{$IFDEF GX_DELPHI_RIO_UP} // Delphi 10.3 Rio - Result := GX_OtaUtils.GxOtaThemingEnabled; -{$ELSE} // if yes, check if theming is enabled reg := TRegistry.Create; try @@ -885,8 +885,8 @@ finally FreeAndNil(reg); end; -{$ENDIF GX_VER330_up} end; +{$ENDIF GX_DELPHI_RIO_UP} function TScreen_TryFindClassForm(const _ClassName: string; out _Form: TForm): Boolean; var Modified: trunk/Source/Utils/GX_OtaUtils.pas =================================================================== --- trunk/Source/Utils/GX_OtaUtils.pas 2024-07-06 20:24:59 UTC (rev 4283) +++ trunk/Source/Utils/GX_OtaUtils.pas 2024-07-07 11:40:46 UTC (rev 4284) @@ -4005,6 +4005,7 @@ end; function GxOtaThemingEnabled: Boolean; +{$IF declared(IOTAIDEThemingServices)} var LService : IOTAIDEThemingServices; begin @@ -4012,6 +4013,11 @@ if Supports(BorlandIDEServices, ToolsAPI.IOTAIDEThemingServices, LService) then Result := LService.IDEThemingEnabled; end; +{$ELSE} +begin + Result := False; +end; +{$IFEND} type // TODO 3 -cCleanup -oAnyone: Remove this type, since it is confusing and is not .NET compatible This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |