aboutsummaryrefslogtreecommitdiff
path: root/backends/graphics/windowed.h
diff options
context:
space:
mode:
Diffstat (limited to 'backends/graphics/windowed.h')
-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..99115275de 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 * width / getWidth();
+ drawRect.top = ((_windowHeight - height) / 2) + _gameScreenShakeYOffset * height / getHeight();
drawRect.setWidth(width);
drawRect.setHeight(height);
}