From 3b4dece82c48f714890f7675d8556e8af45d9e13 Mon Sep 17 00:00:00 2001 From: Lucas Moura Belo Date: Wed, 16 Dec 2020 13:50:59 -0300 Subject: [PATCH 1/4] Adding the TTextControl wrapper --- Source/fmx/WrapFmxControls.pas | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/Source/fmx/WrapFmxControls.pas b/Source/fmx/WrapFmxControls.pas index 2d0ed951..d00c5ab9 100644 --- a/Source/fmx/WrapFmxControls.pas +++ b/Source/fmx/WrapFmxControls.pas @@ -95,6 +95,16 @@ TPyDelphiStyledControl = class(TPyDelphiControl) property DelphiObject: TStyledControl read GetDelphiObject write SetDelphiObject; end; + TPyDelphiTextControl = class(TPyDelphiStyledControl) + private + function GetDelphiObject: TTextControl; + procedure SetDelphiObject(const Value: TTextControl); + public + class function DelphiObjectClass: TClass; override; + // Properties + property DelphiObject: TTextControl read GetDelphiObject write SetDelphiObject; + end; + implementation type @@ -402,6 +412,7 @@ procedure TControlsRegistration.RegisterWrappers( inherited; APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiControl); APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiStyledControl); + APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiTextControl); end; { TControlsAccess } @@ -627,6 +638,23 @@ function TPyDelphiStyledControl.Set_StyleLookup(AValue: PPyObject; Result := -1; end; +{ TPyDelphiTextControl } + +class function TPyDelphiTextControl.DelphiObjectClass: TClass; +begin + Result := TTextControl; +end; + +function TPyDelphiTextControl.GetDelphiObject: TTextControl; +begin + Result := TTextControl(inherited DelphiObject); +end; + +procedure TPyDelphiTextControl.SetDelphiObject(const Value: TTextControl); +begin + inherited DelphiObject := Value; +end; + initialization RegisteredUnits.Add(TControlsRegistration.Create); From 760b095783ff12f031d5d736a1c00c7a2c3701da Mon Sep 17 00:00:00 2001 From: Lucas Moura Belo Date: Wed, 16 Dec 2020 14:14:12 -0300 Subject: [PATCH 2/4] Adding TStyleBook wrapper --- Source/fmx/WrapFmxControls.pas | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/Source/fmx/WrapFmxControls.pas b/Source/fmx/WrapFmxControls.pas index d00c5ab9..c4aaf2f4 100644 --- a/Source/fmx/WrapFmxControls.pas +++ b/Source/fmx/WrapFmxControls.pas @@ -105,6 +105,16 @@ TPyDelphiTextControl = class(TPyDelphiStyledControl) property DelphiObject: TTextControl read GetDelphiObject write SetDelphiObject; end; + TPyDelphiStyleBook = class(TPyDelphiFmxObject) + private + function GetDelphiObject: TStyleBook; + procedure SetDelphiObject(const Value: TStyleBook); + public + class function DelphiObjectClass: TClass; override; + // Properties + property DelphiObject: TStyleBook read GetDelphiObject write SetDelphiObject; + end; + implementation type @@ -413,6 +423,7 @@ procedure TControlsRegistration.RegisterWrappers( APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiControl); APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiStyledControl); APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiTextControl); + APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiStyleBook); end; { TControlsAccess } @@ -655,6 +666,23 @@ procedure TPyDelphiTextControl.SetDelphiObject(const Value: TTextControl); inherited DelphiObject := Value; end; +{ TPyDelphiStyleBook } + +class function TPyDelphiStyleBook.DelphiObjectClass: TClass; +begin + Result := TStyleBook; +end; + +function TPyDelphiStyleBook.GetDelphiObject: TStyleBook; +begin + Result := TStyleBook(inherited DelphiObject); +end; + +procedure TPyDelphiStyleBook.SetDelphiObject(const Value: TStyleBook); +begin + inherited DelphiObject := Value; +end; + initialization RegisteredUnits.Add(TControlsRegistration.Create); From 0655048aa4e7fcd895f4252bf9582d656785582a Mon Sep 17 00:00:00 2001 From: Lucas Moura Belo Date: Wed, 16 Dec 2020 14:16:14 -0300 Subject: [PATCH 3/4] Adding TPopup wrapper --- Source/fmx/WrapFmxControls.pas | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/Source/fmx/WrapFmxControls.pas b/Source/fmx/WrapFmxControls.pas index c4aaf2f4..909be0f7 100644 --- a/Source/fmx/WrapFmxControls.pas +++ b/Source/fmx/WrapFmxControls.pas @@ -115,6 +115,16 @@ TPyDelphiStyleBook = class(TPyDelphiFmxObject) property DelphiObject: TStyleBook read GetDelphiObject write SetDelphiObject; end; + TPyDelphiPopup = class(TPyDelphiStyledControl) + private + function GetDelphiObject: TPopup; + procedure SetDelphiObject(const Value: TPopup); + public + class function DelphiObjectClass: TClass; override; + // Properties + property DelphiObject: TPopup read GetDelphiObject write SetDelphiObject; + end; + implementation type @@ -683,6 +693,23 @@ procedure TPyDelphiStyleBook.SetDelphiObject(const Value: TStyleBook); inherited DelphiObject := Value; end; +{ TPyDelphiPopup } + +class function TPyDelphiPopup.DelphiObjectClass: TClass; +begin + Result := TPopup; +end; + +function TPyDelphiPopup.GetDelphiObject: TPopup; +begin + Result := TPopup(inherited DelphiObject); +end; + +procedure TPyDelphiPopup.SetDelphiObject(const Value: TPopup); +begin + inherited DelphiObject := Value; +end; + initialization RegisteredUnits.Add(TControlsRegistration.Create); From 5197e6adb9299681ec6bf823dda3d72050697546 Mon Sep 17 00:00:00 2001 From: Lucas Moura Belo Date: Wed, 16 Dec 2020 14:17:44 -0300 Subject: [PATCH 4/4] Registering wrapper for TPopup --- Source/fmx/WrapFmxControls.pas | 1 + 1 file changed, 1 insertion(+) diff --git a/Source/fmx/WrapFmxControls.pas b/Source/fmx/WrapFmxControls.pas index 909be0f7..48b0a8f4 100644 --- a/Source/fmx/WrapFmxControls.pas +++ b/Source/fmx/WrapFmxControls.pas @@ -434,6 +434,7 @@ procedure TControlsRegistration.RegisterWrappers( APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiStyledControl); APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiTextControl); APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiStyleBook); + APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiPopup); end; { TControlsAccess }