Skip to content

Commit 0fe42b1

Browse files
committed
1 parent 641de68 commit 0fe42b1

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

Source/vcl/WrapVclThemes.pas

+6-4
Original file line numberDiff line numberDiff line change
@@ -103,11 +103,13 @@ function StyleServices_Wrapper(pself, args: PPyObject): PPyObject; cdecl;
103103
if PyTuple_Check(args) then begin
104104
if PyTuple_Size(args) = 0 then
105105
Result := GlobalDelphiWrapper.Wrap(StyleServices())
106+
{$IF CompilerVersion > 33}
106107
else if (PyArg_ParseTuple(args, 'O:StyleServices', @LPyObj) <> 0)
107-
and CheckObjAttribute(LPyObj, 'AControl', TControl, TObject(LControl)) then
108-
begin
109-
Result := GlobalDelphiWrapper.Wrap(StyleServices(LControl));
110-
end else
108+
and CheckObjAttribute(LPyObj, 'AControl', TControl, TObject(LControl))
109+
then
110+
Result := GlobalDelphiWrapper.Wrap(StyleServices(LControl))
111+
{$IFEND}
112+
else
111113
Result := nil;
112114
end else
113115
Result := nil;

0 commit comments

Comments
 (0)