summaryrefslogtreecommitdiff
path: root/indra/newview/llviewerwindow.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llviewerwindow.cpp')
-rw-r--r--indra/newview/llviewerwindow.cpp14
1 files changed, 12 insertions, 2 deletions
diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp
index cf21ac4e5d..140cbb4e04 100644
--- a/indra/newview/llviewerwindow.cpp
+++ b/indra/newview/llviewerwindow.cpp
@@ -2161,8 +2161,18 @@ void LLViewerWindow::reshape(S32 width, S32 height)
if (!maximized
&& mWindow->getSize(&window_size))
{
- gSavedSettings.setS32("WindowWidth", window_size.mX);
- gSavedSettings.setS32("WindowHeight", window_size.mY);
+ U32 min_window_width=gSavedSettings.getU32("MinWindowWidth");
+ if ( window_size.mX < min_window_width )
+ window_size.mX=min_window_width;
+ gSavedSettings.setU32("WindowWidth", window_size.mX);
+
+ U32 min_window_height=gSavedSettings.getU32("MinWindowHeight");
+ if ( window_size.mY < min_window_height )
+ window_size.mY=min_window_height;
+ gSavedSettings.setU32("WindowHeight", window_size.mY);
+
+ // tell the OS specific window code about min windoow size
+ mWindow->setMinSize(min_window_width, min_window_height);
}
LLViewerStats::getInstance()->setStat(LLViewerStats::ST_WINDOW_WIDTH, (F64)width);