File tree Expand file tree Collapse file tree 1 file changed +8
-10
lines changed Expand file tree Collapse file tree 1 file changed +8
-10
lines changed Original file line number Diff line number Diff line change @@ -5419,12 +5419,11 @@ procedure TPyDelphiWrapper.Initialize;
54195419 with TPythonType(fHelperClassRegister.Objects[i]) do
54205420 if not Initialized then Initialize;
54215421 // Initialize module
5422- if Assigned(FModule) then begin
5422+ if Assigned(FModule) then
5423+ begin
5424+ CreateModuleFunctions;
54235425 if Module .Initialized then
5424- begin
5425- CreateModuleFunctions;
5426- CreateModuleVars;
5427- end
5426+ CreateModuleVars
54285427 else
54295428 Module .AddClient( Self );
54305429 end ;
@@ -5433,7 +5432,6 @@ procedure TPyDelphiWrapper.Initialize;
54335432procedure TPyDelphiWrapper.ModuleReady (Sender : TObject);
54345433begin
54355434 inherited ;
5436- CreateModuleFunctions;
54375435 CreateModuleVars;
54385436end ;
54395437
@@ -5542,13 +5540,13 @@ procedure TPyDelphiWrapper.SetModule(const Value: TPythonModule);
55425540 TPythonType(fHelperClassRegister.Objects[i]).Module := Value ;
55435541 if Assigned(FModule) then
55445542 if Initialized and (ComponentState * [csDesigning, csLoading] = []) then
5543+ begin
5544+ CreateModuleFunctions;
55455545 if FModule.Initialized then
5546- begin
5547- CreateModuleFunctions;
5548- CreateModuleVars;
5549- end
5546+ CreateModuleVars
55505547 else
55515548 FModule.AddClient(Self);
5549+ end ;
55525550 end ;
55535551end ;
55545552
You can’t perform that action at this time.
0 commit comments