From 30527b2206e7fce2890c3c44825ff0bef85aa5a0 Mon Sep 17 00:00:00 2001 From: Richard Linden Date: Tue, 18 Oct 2011 14:09:52 -0700 Subject: EXP-1409 FIX WASD controls don't move avatar while Move floater is in focus moved "chrome" flags to xui separated hiding floater title from setting chrome toolbar toggle button now moves floaters to frontmost and doesn't necessarily rely on focus --- indra/llui/llfloater.cpp | 22 +++++++--------------- 1 file changed, 7 insertions(+), 15 deletions(-) (limited to 'indra/llui/llfloater.cpp') diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index d1d840729d..869ad4410b 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -174,6 +174,7 @@ LLFloater::Params::Params() save_rect("save_rect", false), save_visibility("save_visibility", false), can_dock("can_dock", false), + show_title("show_title", true), open_positioning("open_positioning", LLFloaterEnums::OPEN_POSITIONING_NONE), specified_left("specified_left"), specified_bottom("specified_bottom"), @@ -1142,10 +1143,6 @@ void LLFloater::setMinimized(BOOL minimize) mButtonsEnabled[BUTTON_RESTORE] = TRUE; } - if (mDragHandle) - { - mDragHandle->setVisible(TRUE); - } setBorderVisible(TRUE); for(handle_set_iter_t dependent_it = mDependents.begin(); @@ -1296,19 +1293,9 @@ void LLFloater::setIsChrome(BOOL is_chrome) mButtons[BUTTON_CLOSE]->setToolTip(LLStringExplicit(getButtonTooltip(Params(), BUTTON_CLOSE, is_chrome))); } - // no titles displayed on "chrome" floaters - if (mDragHandle) - mDragHandle->setTitleVisible(!is_chrome); - LLPanel::setIsChrome(is_chrome); } -void LLFloater::setTitleVisible(bool visible) -{ - if (mDragHandle) - mDragHandle->setTitleVisible(visible); -} - // Change the draw style to account for the foreground state. void LLFloater::setForeground(BOOL front) { @@ -1812,7 +1799,7 @@ void LLFloater::draw() { drawChild(mButtons[i]); } - drawChild(mDragHandle); + drawChild(mDragHandle, 0, 0, TRUE); } else { @@ -2991,6 +2978,11 @@ void LLFloater::initFromParams(const LLFloater::Params& p) { setCloseCallback(initCommitCallback(p.close_callback)); } + + if (mDragHandle) + { + mDragHandle->setTitleVisible(p.show_title); + } } boost::signals2::connection LLFloater::setMinimizeCallback( const commit_signal_t::slot_type& cb ) -- cgit v1.2.3 From ccabbec51c87b27d204e49a6bcad72e7ad7aa095 Mon Sep 17 00:00:00 2001 From: Richard Nelson Date: Wed, 19 Oct 2011 13:28:15 -0700 Subject: floaters only save rect when explicitly moved by user --- indra/llui/llfloater.cpp | 1 - 1 file changed, 1 deletion(-) (limited to 'indra/llui/llfloater.cpp') diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index 869ad4410b..3085921e04 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -539,7 +539,6 @@ LLFloater::~LLFloater() delete mResizeHandle[i]; } - storeRectControl(); setVisible(false); // We're not visible if we're destroyed storeVisibilityControl(); storeDockStateControl(); -- cgit v1.2.3