summaryrefslogtreecommitdiff
path: root/indra/llwindow/llwindowmacosx.cpp
diff options
context:
space:
mode:
authorOz Linden <oz@lindenlab.com>2012-04-17 13:47:31 -0700
committerOz Linden <oz@lindenlab.com>2012-04-17 13:47:31 -0700
commit19e0cc93a8af661dbac47552474a704ade600c74 (patch)
tree5d7e539a4c98607a189c6e472732b75608379abb /indra/llwindow/llwindowmacosx.cpp
parentee1124e1c02b1a8be0cc8d2cbce1083dca3b40a2 (diff)
parent3ccda1f2855ae9e5b3f519236e9b4f233d542d1a (diff)
DRTVWR-139: merge back 3.3.1-beta2 fixes
Diffstat (limited to 'indra/llwindow/llwindowmacosx.cpp')
-rw-r--r--indra/llwindow/llwindowmacosx.cpp25
1 files changed, 25 insertions, 0 deletions
diff --git a/indra/llwindow/llwindowmacosx.cpp b/indra/llwindow/llwindowmacosx.cpp
index c952f8bbcf..32bb84cba5 100644
--- a/indra/llwindow/llwindowmacosx.cpp
+++ b/indra/llwindow/llwindowmacosx.cpp
@@ -1266,6 +1266,31 @@ BOOL LLWindowMacOSX::setSizeImpl(const LLCoordScreen size)
return TRUE;
}
+BOOL LLWindowMacOSX::setSizeImpl(const LLCoordWindow size)
+{
+ Rect client_rect;
+ if (mWindow)
+ {
+ OSStatus err = GetWindowBounds(mWindow, kWindowContentRgn, &client_rect);
+ if (err == noErr)
+ {
+ client_rect.right = client_rect.left + size.mX;
+ client_rect.bottom = client_rect.top + size.mY;
+ err = SetWindowBounds(mWindow, kWindowContentRgn, &client_rect);
+ }
+ if (err == noErr)
+ {
+ return TRUE;
+ }
+ else
+ {
+ llinfos << "Error setting size" << err << llendl;
+ return FALSE;
+ }
+ }
+ return FALSE;
+}
+
void LLWindowMacOSX::swapBuffers()
{
aglSwapBuffers(mContext);