From bf8d3e1d304007cbd2a723808193e172b3e56c8a Mon Sep 17 00:00:00 2001 From: prep Date: Fri, 1 Jun 2012 16:02:12 -0400 Subject: Migrated restoration of physics capsule into pathing character --- indra/newview/llfloaterpathfindingcharacters.cpp | 20 ++++++++++++++++++++ indra/newview/llfloaterpathfindingcharacters.h | 2 ++ indra/newview/llfloaterpathfindingobjects.cpp | 19 +------------------ indra/newview/llfloaterpathfindingobjects.h | 2 -- 4 files changed, 23 insertions(+), 20 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/llfloaterpathfindingcharacters.cpp b/indra/newview/llfloaterpathfindingcharacters.cpp index 8915683b6d..0dbc2a303a 100644 --- a/indra/newview/llfloaterpathfindingcharacters.cpp +++ b/indra/newview/llfloaterpathfindingcharacters.cpp @@ -57,8 +57,11 @@ void LLFloaterPathfindingCharacters::openCharactersViewer() { LLFloaterReg::toggleInstanceOrBringToFront("pathfinding_characters"); } + void LLFloaterPathfindingCharacters::onClose(bool pIsAppQuitting) { + unhideAnyCharacters(); + LLFloaterPathfindingObjects::onClose( pIsAppQuitting ); } LLFloaterPathfindingCharacters::LLFloaterPathfindingCharacters(const LLSD& pSeed) @@ -246,3 +249,20 @@ void LLFloaterPathfindingCharacters::updateStateOnEditFields() LLFloaterPathfindingObjects::updateStateOnEditFields(); } + + +void LLFloaterPathfindingCharacters::unhideAnyCharacters( ) +{ + std::vector selectedItems = mObjectsScrollList->getAllSelected(); + int numSelectedItems = selectedItems.size(); + uuid_vec_t selectedUUIDs; + if (numSelectedItems > 0) + { + for (std::vector::const_iterator itemIter = selectedItems.begin(); + itemIter != selectedItems.end(); ++itemIter) + { + const LLScrollListItem *listItem = *itemIter; + gPipeline.restoreHiddenObject( listItem->getUUID() ); + } + } +} diff --git a/indra/newview/llfloaterpathfindingcharacters.h b/indra/newview/llfloaterpathfindingcharacters.h index 3c1aee2b80..397191943a 100644 --- a/indra/newview/llfloaterpathfindingcharacters.h +++ b/indra/newview/llfloaterpathfindingcharacters.h @@ -59,6 +59,8 @@ protected: virtual LLPathfindingObjectListPtr getEmptyObjectList() const; + void unhideAnyCharacters(); + private: LLSD buildCharacterScrollListData(const LLPathfindingCharacter *pCharacterPtr) const; diff --git a/indra/newview/llfloaterpathfindingobjects.cpp b/indra/newview/llfloaterpathfindingobjects.cpp index da7c51599f..002849695a 100644 --- a/indra/newview/llfloaterpathfindingobjects.cpp +++ b/indra/newview/llfloaterpathfindingobjects.cpp @@ -90,8 +90,7 @@ void LLFloaterPathfindingObjects::onOpen(const LLSD &pKey) void LLFloaterPathfindingObjects::onClose(bool pIsAppQuitting) { - unhideAnyCharacters(); - + if (mGodLevelChangeSlot.connected()) { mGodLevelChangeSlot.disconnect(); @@ -693,19 +692,3 @@ LLPathfindingObjectPtr LLFloaterPathfindingObjects::findObject(const LLScrollLis return objectPtr; } - -void LLFloaterPathfindingObjects::unhideAnyCharacters( ) -{ - std::vector selectedItems = mObjectsScrollList->getAllSelected(); - int numSelectedItems = selectedItems.size(); - uuid_vec_t selectedUUIDs; - if (numSelectedItems > 0) - { - for (std::vector::const_iterator itemIter = selectedItems.begin(); - itemIter != selectedItems.end(); ++itemIter) - { - const LLScrollListItem *listItem = *itemIter; - gPipeline.restoreHiddenObject( listItem->getUUID() ); - } - } -} diff --git a/indra/newview/llfloaterpathfindingobjects.h b/indra/newview/llfloaterpathfindingobjects.h index e0f3c12419..7e7f1b9449 100644 --- a/indra/newview/llfloaterpathfindingobjects.h +++ b/indra/newview/llfloaterpathfindingobjects.h @@ -124,8 +124,6 @@ private: LLPathfindingObjectPtr findObject(const LLScrollListItem *pListItem) const; - void unhideAnyCharacters( ); - protected: LLScrollListCtrl *mObjectsScrollList; LLTextBase *mMessagingStatus; -- cgit v1.2.3