// static void LLPanelPlace::onClickTeleport(void* data) { LLPanelPlace* self = (LLPanelPlace*)data; LLView* parent_viewp = self->getParent(); LLFloater* parent_floaterp = dynamic_cast<LLFloater*>(parent_viewp); if (parent_floaterp) { parent_floaterp->closeFloater(); } // LLFloater* parent_floaterp = (LLFloater*)self->getParent(); parent_viewp->setVisible(false); LLFloaterWorldMap* worldmap_instance = LLFloaterWorldMap::getInstance(); if(self->mLandmarkAssetID.notNull() && worldmap_instance) { gAgent.teleportViaLandmark(self->mLandmarkAssetID); worldmap_instance->trackLandmark(self->mLandmarkAssetID); } else if (!self->mPosGlobal.isExactlyZero() && worldmap_instance) { gAgent.teleportViaLocation(self->mPosGlobal); worldmap_instance->trackLocation(self->mPosGlobal); } }
// static void LLPanelPlace::onClickTeleport(void* data) { LLPanelPlace* self = (LLPanelPlace*)data; LLView* parent_viewp = self->getParent(); LLFloater* parent_floaterp = dynamic_cast<LLFloater*>(parent_viewp); if (parent_floaterp) { parent_floaterp->close(); } // LLFloater* parent_floaterp = (LLFloater*)self->getParent(); parent_viewp->setVisible(false); if(self->mLandmarkAssetID.notNull()) { gAgent.teleportViaLandmark(self->mLandmarkAssetID); // remember this must be an inventory item id, not an asset UUID gFloaterWorldMap->trackLandmark(self->mLandmarkItemID); } else if (!self->mPosGlobal.isExactlyZero()) { gAgent.teleportViaLocation(self->mPosGlobal); gFloaterWorldMap->trackLocation(self->mPosGlobal); } }