diff options
author | Jacek Antonelli | 2008-08-15 23:45:42 -0500 |
---|---|---|
committer | Jacek Antonelli | 2008-08-15 23:45:42 -0500 |
commit | ce28e056c20bf2723f565bbf464b87781ec248a2 (patch) | |
tree | ef7b0501c4de4b631a916305cbc2a5fdc125e52d /linden/indra/newview/llfloatergodtools.cpp | |
parent | Second Life viewer sources 1.19.1.4b (diff) | |
download | meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.zip meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.tar.gz meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.tar.bz2 meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.tar.xz |
Second Life viewer sources 1.20.2
Diffstat (limited to '')
-rw-r--r-- | linden/indra/newview/llfloatergodtools.cpp | 26 |
1 files changed, 11 insertions, 15 deletions
diff --git a/linden/indra/newview/llfloatergodtools.cpp b/linden/indra/newview/llfloatergodtools.cpp index bdfa09c..3965c8b 100644 --- a/linden/indra/newview/llfloatergodtools.cpp +++ b/linden/indra/newview/llfloatergodtools.cpp | |||
@@ -71,7 +71,7 @@ | |||
71 | #include "llvlcomposition.h" | 71 | #include "llvlcomposition.h" |
72 | #include "llsurface.h" | 72 | #include "llsurface.h" |
73 | #include "llviewercontrol.h" | 73 | #include "llviewercontrol.h" |
74 | #include "llvieweruictrlfactory.h" | 74 | #include "lluictrlfactory.h" |
75 | 75 | ||
76 | #include "lltransfertargetfile.h" | 76 | #include "lltransfertargetfile.h" |
77 | #include "lltransfersourcefile.h" | 77 | #include "lltransfersourcefile.h" |
@@ -124,7 +124,7 @@ LLFloaterGodTools::LLFloaterGodTools() | |||
124 | factory_map["region"] = LLCallbackMap(createPanelRegion, this); | 124 | factory_map["region"] = LLCallbackMap(createPanelRegion, this); |
125 | factory_map["objects"] = LLCallbackMap(createPanelObjects, this); | 125 | factory_map["objects"] = LLCallbackMap(createPanelObjects, this); |
126 | factory_map["request"] = LLCallbackMap(createPanelRequest, this); | 126 | factory_map["request"] = LLCallbackMap(createPanelRequest, this); |
127 | gUICtrlFactory->buildFloater(this, "floater_god_tools.xml", &factory_map); | 127 | LLUICtrlFactory::getInstance()->buildFloater(this, "floater_god_tools.xml", &factory_map); |
128 | 128 | ||
129 | childSetTabChangeCallback("GodTools Tabs", "grid", onTabChanged, this); | 129 | childSetTabChangeCallback("GodTools Tabs", "grid", onTabChanged, this); |
130 | childSetTabChangeCallback("GodTools Tabs", "region", onTabChanged, this); | 130 | childSetTabChangeCallback("GodTools Tabs", "region", onTabChanged, this); |
@@ -853,18 +853,14 @@ void LLPanelRegionTools::onSelectRegion(void* userdata) | |||
853 | { | 853 | { |
854 | llinfos << "LLPanelRegionTools::onSelectRegion" << llendl; | 854 | llinfos << "LLPanelRegionTools::onSelectRegion" << llendl; |
855 | 855 | ||
856 | if (!gWorldp) | 856 | LLViewerRegion *regionp = LLWorld::getInstance()->getRegionFromPosGlobal(gAgent.getPositionGlobal()); |
857 | { | ||
858 | return; | ||
859 | } | ||
860 | LLViewerRegion *regionp = gWorldp->getRegionFromPosGlobal(gAgent.getPositionGlobal()); | ||
861 | if (!regionp) | 857 | if (!regionp) |
862 | { | 858 | { |
863 | return; | 859 | return; |
864 | } | 860 | } |
865 | 861 | ||
866 | LLVector3d north_east(REGION_WIDTH_METERS, REGION_WIDTH_METERS, 0); | 862 | LLVector3d north_east(REGION_WIDTH_METERS, REGION_WIDTH_METERS, 0); |
867 | gParcelMgr->selectLand(regionp->getOriginGlobal(), | 863 | LLViewerParcelMgr::getInstance()->selectLand(regionp->getOriginGlobal(), |
868 | regionp->getOriginGlobal() + north_east, FALSE); | 864 | regionp->getOriginGlobal() + north_east, FALSE); |
869 | 865 | ||
870 | } | 866 | } |
@@ -1261,12 +1257,12 @@ void LLPanelObjectTools::onClickSetBySelection(void* data) | |||
1261 | if (!panelp) return; | 1257 | if (!panelp) return; |
1262 | 1258 | ||
1263 | const BOOL non_root_ok = TRUE; | 1259 | const BOOL non_root_ok = TRUE; |
1264 | LLSelectNode* node = gSelectMgr->getSelection()->getFirstRootNode(NULL, non_root_ok); | 1260 | LLSelectNode* node = LLSelectMgr::getInstance()->getSelection()->getFirstRootNode(NULL, non_root_ok); |
1265 | if (!node) return; | 1261 | if (!node) return; |
1266 | 1262 | ||
1267 | LLString owner_name; | 1263 | LLString owner_name; |
1268 | LLUUID owner_id; | 1264 | LLUUID owner_id; |
1269 | gSelectMgr->selectGetOwner(owner_id, owner_name); | 1265 | LLSelectMgr::getInstance()->selectGetOwner(owner_id, owner_name); |
1270 | 1266 | ||
1271 | panelp->mTargetAvatar = owner_id; | 1267 | panelp->mTargetAvatar = owner_id; |
1272 | LLString name = "Object " + node->mName + " owned by " + owner_name; | 1268 | LLString name = "Object " + node->mName + " owned by " + owner_name; |
@@ -1348,8 +1344,8 @@ void LLPanelRequestTools::refresh() | |||
1348 | list->operateOnAll(LLCtrlListInterface::OP_DELETE); | 1344 | list->operateOnAll(LLCtrlListInterface::OP_DELETE); |
1349 | list->addSimpleElement(SELECTION); | 1345 | list->addSimpleElement(SELECTION); |
1350 | list->addSimpleElement(AGENT_REGION); | 1346 | list->addSimpleElement(AGENT_REGION); |
1351 | for (LLWorld::region_list_t::iterator iter = gWorldp->mActiveRegionList.begin(); | 1347 | for (LLWorld::region_list_t::iterator iter = LLWorld::getInstance()->mActiveRegionList.begin(); |
1352 | iter != gWorldp->mActiveRegionList.end(); ++iter) | 1348 | iter != LLWorld::getInstance()->mActiveRegionList.end(); ++iter) |
1353 | { | 1349 | { |
1354 | LLViewerRegion* regionp = *iter; | 1350 | LLViewerRegion* regionp = *iter; |
1355 | LLString name = regionp->getName(); | 1351 | LLString name = regionp->getName(); |
@@ -1400,7 +1396,7 @@ void LLPanelRequestTools::onClickRequest(void* data) | |||
1400 | std::string req = self->childGetValue("request"); | 1396 | std::string req = self->childGetValue("request"); |
1401 | req = req.substr(0, req.find_first_of(" ")); | 1397 | req = req.substr(0, req.find_first_of(" ")); |
1402 | std::string param = self->childGetValue("parameter"); | 1398 | std::string param = self->childGetValue("parameter"); |
1403 | gSelectMgr->sendGodlikeRequest(req, param); | 1399 | LLSelectMgr::getInstance()->sendGodlikeRequest(req, param); |
1404 | } | 1400 | } |
1405 | else if(dest == AGENT_REGION) | 1401 | else if(dest == AGENT_REGION) |
1406 | { | 1402 | { |
@@ -1409,8 +1405,8 @@ void LLPanelRequestTools::onClickRequest(void* data) | |||
1409 | else | 1405 | else |
1410 | { | 1406 | { |
1411 | // find region by name | 1407 | // find region by name |
1412 | for (LLWorld::region_list_t::iterator iter = gWorldp->mActiveRegionList.begin(); | 1408 | for (LLWorld::region_list_t::iterator iter = LLWorld::getInstance()->mActiveRegionList.begin(); |
1413 | iter != gWorldp->mActiveRegionList.end(); ++iter) | 1409 | iter != LLWorld::getInstance()->mActiveRegionList.end(); ++iter) |
1414 | { | 1410 | { |
1415 | LLViewerRegion* regionp = *iter; | 1411 | LLViewerRegion* regionp = *iter; |
1416 | if(dest == regionp->getName()) | 1412 | if(dest == regionp->getName()) |