summaryrefslogtreecommitdiff
path: root/indra/newview/llinventoryfunctions.cpp
diff options
context:
space:
mode:
authorSeth ProductEngine <slitovchuk@productengine.com>2011-09-27 21:05:05 +0300
committerSeth ProductEngine <slitovchuk@productengine.com>2011-09-27 21:05:05 +0300
commit0f3221e25d6261d7f29b5b37391156c07fde1d0c (patch)
treeb0bd6ec7e8f5434f2b715e6d0755912c9744fb14 /indra/newview/llinventoryfunctions.cpp
parenta80d5f2b46b21a8d1a48da4b4d2c740cb8260928 (diff)
EXP-1225 FIXED Added a floater for My Inventory side tab.
- Replaced calls to LLSideTray with LLFloaterSidePanelContainer. - Added LLFloaterSidePanelContainer::getPanel<T>() for getting custom type panels.
Diffstat (limited to 'indra/newview/llinventoryfunctions.cpp')
-rw-r--r--indra/newview/llinventoryfunctions.cpp17
1 files changed, 12 insertions, 5 deletions
diff --git a/indra/newview/llinventoryfunctions.cpp b/indra/newview/llinventoryfunctions.cpp
index 0af013fde5..acec02b507 100644
--- a/indra/newview/llinventoryfunctions.cpp
+++ b/indra/newview/llinventoryfunctions.cpp
@@ -47,6 +47,7 @@
#include "llappviewer.h"
//#include "llfirstuse.h"
#include "llfloaterinventory.h"
+#include "llfloatersidepanelcontainer.h"
#include "llfocusmgr.h"
#include "llfolderview.h"
#include "llgesturemgr.h"
@@ -459,22 +460,28 @@ BOOL get_is_category_renameable(const LLInventoryModel* model, const LLUUID& id)
void show_task_item_profile(const LLUUID& item_uuid, const LLUUID& object_id)
{
- LLSideTray::getInstance()->showPanel("sidepanel_inventory", LLSD().with("id", item_uuid).with("object", object_id));
+ LLFloaterSidePanelContainer::showPanel("my_inventory", LLSD().with("id", item_uuid).with("object", object_id));
}
void show_item_profile(const LLUUID& item_uuid)
{
LLUUID linked_uuid = gInventory.getLinkedItemID(item_uuid);
- LLSideTray::getInstance()->showPanel("sidepanel_inventory", LLSD().with("id", linked_uuid));
+ LLFloaterSidePanelContainer::showPanel("my_inventory", LLSD().with("id", linked_uuid));
}
void show_item_original(const LLUUID& item_uuid)
{
+ LLFloater* floater_my_inventory = LLFloaterReg::getInstance("my_inventory");
+ if (!floater_my_inventory)
+ {
+ llwarns << "Could not find My Inventory floater" << llendl;
+ return;
+ }
+
//sidetray inventory panel
- LLSidepanelInventory *sidepanel_inventory =
- dynamic_cast<LLSidepanelInventory *>(LLSideTray::getInstance()->getPanel("sidepanel_inventory"));
+ LLSidepanelInventory *sidepanel_inventory = LLFloaterSidePanelContainer::getPanel<LLSidepanelInventory>("my_inventory");
- bool reset_inventory_filter = !LLSideTray::getInstance()->isPanelActive("sidepanel_inventory");
+ bool reset_inventory_filter = !floater_my_inventory->isInVisibleChain();
LLInventoryPanel* active_panel = LLInventoryPanel::getActiveInventoryPanel();
if (!active_panel)