From 4c89e7389383e2943334ad8ec185b8935cbe7db8 Mon Sep 17 00:00:00 2001 From: Steven Bennetts Date: Thu, 8 Oct 2009 22:39:17 +0000 Subject: Fixed a problem where floaters that failed to load their XML would still be opened. This was particularly a problem with Modal Dialogs since the UI would loose focus with no floater to respond to. Reviewed by Leyla --- indra/llui/llfloater.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'indra/llui/llfloater.cpp') diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index b7a15a2b33..51e2b5dea4 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -2564,10 +2564,10 @@ void LLFloater::initFromParams(const LLFloater::Params& p) LLFastTimer::DeclareTimer POST_BUILD("Floater Post Build"); -void LLFloater::initFloaterXML(LLXMLNodePtr node, LLView *parent, LLXMLNodePtr output_node) +bool LLFloater::initFloaterXML(LLXMLNodePtr node, LLView *parent, LLXMLNodePtr output_node) { Params params(LLUICtrlFactory::getDefaultParams()); - LLXUIParser::instance().readXUI(node, params); + LLXUIParser::instance().readXUI(node, params); // *TODO: Error checking if (output_node) { @@ -2613,5 +2613,7 @@ void LLFloater::initFloaterXML(LLXMLNodePtr node, LLView *parent, LLXMLNodePtr o gFloaterView->adjustToFitScreen(this, FALSE); // Floaters loaded from XML should all fit on screen moveResizeHandlesToFront(); + + return true; // *TODO: Error checking } -- cgit v1.2.3 From 20e56a6925b4d4106059a73a22170beb5a38be1e Mon Sep 17 00:00:00 2001 From: Steven Bennetts Date: Tue, 13 Oct 2009 16:25:48 +0000 Subject: merge https://svn.aws.productengine.com/secondlife/export-from-ll/viewer-2-0@1992 https://svn.aws.productengine.com/secondlife/pe/stable-2@2004 -> viewer-2.0.0-3 * Bugs: EXT-1091 EXT-1418 EXT-996 EXT-1150 EXT-1188 EXT-1417 EXT-1181 EXT-1058 EXT-1397 EXT-836 EXT-1437 EXT-1379 * Dev: EXT-1291 EXT-1255 EXT-992 EXT-96 EXT-1157 --- indra/llui/llfloater.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'indra/llui/llfloater.cpp') diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index 51e2b5dea4..8d2783db20 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -926,6 +926,9 @@ void LLFloater::setMinimized(BOOL minimize) if (minimize) { + // minimized flag should be turned on before release focus + mMinimized = TRUE; + mExpandedRect = getRect(); // If the floater has been dragged while minimized in the @@ -987,8 +990,6 @@ void LLFloater::setMinimized(BOOL minimize) } } - mMinimized = TRUE; - // Reshape *after* setting mMinimized reshape( minimized_width, floater_header_size, TRUE); } -- cgit v1.2.3 From 925f01f6a066113049e8c829c6fc3875c69ef566 Mon Sep 17 00:00:00 2001 From: Martin Reddy Date: Thu, 15 Oct 2009 13:08:12 +0000 Subject: DEV-41253: Updated the help context calculation code so that it will now search through a panel's children to see if there are any visible tabs that have a help topic string defined. If so, we use this string. Updated all of the XUI files that include a tab_container to define help topic strings for their child panels. I named all of these strings with the floater name as the prefix and "tab" at the end. For example, "preferences_display_tab" or "people_nearby_tab". --- indra/llui/llfloater.cpp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'indra/llui/llfloater.cpp') diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index 8d2783db20..47ca4899df 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -1443,7 +1443,18 @@ void LLFloater::onClickHelp( LLFloater* self ) { if (self && LLUI::sHelpImpl) { - LLUI::sHelpImpl->showTopic(self->getHelpTopic()); + // get the help topic for this floater + std::string help_topic = self->getHelpTopic(); + + // but use a more specific help topic for the currently + // displayed tab inside of this floater, if present + LLPanel *curtab = self->childGetVisibleTabWithHelp(); + if (curtab) + { + help_topic = curtab->getHelpTopic(); + } + + LLUI::sHelpImpl->showTopic(help_topic); } } -- cgit v1.2.3