Skip to content

StackLayout isUserInteractionEnabled="false" value is not working #3215

@MadhuSudhanBhaskar

Description

@MadhuSudhanBhaskar

StackLayout isUserInteractionEnabled="false" value is not working

https://docs.nativescript.org/api-reference/classes/_ui_core_view_.view.html#isuserinteractionenabled
Yes I did verify on stackover flow and other channels

I am trying to disable use interaction when I have a activity indicator. Below code is stack layout example.

<Button text="Sign in" (tap) = "test()">
<ActivityIndicator style="color:red" [busy] = "isLoading" >

Which platform(s) does your issue occur on?
Android [For now I tested this on Android alone]

Please provide the following version numbers that your issue occurs with:

  • CLI: (run tns --version to fetch it) 2.4.0
  • Cross-platform modules: (check the 'version' attribute in the
    node_modules/tns-core-modules/package.json file in your project) 2.4.0
  • Runtime(s): (look for the "tns-android" and "tns-ios" properties in the
    package.json file of your project) 2.4.1 (Android)
  • Plugin(s): (look for the version number in the package.json file of your
    project)

Please tell us how to recreate the issue in as much detail as possible.

I have a button which enables the activity indicator, from my function I am trying to set isUserInteractionEnabled to false(Boolean) and trying to disable the interaction on the screen for certain time. But I still can click different buttons on the screen.

Is there code involved? If so, please share the minimal amount of code needed to recreate the problem.

Some pieces of code.

<TextField hint="Password" secure="true" [(ngModel)]="user.password">
<Button text="Sign in" (tap) = "test()">
<ActivityIndicator style="color:red" [busy] = "isLoading" >

Component function
test() {
this.isLoading = !this.isLoading;
this.defaultTest = false;
}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions