コード例 #1
0
        public override void OnEnable()
        {
            var packageSources = AssetDatabase.FindAssets("t:PackageSource", new[] { "Assets", "Packages" })
                                 .Select(AssetDatabase.GUIDToAssetPath)
                                 .Select(AssetDatabase.LoadAssetAtPath <PackageSource>)
                                 .ToArray();


            Construct(packageSources);

            PackageSource.SourcesInitialized += PackageSource_SourceInitialized;
            PackageSource.LoadAllSources();
        }
コード例 #2
0
 public override void OnEnable()
 {
     PackageSource.SourcesInitialized -= PackageSource_SourceInitialized;
     PackageSource.SourcesInitialized += PackageSource_SourceInitialized;
     PackageSource.LoadAllSources();
 }
コード例 #3
0
 private void RefreshClicked()
 {
     PackageSource.LoadAllSources();
 }
コード例 #4
0
 private static void Init()
 {
     PackageSource.SourcesInitialized -= PackageSource_SourceInitialized;
     PackageSource.SourcesInitialized += PackageSource_SourceInitialized;
     PackageSource.LoadAllSources();
 }