Bug with GUILayout

If you try to open a modal window (or any other window) from a button inside a layoutgroup, editor will throw an error complaining that “EndLayoutGroup: BeginLayoutGroup must be called first.” probably because of the new window, the previous window couldnt finish its layout group cycle, or something.

Before opening a modal window, you should GUIUtility.ExitGUI.

1 Like