Esempio n. 1
0
 private void OnGUI()
 {
     if (UPM.RemoteSources.Repositories.Count == 0)
     {
         UPM.LoadRemoteRepos();
     }
     DrawMainMenu();
     DrawRepositorySelector();
     DrawOutputConsole();
 }
Esempio n. 2
0
 private static void OpenPackageManager()
 {
     if (!window)
     {
         window = Editor.CreateInstance <UPMWindow>();
     }
     UPM.LoadRemoteRepos();
     if (!GitCommand.IsGitInstalled)
     {
         EditorUtility.DisplayDialog("Error",
                                     "Git not installed UPM will not work until you have installed Git on your computer.",
                                     "Ok");
     }
     else
     {
         window.Show();
     }
 }
Esempio n. 3
0
    private void DrawRepositorySelector()
    {
        GUILayout.BeginHorizontal();
        scrollPosition = GUILayout.BeginScrollView(scrollPosition);
        foreach (var repo in UPM.RemoteSources.Repositories)
        {
            GUILayout.BeginHorizontal();
            GUILayout.Label(repo.PackageName, GUILayout.Width(200));
            GUILayout.Button("Package Description");
            if (GUILayout.Button("Install Package"))
            {
                UPM.PullPackage(repo);
            }

            GUILayout.EndHorizontal();
        }
        GUILayout.EndScrollView();
        GUILayout.EndHorizontal();
    }
Esempio n. 4
0
 private static void createDummyRepos()
 {
     UPM.SaveRepositoriesList(UPM.UPM_MASTER_REPOS_LOCAL);
 }
Esempio n. 5
0
 private static void UpdateRemoteRepos()
 {
     UPM.CheckForUpdates();
 }