aboutsummaryrefslogtreecommitdiff
path: root/backends/graphics
diff options
context:
space:
mode:
Diffstat (limited to 'backends/graphics')
-rw-r--r--backends/graphics/windowed.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/backends/graphics/windowed.h b/backends/graphics/windowed.h
index 40fbe8baf7..bea4522d5a 100644
--- a/backends/graphics/windowed.h
+++ b/backends/graphics/windowed.h
@@ -405,9 +405,9 @@ private:
width = fracToInt(height * displayAspect);
}
}
-
- drawRect.left = ((_windowWidth - width) / 2) + _gameScreenShakeXOffset;
- drawRect.top = ((_windowHeight - height) / 2) + _gameScreenShakeYOffset;
+
+ drawRect.left = ((_windowWidth - width) / 2) + _gameScreenShakeXOffset * _windowWidth / getWidth();
+ drawRect.top = ((_windowHeight - height) / 2) + _gameScreenShakeYOffset * _windowHeight / getHeight();
drawRect.setWidth(width);
drawRect.setHeight(height);
}