diff options
author | Steve Bennetts <steve@lindenlab.com> | 2009-12-07 15:57:31 -0800 |
---|---|---|
committer | Steve Bennetts <steve@lindenlab.com> | 2009-12-07 15:57:31 -0800 |
commit | 0b4b03fe3e92f0991b8145a2ba8267a20ce53581 (patch) | |
tree | adef5f205fd2ba632c1e6db79d575b1c3ceb081d /indra/newview/llinventorypanel.cpp | |
parent | 374aa101ab0296d9bed3e7c592e4820930042f6e (diff) | |
parent | c3a82913deb9b23ef1f22b6d002893b36146553a (diff) |
Merge from product-engine
Diffstat (limited to 'indra/newview/llinventorypanel.cpp')
-rw-r--r-- | indra/newview/llinventorypanel.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/indra/newview/llinventorypanel.cpp b/indra/newview/llinventorypanel.cpp index 54f528de8d..bf70bb66fa 100644 --- a/indra/newview/llinventorypanel.cpp +++ b/indra/newview/llinventorypanel.cpp @@ -903,10 +903,12 @@ LLInventoryPanel* LLInventoryPanel::getActiveInventoryPanel(BOOL auto_open) if (!auto_open) return NULL; // D. Open the inventory side panel and use that. - LLSD key; LLSidepanelInventory *sidepanel_inventory = - dynamic_cast<LLSidepanelInventory *>(LLSideTray::getInstance()->showPanel("sidepanel_inventory", key)); - if (sidepanel_inventory) + dynamic_cast<LLSidepanelInventory *>(side_tray->getPanel("sidepanel_inventory")); + + // Use the inventory side panel only if it is already active. + // Activating it may unexpectedly switch off the currently active tab in some cases. + if (sidepanel_inventory && (LLPanel*)side_tray->getActiveTab() == (LLPanel*)sidepanel_inventory) { return sidepanel_inventory->getActivePanel(); } |