[Pas2js] External class with custom event

Luca Olivetti luca at ventoso.org
Mon May 22 12:27:05 CEST 2023


El 22/5/23 a les 12:14, Luca Olivetti via Pas2js ha escrit:

> It seems to work OK

I forgot the Selected property and, while in the object 
(console.log(choice)) I see it is true, console.log(choice.selected) 
shows false.


   TChoice = class (TJsObject)
   private
     FActive: boolean; external name 'active';
     FDisabled: boolean; external name 'disabled';
     FElementId: string; external name 'elementId';
     FgroupId: integer; external name 'groupId';
     Fid: integer; external name 'id';
     FKeyCode: integer; external name 'keyCode';
     FLabel: string; external name 'label';
     FPlaceholder: boolean; external name 'placeholder';
     FScore:integer; external name 'score';
     FSelected:boolean; external name 'selected';
     FValue:string; external name 'value';
   public
     property Active:boolean read FActive;
     property Disabled:boolean read FDisabled;
     property ElementId:string read FElementId;
     property GroupId:integer read FGroupId;
     property Id:integer read FId;
     property KeyCode:integer read FKeyCode;
     property Label_:string read FLabel;
     property Placeholder:boolean read FPlaceHolder;
     property Score:integer read FScore;
     property Selected:boolean read FSelected;
     property Value:string read FValue;
   end;


Bye
-- 
Luca


More information about the Pas2js mailing list