linuxgurugamer / ClickThroughBlocker

GNU Lesser General Public License v3.0
31 stars 17 forks source link

Missing static functions on GUI and GUILayout #6

Closed Lisias closed 4 years ago

Lisias commented 5 years ago

I noticed that the following functions are missing from the CTB's GUI :

    public static Rect ModalWindow (int id, Rect clientRect, UnityEngine.GUI.WindowFunction func, string text);
        public static Rect ModalWindow (int id, Rect clientRect, UnityEngine.GUI.WindowFunction func, Texture image);
    public static Rect ModalWindow (int id, Rect clientRect, UnityEngine.GUI.WindowFunction func, GUIContent content);
        public static Rect ModalWindow (int id, Rect clientRect, UnityEngine.GUI.WindowFunction func, string text, GUIStyle style);
        public static Rect ModalWindow (int id, Rect clientRect, UnityEngine.GUI.WindowFunction func, Texture image, GUIStyle style);
        public static Rect ModalWindow (int id, Rect clientRect, UnityEngine.GUI.WindowFunction func, GUIContent content, GUIStyle style);

It's feasible to implement them? I had some issues with Modal Windows on some AddOns, and perhaps this is the place to solve them.

Additionally, the following functions are "missing" from GUILayout, as there're counterparts on the UnityEngine:

    public static Rect Window (int id, Rect screenRect, UnityEngine.GUI.WindowFunction func, Texture image, GUIStyle style, params GUILayoutOption[] options);
    public static Rect Window (int id, Rect screenRect, UnityEngine.GUI.WindowFunction func, GUIContent content, GUIStyle style, params GUILayoutOption[] options);

I think that they should be implemented to guarantee a 1 to 1 replacement for the flawed UnityEngine.GUILayout.

(updated due mishandling of my test beds - this time I triple checked :) )

linuxgurugamer commented 5 years ago

being added now

linuxgurugamer commented 5 years ago

Please try the attached file, it contains the changes you requested.

000_ClickThroughBlocker-0.1.8.zip

Lisias commented 5 years ago

Sorry the lateness. Only got time to dive into it today. I'm giving this a test drive.

linuxgurugamer commented 5 years ago

Status of this?

linuxgurugamer commented 4 years ago

Reopen if you still need this