mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
fix(slider): correct maxValue setter for android (#4346)
The setter should invoke setNativeValuesSilently with the new value and max value respectively. fixes #4343
This commit is contained in:
@@ -80,8 +80,7 @@ export class Slider extends SliderBase {
|
||||
try {
|
||||
nativeView.setMax(newMaxValue);
|
||||
nativeView.setProgress(newValue);
|
||||
}
|
||||
finally {
|
||||
} finally {
|
||||
this._supressNativeValue = false;
|
||||
}
|
||||
}
|
||||
@@ -102,7 +101,7 @@ export class Slider extends SliderBase {
|
||||
return 100;
|
||||
}
|
||||
[maxValueProperty.setNative](value: number) {
|
||||
this.nativeView.setMax(value - this.minValue);
|
||||
this.setNativeValuesSilently(value - this.minValue, value);
|
||||
}
|
||||
|
||||
[colorProperty.getDefault](): number {
|
||||
|
||||
Reference in New Issue
Block a user