summaryrefslogtreecommitdiff
path: root/src/client.cpp
diff options
context:
space:
mode:
authorThorbjørn Lindeijer <thorbjorn@lindeijer.nl>2012-07-12 23:10:37 +0200
committerThorbjørn Lindeijer <thorbjorn@lindeijer.nl>2012-07-12 23:10:37 +0200
commit55fc460429899df2d976a11d4521eb2f6ab56367 (patch)
tree7cecc9f16227dc31a46b3d043a7f356eb8d16f63 /src/client.cpp
parent6fb4a7f6e0b793a0d3033e1ffdc31c115c8313eb (diff)
downloadmana-55fc460429899df2d976a11d4521eb2f6ab56367.tar.gz
mana-55fc460429899df2d976a11d4521eb2f6ab56367.tar.bz2
mana-55fc460429899df2d976a11d4521eb2f6ab56367.tar.xz
mana-55fc460429899df2d976a11d4521eb2f6ab56367.zip
Implemented scaling in OpenGL mode
The screen will be scaled up as much as possible, while keeping a minimum 'virtual' resolution of 640x360.
Diffstat (limited to 'src/client.cpp')
-rw-r--r--src/client.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/client.cpp b/src/client.cpp
index 28affce6..ce29f1b1 100644
--- a/src/client.cpp
+++ b/src/client.cpp
@@ -1397,7 +1397,7 @@ void Client::handleVideoResize(int width, int height)
// Keep a minimum size. This isn't adhered to by the actual window, but
// it keeps some window positions from getting messed up.
width = std::max(640, width);
- height = std::max(480, height);
+ height = std::max(360, height);
if (graphics->getWidth() == width && graphics->getHeight() == height)
return;
@@ -1408,7 +1408,8 @@ void Client::handleVideoResize(int width, int height)
false,
graphics->getHWAccel()))
{
- videoResized(width, height);
+ videoResized(graphics->getWidth(),
+ graphics->getHeight());
// Since everything appears to have worked out, remember to store the
// new size in the configuration.