Skip to content

Commit

Permalink
Delphi 10.2 Tokyo compatibility fix (#805)
Browse files Browse the repository at this point in the history
  • Loading branch information
mark-lobanov authored Jan 20, 2025
1 parent e3f31e4 commit bcb4af1
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion ideexpert/DMVC.Expert.Forms.NewProjectWizard.pas
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@

unit DMVC.Expert.Forms.NewProjectWizard;

{$I dmvcframework.inc}
{$I ..\sources\dmvcframework.inc}

interface

Expand Down
3 changes: 2 additions & 1 deletion sources/MVCFramework.HTMX.pas
Original file line number Diff line number Diff line change
Expand Up @@ -433,12 +433,13 @@ function THTMXResponseHelper.HXTriggerClientEvents(EventsDescriptors: TJSONObjec
function THTMXResponseHelper.HXTriggerClientEvents(Names: TArray<string>; After: TClientEventType): TMVCWebResponse;
var
Value: string;
I: Integer;
begin
if Length(Names) = 0 then
Exit(Self);

Value := Names[0];
for var I := Low(Names) + 1 to High(Names) do
for I := Low(Names) + 1 to High(Names) do
Value := Value + ', ' + Names[I];

SetCustomHeader(ClientEventTypes[After], Value);
Expand Down
4 changes: 3 additions & 1 deletion sources/MVCFramework.IntfObjectPool.pas
Original file line number Diff line number Diff line change
Expand Up @@ -253,9 +253,11 @@ procedure TIntfCleanupThread<IInterface>.Execute;

function TIntfCleanupThread<IInterface>.GetAveragePoolSize(
var SizeSamples: TPoolSizeSamples): Integer;
var
I: Integer;
begin
Result := 0;
for var I := Low(TPoolSizeSamples) to High(TPoolSizeSamples) do
for I := Low(TPoolSizeSamples) to High(TPoolSizeSamples) do
begin
Inc(Result, SizeSamples[I]);
end;
Expand Down
4 changes: 3 additions & 1 deletion sources/MVCFramework.ObjectPool.pas
Original file line number Diff line number Diff line change
Expand Up @@ -253,9 +253,11 @@ procedure TCleanupThread<T>.Execute;

function TCleanupThread<T>.GetAveragePoolSize(
var SizeSamples: TPoolSizeSamples): Integer;
var
I: Integer;
begin
Result := 0;
for var I := Low(TPoolSizeSamples) to High(TPoolSizeSamples) do
for I := Low(TPoolSizeSamples) to High(TPoolSizeSamples) do
begin
Inc(Result, SizeSamples[I]);
end;
Expand Down
3 changes: 2 additions & 1 deletion sources/MVCFramework.View.Renderers.Mustache.pas
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ TMVCMustacheHelpers = class sealed
implementation

uses
Types,
JsonDataObjects,
MVCFramework.Serializer.Defaults,
MVCFramework.Serializer.Intf,
Expand Down Expand Up @@ -171,7 +172,7 @@ procedure TMVCMustacheViewEngine.LoadPartials;
lViewsExtension: string;
lViewPath: string;
lPartialName: String;
lPartialFileNames: TArray<string>;
lPartialFileNames: TStringDynArray;
I: Integer;
begin
if gPartialsLoaded then
Expand Down

0 comments on commit bcb4af1

Please sign in to comment.