Example #1
0
 private void ShowPopup(Rect rect)
 {
     AssetDatabase.SaveAssets();
     this.ReserveRight(39f, ref rect);
     this.ReserveBottom(5f, ref rect);
     if (CollabToolbarWindow.ShowCenteredAtPosition(rect))
     {
         GUIUtility.ExitGUI();
     }
 }
Example #2
0
        void ShowPopup(Rect rect)
        {
            // window should be centered on the button
            ReserveRight(kCollabButtonWidth / 2, ref rect);
            ReserveBottom(5, ref rect);
            // calculate screen rect before saving assets since it might open the AssetSaveDialog window
            var screenRect = GUIUtility.GUIToScreenRect(rect);

            // save all the assets
            AssetDatabase.SaveAssets();
            if (CollabToolbarWindow.ShowCenteredAtPosition(screenRect))
            {
                GUIUtility.ExitGUI();
            }
        }