Skip to content
This repository was archived by the owner on Dec 5, 2024. It is now read-only.

Commit 8d9c278

Browse files
Making the open method call InitializeWindow
1 parent 69fd053 commit 8d9c278

File tree

3 files changed

+4
-6
lines changed

3 files changed

+4
-6
lines changed

src/UnityExtension/Assets/Editor/GitHub.Unity/UI/HistoryView.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -395,8 +395,7 @@ public void OnEmbeddedGUI()
395395
var publishedClicked = GUILayout.Button(PublishButton, Styles.HistoryToolbarButtonStyle);
396396
if (publishedClicked)
397397
{
398-
var popupWindow = PopupWindow.Open(PopupWindow.PopupViewType.PublishView);
399-
popupWindow.InitializeWindow(EntryPoint.ApplicationManager);
398+
PopupWindow.Open(PopupWindow.PopupViewType.PublishView);
400399
}
401400
GUI.enabled = true;
402401
}

src/UnityExtension/Assets/Editor/GitHub.Unity/UI/PopupWindow.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,7 @@ public enum PopupViewType
2222
[MenuItem("GitHub/Authenticate")]
2323
public static void Launch()
2424
{
25-
var popupWindow = Open(PopupViewType.AuthenticationView);
26-
popupWindow.InitializeWindow(EntryPoint.ApplicationManager);
25+
Open(PopupViewType.AuthenticationView);
2726
}
2827

2928
public static PopupWindow Open(PopupViewType popupViewType, Action<bool> onClose = null)
@@ -41,6 +40,7 @@ public static PopupWindow Open(PopupViewType popupViewType, Action<bool> onClose
4140
popupWindow.titleContent = new GUIContent(popupWindow.ActiveView.Title, Styles.SmallLogo);
4241

4342
popupWindow.Show();
43+
popupWindow.InitializeWindow(EntryPoint.ApplicationManager);
4444
return popupWindow;
4545
}
4646

src/UnityExtension/Assets/Editor/GitHub.Unity/UI/Window.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -326,8 +326,7 @@ private void DoAccountDropdown()
326326

327327
private void SignIn(object obj)
328328
{
329-
var popupWindow = PopupWindow.Open(PopupWindow.PopupViewType.AuthenticationView);
330-
popupWindow.InitializeWindow(EntryPoint.ApplicationManager);
329+
PopupWindow.Open(PopupWindow.PopupViewType.AuthenticationView);
331330
}
332331

333332
private void GoToProfile(object obj)

0 commit comments

Comments
 (0)