How to reset a button's error state?

Is there any API to reset a button’s error state, i.e., the exclamation mark and the exception stacktrace popup? I’d like to do that the first thing in the click listener so that the user won’t be confused by the error from last click.

Thanks for any pointers

Button.setComponentError(null) should do the trick.

Nice. I saw it in the javadoc but couldn’t tell what it would do exactly.
Thanks.