@@ -574,6 +574,24 @@ export function Grid(columns: number, spacing?: number, content?: ViewBuilder):
574574 return container ;
575575}
576576
577+ export function Switch ( checked : boolean ) {
578+ const ret = new SwitchView ( ) ;
579+ // ret.setChecked(checked);
580+ return ret ;
581+ }
582+
583+ export function CheckBox ( checked : boolean ) {
584+ const ret = new CheckBoxView ( ) ;
585+ // ret.setChecked(checked);
586+ return ret ;
587+ }
588+
589+ export function RadioButton ( checked : boolean ) {
590+ const ret = new RadioButtonView ( ) ;
591+ // ret.setChecked(checked);
592+ return ret ;
593+ }
594+
577595export class RootLayoutView extends RemoteViews {
578596 constructor ( id ?: string ) {
579597 super ( ) ;
@@ -1005,6 +1023,54 @@ export class TextClockView extends RemoteViews {
10051023 }
10061024}
10071025
1026+ export class CheckBoxView extends RemoteViews {
1027+ constructor ( id ?: string ) {
1028+ super ( ) ;
1029+ // this[native_] = new org.nativescript.widgets.RemoteViews.CheckBox(id ?? null);
1030+ }
1031+
1032+ get native ( ) {
1033+ return this [ native_ ] ;
1034+ }
1035+
1036+ setChecked ( checked : boolean ) : this {
1037+ this . native . setChecked ( checked ) ;
1038+ return this ;
1039+ }
1040+ }
1041+
1042+ export class RadioButtonView extends RemoteViews {
1043+ constructor ( id ?: string ) {
1044+ super ( ) ;
1045+ // this[native_] = new org.nativescript.widgets.RemoteViews.RadioButton(id ?? null);
1046+ }
1047+
1048+ get native ( ) {
1049+ return this [ native_ ] ;
1050+ }
1051+
1052+ setChecked ( checked : boolean ) : this {
1053+ this . native . setChecked ( checked ) ;
1054+ return this ;
1055+ }
1056+ }
1057+
1058+ export class SwitchView extends RemoteViews {
1059+ constructor ( id ?: string ) {
1060+ super ( ) ;
1061+ // this[native_] = new org.nativescript.widgets.RemoteViews.Switch(id ?? null);
1062+ }
1063+
1064+ get native ( ) {
1065+ return this [ native_ ] ;
1066+ }
1067+
1068+ setChecked ( checked : boolean ) : this {
1069+ this . native . setChecked ( checked ) ;
1070+ return this ;
1071+ }
1072+ }
1073+
10081074function toJSArray ( array : androidNative . Array < number > ) {
10091075 const jsArray : number [ ] = [ ] ;
10101076 for ( let i = 0 ; i < array . length ; i ++ ) {
0 commit comments