private void InitializeInternal()
        {
            lock (initializedLock)
            {
                if (IsInitialized)
                {
                    return;
                }

                instance = this;

                if (Application.isPlaying)
                {
                    DontDestroyOnLoad(instance.transform.root);
                }

                Application.quitting += ApplicationOnQuitting;

#if UNITY_EDITOR
                UnityEditor.EditorApplication.playModeStateChanged += playModeState =>
                {
                    if (playModeState == UnityEditor.PlayModeStateChange.ExitingEditMode && activeProfile == null)
                    {
                        UnityEditor.EditorApplication.isPlaying = false;
                        UnityEditor.Selection.activeObject      = Instance;
                        UnityEditor.EditorGUIUtility.PingObject(Instance);
                    }
                };
#endif // UNITY_EDITOR

                Initialize();
            }
        }
        /// <summary>
        /// Static function to determine if the MixedRealityManager class has been initialized or not.
        /// </summary>
        /// <returns></returns>
        public static bool ConfirmInitialized()
        {
            // ReSharper disable once UnusedVariable
            // Assigning the Instance to access is used Implicitly.
            MixedRealityManager access = Instance;

            return(IsInitialized);
        }
        /// <summary>
        /// The MonoBehaviour Destroy event, which is then circulated to all active managers prior to the Mixed Reality Manager being destroyed
        /// </summary>
        private void OnDestroy()
        {
            DestroyAllManagers();

            if (instance == this)
            {
                instance          = null;
                searchForInstance = true;
            }
        }