MarcinusX / NumberPicker

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Dynamically Set the picker as not editable

murad-alm opened this issue · comments

Hi there,
thanks for the awesome package!

Is there any way to dynamically disable the scrolling or set the picker as not-editable? Thanks!

Edit: typo

This is very old, but you can just wrap the picker in other classes to handle the focus. I wrapped nested it like
InkWell(IgnorePointer(NumberPicker())) where the InkWell has an 'onTap' handler that updates a State boolean that controls the ignoring property in the IgnorePointer. That way, the NumberPicker is only active when you tap it.