Browse Source

Highlight currently selected combobox item

habeebweeb 4 years ago
parent
commit
05d769dc39
1 changed files with 3 additions and 1 deletions
  1. 3 1
      MultipleMaids/ComboBox2.cs

+ 3 - 1
MultipleMaids/ComboBox2.cs

@@ -32,6 +32,8 @@ public class ComboBox2
                     GUIStyle boxStyle,
                     GUIStyle listStyle)
     {
+        listStyle.onNormal.textColor = listStyle.onHover.textColor;
+        listStyle.onNormal.background = listStyle.onHover.background;
         if (forceToUnShow)
         {
             forceToUnShow = false;
@@ -108,4 +110,4 @@ public class ComboBox2
     {
         return (int)((1.0 + (Screen.width / 1280.0 - 1.0) * 0.600000023841858) * i);
     }
-}
+}