summaryrefslogtreecommitdiffhomepage
path: root/StarsEx
diff options
context:
space:
mode:
authorAki <please@ignore.pl>2022-04-03 20:25:14 +0200
committerAki <please@ignore.pl>2022-04-03 20:25:14 +0200
commit029213d28484dbc4d3f874a88ce4e7b13d68b373 (patch)
tree329ae8acbf63c35a62ca533c1234fbae96870b46 /StarsEx
parent8fe1e0179fc4f08c9288c50ba5505fe040dea042 (diff)
downloadstarshatter-029213d28484dbc4d3f874a88ce4e7b13d68b373.zip
starshatter-029213d28484dbc4d3f874a88ce4e7b13d68b373.tar.gz
starshatter-029213d28484dbc4d3f874a88ce4e7b13d68b373.tar.bz2
Moved UpdateScreen to GameWinDX9
Diffstat (limited to 'StarsEx')
-rw-r--r--StarsEx/Game.cpp8
-rw-r--r--StarsEx/GameWinDX9.cpp14
-rw-r--r--StarsEx/GameWinDX9.h1
3 files changed, 15 insertions, 8 deletions
diff --git a/StarsEx/Game.cpp b/StarsEx/Game.cpp
index 56cb115..6cf7321 100644
--- a/StarsEx/Game.cpp
+++ b/StarsEx/Game.cpp
@@ -196,14 +196,6 @@ Game::GameState()
void
Game::UpdateScreen()
{
- if (!screen || !video) return;
-
- if (screen->Refresh()) {
- video->Present();
- }
- else {
- Panic::Panic("Screen refresh failed.");
- }
}
// +--------------------------------------------------------------------+
diff --git a/StarsEx/GameWinDX9.cpp b/StarsEx/GameWinDX9.cpp
index b4f7979..3020eea 100644
--- a/StarsEx/GameWinDX9.cpp
+++ b/StarsEx/GameWinDX9.cpp
@@ -580,6 +580,20 @@ GameWinDX9::Run()
void
+GameWinDX9::UpdateScreen()
+{
+ if (!screen || !video) return;
+
+ if (screen->Refresh()) {
+ video->Present();
+ }
+ else {
+ Panic::Panic("Screen refresh failed.");
+ }
+}
+
+
+void
GameWinDX9::Activate(bool f)
{
Game::Activate(f);
diff --git a/StarsEx/GameWinDX9.h b/StarsEx/GameWinDX9.h
index 88ad113..f194504 100644
--- a/StarsEx/GameWinDX9.h
+++ b/StarsEx/GameWinDX9.h
@@ -36,6 +36,7 @@ public:
virtual bool LoadPalette(PALETTEENTRY* pal, BYTE* inv);
virtual int Run() override;
+ virtual void UpdateScreen() override;
virtual void Activate(bool f) override;
virtual void Pause(bool f) override;
void ShowStats();