diff options
author | Oz Linden <oz@lindenlab.com> | 2012-03-30 15:56:38 -0400 |
---|---|---|
committer | Oz Linden <oz@lindenlab.com> | 2012-03-30 15:56:38 -0400 |
commit | 74d199c1dd10660f72293c84888af412764f1da8 (patch) | |
tree | 0b4c4137abde8283c5a85da08f19de1aea335c2a /indra/llwindow/llwindowmacosx.cpp | |
parent | 3c3ee709677a0c60420eae84a55a7b61113b4949 (diff) | |
parent | 6e4e971fd27826f90c1728c7fd17242083e230fc (diff) |
merge changes for vmrg-233
Diffstat (limited to 'indra/llwindow/llwindowmacosx.cpp')
-rw-r--r-- | indra/llwindow/llwindowmacosx.cpp | 25 |
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); |