Make widget react correctly when used in the UI