summaryrefslogtreecommitdiff
path: root/indra/newview/llviewermenu.cpp
diff options
context:
space:
mode:
authorMnikolenko Productengine <mnikolenko@productengine.com>2022-03-25 18:48:44 +0200
committerMnikolenko Productengine <mnikolenko@productengine.com>2022-03-25 18:48:44 +0200
commit3f0a0051ba7cd54ddd83daed392996d9b23b9ee1 (patch)
tree650de7cfaadd712bc8f1f4a95e93dd175c16f829 /indra/newview/llviewermenu.cpp
parentd11df206018ea5192266141f242ff6372597ecd6 (diff)
SL-17036 update menu item similar to NavMesh icon
Diffstat (limited to 'indra/newview/llviewermenu.cpp')
-rw-r--r--indra/newview/llviewermenu.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index b902d346cb..77f8160aa5 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -94,6 +94,7 @@
#include "llmarketplacefunctions.h"
#include "llmenuoptionpathfindingrebakenavmesh.h"
#include "llmoveview.h"
+#include "llnavigationbar.h"
#include "llparcel.h"
#include "llrootview.h"
#include "llsceneview.h"
@@ -5331,12 +5332,10 @@ class LLToolsEnablePathfindingRebakeRegion : public view_listener_t
{
bool returnValue = false;
- if (LLPathfindingManager::getInstance() != NULL)
- {
- LLMenuOptionPathfindingRebakeNavmesh *rebakeInstance = LLMenuOptionPathfindingRebakeNavmesh::getInstance();
- returnValue = (rebakeInstance->canRebakeRegion() &&
- (rebakeInstance->getMode() == LLMenuOptionPathfindingRebakeNavmesh::kRebakeNavMesh_Available));
- }
+ if (LLNavigationBar::instanceExists())
+ {
+ returnValue = LLNavigationBar::getInstance()->isRebakeNavMeshAvailable();
+ }
return returnValue;
}
};