Пример #1
0
        private void Initialize()
        {
            if (m_InitializeState == State.Initialized)
            {
                return;
            }

            if (m_InitializeState == State.Initializing)
            {
                Debug.LogWarning("[Package Manager Window] Nested ServicesContainer initialization detected.");
                return;
            }
            m_InitializeState = State.Initializing;

            ResolveDependencies();

            // Some services has dependencies that requires some initialization in `OnEnable`.
            m_UnityConnectProxy.OnEnable();
            m_ApplicationProxy.OnEnable();
            m_SettingsProxy.OnEnable();

            m_AssetStoreClient.OnEnable();
            m_AssetStoreOAuth.OnEnable();
            m_AssetStoreDownloadManager.OnEnable();
            m_AssetStoreCallQueue.OnEnable();

            m_UpmClient.OnEnable();

            m_PackageDatabase.OnEnable();
            m_PageManager.OnEnable();

            m_InitializeState = State.Initialized;
        }