summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rw-r--r--indra/llui/llnotifications.cpp4
-rw-r--r--indra/llui/llnotificationtemplate.h2
-rw-r--r--indra/newview/llpathfindingmanager.cpp14
-rw-r--r--indra/newview/llpathfindingmanager.h1
-rw-r--r--indra/newview/skins/default/xui/en/notifications.xml34
-rw-r--r--indra/newview/skins/default/xui/en/strings.xml3
6 files changed, 58 insertions, 0 deletions
diff --git a/indra/llui/llnotifications.cpp b/indra/llui/llnotifications.cpp
index 8aa548b974..83fa6da863 100644
--- a/indra/llui/llnotifications.cpp
+++ b/indra/llui/llnotifications.cpp
@@ -1477,6 +1477,10 @@ bool LLNotifications::loadTemplates()
{
replaceFormText(notification.form_ref.form, "$canceltext", notification.form_ref.form_template.cancel_text);
}
+ if(notification.form_ref.form_template.help_text.isProvided())
+ {
+ replaceFormText(notification.form_ref.form, "$helptext", notification.form_ref.form_template.help_text);
+ }
if(notification.form_ref.form_template.ignore_text.isProvided())
{
replaceFormText(notification.form_ref.form, "$ignoretext", notification.form_ref.form_template.ignore_text);
diff --git a/indra/llui/llnotificationtemplate.h b/indra/llui/llnotificationtemplate.h
index fb50c9c123..56b18eb81a 100644
--- a/indra/llui/llnotificationtemplate.h
+++ b/indra/llui/llnotificationtemplate.h
@@ -121,6 +121,7 @@ struct LLNotificationTemplate
Optional<std::string> yes_text,
no_text,
cancel_text,
+ help_text,
ignore_text;
TemplateRef()
@@ -128,6 +129,7 @@ struct LLNotificationTemplate
yes_text("yestext"),
no_text("notext"),
cancel_text("canceltext"),
+ help_text("helptext"),
ignore_text("ignoretext")
{}
};
diff --git a/indra/newview/llpathfindingmanager.cpp b/indra/newview/llpathfindingmanager.cpp
index e754e77588..59cfc398f2 100644
--- a/indra/newview/llpathfindingmanager.cpp
+++ b/indra/newview/llpathfindingmanager.cpp
@@ -42,6 +42,9 @@
#include "llpathfindinglinksetlist.h"
#include "llpathfindingcharacterlist.h"
#include "llhttpnode.h"
+#include "llnotificationsutil.h"
+#include "lltrans.h"
+#include "llweb.h"
#include <boost/function.hpp>
#include <boost/signals2.hpp>
@@ -663,6 +666,17 @@ void LLPathfindingManager::handleAgentStateUpdate(const LLSD &pContent)
EAgentState agentState = (pContent.get(ALTER_NAVMESH_OBJECTS_FIELD).asBoolean() ? kAgentStateUnfrozen : kAgentStateFrozen);
setAgentState(agentState);
+
+ LLSD substitutions, payload;
+ LLNotificationsUtil::add("AutomaticAgentStateUnfreeze", substitutions, payload, boost::bind(&LLPathfindingManager::handleAgentStateUserNotification, this, _1, _2));
+}
+
+void LLPathfindingManager::handleAgentStateUserNotification(const LLSD &pNotification, const LLSD &pResponse)
+{
+ if (LLNotificationsUtil::getSelectedOption(pNotification, pResponse) == 1)
+ {
+ LLWeb::loadURL(LLTrans::getString("Pathfinding_Wiki_URL"));
+ }
}
std::string LLPathfindingManager::getNavMeshStatusURLForRegion(LLViewerRegion *pRegion) const
diff --git a/indra/newview/llpathfindingmanager.h b/indra/newview/llpathfindingmanager.h
index 9797c783b5..f5d7cd1332 100644
--- a/indra/newview/llpathfindingmanager.h
+++ b/indra/newview/llpathfindingmanager.h
@@ -123,6 +123,7 @@ private:
void handleAgentStateResult(const LLSD &pContent, EAgentState pRequestedAgentState);
void handleAgentStateError(U32 pStatus, const std::string &pReason, const std::string &pURL);
void handleAgentStateUpdate(const LLSD &pContent);
+ void handleAgentStateUserNotification(const LLSD &pNotification, const LLSD &pResponse);
std::string getNavMeshStatusURLForRegion(LLViewerRegion *pRegion) const;
std::string getRetrieveNavMeshURLForRegion(LLViewerRegion *pRegion) const;
diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml
index 3b03bc0aed..a0a670f233 100644
--- a/indra/newview/skins/default/xui/en/notifications.xml
+++ b/indra/newview/skins/default/xui/en/notifications.xml
@@ -77,6 +77,21 @@
</form>
</template>
+ <template name="okhelpignore">
+ <form>
+ <button
+ default="true"
+ index="0"
+ name="OK_okhelpignore"
+ text="$yestext"/>
+ <button
+ index="1"
+ name="Help_okhelpignore"
+ text="$helptext"/>
+ <ignore text="$ignoretext"/>
+ </form>
+ </template>
+
<template name="yesnocancelbuttons">
<form>
<button
@@ -1286,6 +1301,25 @@ The region [REGION] does not allow terraforming.
<notification
icon="alertmodal.tga"
+ name="AutomaticAgentStateUnfreeze"
+ type="alertmodal">
+You have automatically switched into Unfrozen mode because of one of the following reasons:
+
+- You rezzed an object marked as permanent
+- You returned an object marked as permanent
+
+After you finish modifying your permanent objects, please remember to switch back to Frozen mode from the menu option Build->Pathfinding->Basic Setup.
+ <tag>confirm</tag>
+ <usetemplate
+ name="okhelpignore"
+ yestext="OK"
+ helptext="More Info"
+ ignoretext="Launch browser to view pathfinding help"
+ />
+ </notification>
+
+ <notification
+ icon="alertmodal.tga"
name="CannotCopyWarning"
type="alertmodal">
You do not have permission to copy the following items:
diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml
index 61935c77c3..5fb629b704 100644
--- a/indra/newview/skins/default/xui/en/strings.xml
+++ b/indra/newview/skins/default/xui/en/strings.xml
@@ -3888,6 +3888,9 @@ Try enclosing path to the editor with double quotes.
<string name="Preview">Preview</string>
<string name="Normal">Normal</string>
+ <!-- Pathfinding -->
+ <string name="Pathfinding_Wiki_URL">http://wiki.secondlife.com/wiki/Pathfinding_Tools_in_the_Second_Life_Viewer</string>
+
<!-- Snapshot image quality levels -->
<string name="snapshot_quality_very_low">Very Low</string>
<string name="snapshot_quality_low">Low</string>