ol-ext icon indicating copy to clipboard operation
ol-ext copied to clipboard

How to disable the ol.control.Button

Open 1Map opened this issue 3 years ago • 1 comments

I would like my ol.control.Button to have disabled attribute. How can I achieve this?

So, enabled button is like:

And, disabled button is like:

1Map avatar Sep 12 '22 18:09 1Map

Button control can't be disabled you have to handle it in your listener. You can use Toggle button that can be disabled (using setDisable()).

Viglino avatar Sep 13 '22 06:09 Viglino