UI Buttons Interactable switch


I have 2 buttons with color tint transition mode and I set interactable= false on the one I click and set the other one to interactable= true.

Simple switch with button everything is working fine…

But, when the button is intractable again the button don’t take the normal color but stay on the Highlight color until I go over it with the mouse…

Why ?

I tried everything to force the normal color but there’s just no way. I can’t find where the color tint is applied to the button. I even looked in the source of the Unity UI system…

Can someone explain the trick here ? I’m getting quite mad against the Unity UI system for this kind of weird behavior.

Thanks in advance !

Try it:

void Update()
if(button.GetComponent().interactable == true)
button.GetComponent().color = Color.white;