summaryrefslogtreecommitdiff
path: root/indra/llwindow/llwindowsdl.cpp
diff options
context:
space:
mode:
authorRichard Linden <none@none>2012-02-23 12:39:32 -0800
committerRichard Linden <none@none>2012-02-23 12:39:32 -0800
commit9da67fff0a21ae7af2f99c90be267b089eaafeb6 (patch)
treee32bf21579865a0e079e5a55828ef12d072a7cce /indra/llwindow/llwindowsdl.cpp
parent3053712f446a22316d31bfcedd89c3f175ec4f21 (diff)
EXP-1832 FIX Viewer Size not persistent across logins
made Set Window Size correctly set interior window rect, preserving measured dimensions
Diffstat (limited to 'indra/llwindow/llwindowsdl.cpp')
-rw-r--r--indra/llwindow/llwindowsdl.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/indra/llwindow/llwindowsdl.cpp b/indra/llwindow/llwindowsdl.cpp
index 5f5baceef8..3d33af9d9b 100644
--- a/indra/llwindow/llwindowsdl.cpp
+++ b/indra/llwindow/llwindowsdl.cpp
@@ -981,6 +981,25 @@ BOOL LLWindowSDL::setSizeImpl(const LLCoordScreen size)
return FALSE;
}
+BOOL LLWindowSDL::setSizeImpl(const LLCoordWindow size)
+{
+ if(mWindow)
+ {
+ // Push a resize event onto SDL's queue - we'll handle it
+ // when it comes out again.
+ SDL_Event event;
+ event.type = SDL_VIDEORESIZE;
+ event.resize.w = size.mX;
+ event.resize.h = size.mY;
+ SDL_PushEvent(&event); // copied into queue
+
+ return TRUE;
+ }
+
+ return FALSE;
+}
+
+
void LLWindowSDL::swapBuffers()
{
if (mWindow)