private void DrawWindowLabel() { GUILayout.BeginHorizontal(); if (!_isApiKeyValid) { GUILayout.Label("Please set valid api key in the Svrf Api Key game object", EditorStyles.boldLabel); GUILayout.FlexibleSpace(); var isCreateApiKeyObjectClicked = GUILayout.Button("Create Api Key game object", GUILayout.Height(30)); if (isCreateApiKeyObjectClicked) { SvrfObjectsFactory.CreateSvrfApiKey(); } } else { GUILayout.Label("Discover Svrf face filter and 3D models", EditorStyles.boldLabel); GUILayout.FlexibleSpace(); } var isRefreshClicked = GUILayout.Button(_refreshIcon, GUILayout.Width(30), GUILayout.Height(30)); GUILayout.EndHorizontal(); if (isRefreshClicked) { Refresh(); } }
public static void CreateSvrfApiKey(MenuCommand menuCommand) { var gameObject = SvrfObjectsFactory.CreateSvrfApiKey(); SetParentAndAlign(gameObject, menuCommand); }