Engines/FlatRedBallXNA/FlatRedBall/Screens/ScreenManager.cs
/// <summary>
/// Loads a screen.  Should only be called once during initialization.
/// </summary>
/// <param name="screenToStartWithType">Qualified name of the class to load.</param>
Loads a screen.  Should only be called once during initialization.
Loads a screen . Should only be called once during initialization .
public static void Start(Type screenToStartWithType)
        {
#if WINDOWS_8 || UWP
            MainAssembly =
                screenToStartWithType.GetTypeInfo().Assembly;
#else
            MainAssembly =
                screenToStartWithType.Assembly;
#endif
            string screenToStartWith = screenToStartWithType.FullName;
            if (mCurrentScreen != null)
            {
                throw new InvalidOperationException("You can't call Start if there is already a Screen.  Did you call Start twice?");
            }
            else
            {
                StateManager.Current.Initialize();
                if (ShouldActivateScreen && RehydrateAction != null)
                {
					RehydrateAction(screenToStartWith);
                }
                else
                {
                    mCurrentScreen = LoadScreen(screenToStartWith, null, true, true);
                    ShouldActivateScreen = false;
                }
            }
        }
public static void Start ( Type screenToStartWithType ) { if WINDOWS_8 || UWP MainAssembly = screenToStartWithType . GetTypeInfo ( ) . Assembly ; else MainAssembly = screenToStartWithType . Assembly ; endif string screenToStartWith = screenToStartWithType . FullName ; if ( mCurrentScreen != null ) { throw new InvalidOperationException ( " " ) ; } else { StateManager . Current . Initialize ( ) ; if ( ShouldActivateScreen && RehydrateAction != null ) { RehydrateAction ( screenToStartWith ) ; } else { mCurrentScreen = LoadScreen ( screenToStartWith , null , true , true ) ; ShouldActivateScreen = false ; } } }
Loads a screen.
Loads a screen .
screenToStartWithType
Type
Qualified name of the class to load.
Qualified name of the class to load .