Search Issue Tracker
By Design
Votes
0
Found in
4.6.0b16
Issue ID
626052
Regression
No
UI Button doesn't change to "Disabled Color" when it gets disabled by Toggle
To reproduce:
1) Create new Unity Project
2) Add "GameObject" --> UI --> Button
3) Change colors like this: "Image" Component color -> Black; Normal Color -> White; Disabled Color -> Red
4) Add "GameObject" --> UI --> Toggle
5) For "On Value Changed" event for Toggle, specify the Button component and "Button --> enabled" for the event
6) Run scene and when you disable the Button through, you'll notice that it does indeed become disabled from click events, however, the Disabled Color is not displayed, instead, an "Image" component color is displayed.
Comments (3)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Texture2D hash changes inside of an AssetBundle when rebuilding a SpriteAtlas bundle with an empty AssetPostprocessor Script enabled
- Aniso Level still applies when Generate MipMap is disabled in Texture Import Settings
- Mipmap Limit Groups long names are not truncated when creating a new Mipmap Limit Group with a long name
- “ArgumentException: Invalid double parameter.” error is thrown when Infinity is typed into the Fixed Timestep field
- GameObject becomes gray when using HDRP and STP together on macOS
Trionet
Aug 17, 2016 09:42
If the "Image" Component color is Black no nuance of black will become anything but black.
Since what highlighted, pressed and disable color do is to multiply that color with the Image color and since black is (0,0,0,1) then anything except a transparent color will be black.
Try changing the image you use to a white image and set normal color to black in the button settings. Then you can do whatever you want with the highlighted, pressed and disabled color!
yefeihe
Jun 25, 2015 18:26
Also, DO NOT set enabled to false. That will disable the Button script and make it not react to the interactable value.
shophongkong
Jan 26, 2015 19:26
Please set interactable to false. Disable color will show.