diff options
author | Jacek Antonelli | 2008-08-15 23:45:17 -0500 |
---|---|---|
committer | Jacek Antonelli | 2008-08-15 23:45:17 -0500 |
commit | 7c207214b86dc5675e2d136cc34e9b209209dc4b (patch) | |
tree | dfbdef0c039221cfadd7c26c839f446064263ddd /linden/indra/newview/llfloaterdirectory.cpp | |
parent | Second Life viewer sources 1.18.5.0-RC (diff) | |
download | meta-impy-7c207214b86dc5675e2d136cc34e9b209209dc4b.zip meta-impy-7c207214b86dc5675e2d136cc34e9b209209dc4b.tar.gz meta-impy-7c207214b86dc5675e2d136cc34e9b209209dc4b.tar.bz2 meta-impy-7c207214b86dc5675e2d136cc34e9b209209dc4b.tar.xz |
Second Life viewer sources 1.18.5.1-RC
Diffstat (limited to '')
-rw-r--r-- | linden/indra/newview/llfloaterdirectory.cpp | 33 |
1 files changed, 25 insertions, 8 deletions
diff --git a/linden/indra/newview/llfloaterdirectory.cpp b/linden/indra/newview/llfloaterdirectory.cpp index 3b7142e..f386f5b 100644 --- a/linden/indra/newview/llfloaterdirectory.cpp +++ b/linden/indra/newview/llfloaterdirectory.cpp | |||
@@ -67,7 +67,8 @@ | |||
67 | LLFloaterDirectory* LLFloaterDirectory::sInstance = NULL; | 67 | LLFloaterDirectory* LLFloaterDirectory::sInstance = NULL; |
68 | 68 | ||
69 | LLFloaterDirectory::LLFloaterDirectory(const std::string& name) | 69 | LLFloaterDirectory::LLFloaterDirectory(const std::string& name) |
70 | : LLFloater(name, "FloaterFindRect2", "") | 70 | : LLFloater(name, "FloaterFindRect2", ""), |
71 | mMinimizing(false) | ||
71 | { | 72 | { |
72 | sInstance = this; | 73 | sInstance = this; |
73 | 74 | ||
@@ -470,16 +471,32 @@ void LLFloaterDirectory::setVisible(BOOL visible) | |||
470 | } | 471 | } |
471 | 472 | ||
472 | // virtual | 473 | // virtual |
474 | void LLFloaterDirectory::setMinimized(BOOL b) | ||
475 | { | ||
476 | mMinimizing = true; | ||
477 | LLFloater::setMinimized(b); | ||
478 | mMinimizing = false; | ||
479 | } | ||
480 | |||
481 | // virtual | ||
473 | void LLFloaterDirectory::reshape(S32 width, S32 height, BOOL called_from_parent) | 482 | void LLFloaterDirectory::reshape(S32 width, S32 height, BOOL called_from_parent) |
474 | { | 483 | { |
475 | // Don't let this floater go below its minimum width and height, ever. | 484 | // HACK: If the window (screen window) is made too small, the search floater |
476 | if (width < getMinWidth()) | 485 | // will get resized below its minimum size, resulting in buttons hanging off |
477 | { | 486 | // the edge. So we need to limit reshape size. |
478 | width = getMinWidth(); | 487 | // BUT: Minimizing the window is considered a resize. |
479 | } | 488 | // Remove this code when DEV-5670 is fixed ("Sanitize floater sizing behavior |
480 | if (height < getMinHeight()) | 489 | // when SL window is made very small"). JC |
490 | if (!mMinimizing) | ||
481 | { | 491 | { |
482 | height = getMinHeight(); | 492 | if (width < getMinWidth()) |
493 | { | ||
494 | width = getMinWidth(); | ||
495 | } | ||
496 | if (height < getMinHeight()) | ||
497 | { | ||
498 | height = getMinHeight(); | ||
499 | } | ||
483 | } | 500 | } |
484 | LLFloater::reshape(width, height, called_from_parent); | 501 | LLFloater::reshape(width, height, called_from_parent); |
485 | } | 502 | } |