コード例 #1
0
ファイル: GamePlatform.cs プロジェクト: Powerino73/paradox
        protected override void Destroy()
        {
            if (gameWindow != null)
            {
                gameWindow.Dispose();
                gameWindow = null;
            }

            Activated = null;
            Deactivated = null;
            Exiting = null;
            Idle = null;
            Resume = null;
            Suspend = null;
        }
コード例 #2
0
ファイル: GamePlatform.cs プロジェクト: Powerino73/paradox
        public void Run(GameContext gameContext)
        {
            gameWindow = CreateWindow(gameContext);

            // Register on Activated 
            gameWindow.GameContext = gameContext;
            gameWindow.Activated += OnActivated;
            gameWindow.Deactivated += OnDeactivated;
            gameWindow.InitCallback = OnInitCallback;
            gameWindow.RunCallback = OnRunCallback;

            var windowCreated = WindowCreated;
            if (windowCreated != null)
            {
                windowCreated(this, EventArgs.Empty);
            }

            gameWindow.Run();
        }