[Slider] When select a value not drag the slider ,the onChange method doesn't notify
See original GitHub issueDescription: When I update the libray from com.google.android.material:material:1.2.0-alpha02 to com.google.android.material:material:1.2.0-alpha03, but when I select a new value the tooltip didn’t show and the method of onChange didn’t work,the same problem occur in the catalog
Expected behavior: it should working like 1.20-alpha02
Source code:
<com.google.android.material.slider.Slider
android:id="@+id/slide"
android:layout_width="0dp"
android:layout_height="wrap_content"
/>
slide.valueFrom = 0f
slide.valueTo = 20f
slide.stepSize = 1f
slide.setOnChangeListener { slider, value ->
//do something
}
Android API version: Android Q
Material Library version: com.google.android.material:material:1.2.0-alpha03
Device: oneplus 6
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
onchange event on input type=range is not triggering in ...
This reads the slider as needed, but continues firing unnecessarily during any mouse-over events, even when the user has not clicked and is...
Read more >Event triggered when the slider value changes (no drag)
Hello, Is there an event triggered when the value of a slider changes? In the above example, the alert("in") method is never called....
Read more >onchange vs. oninput for Range Sliders - Impressive Webs
The change event does not fire immediately, demonstrated by the fact that the value on the page does not change until the slider...
Read more >Slider class - material library - Flutter - Dart API docs
The "value indicator", which is a shape that pops up when the user is dragging the thumb to indicate the value being selected....
Read more >How to trigger onchange event on input type=range while ...
It is a frequent UI design for a range slider to showcase the immediate change in the depicted value as the user moves...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
In
1.2.0-alpha03
we added a fix to prevent the Slider from intercepting scroll events from the parent. It looks like in this case it’s no longer dispatching the change because we avoid handling the touch event unless there is enough horizontal movement. I’ll take a look.I also can’t set slider to a value by selecting it. New value is selected only when I drag of swipe the slider. 1.2.0-alpha06