summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Borovkov <iborovkov@productengine.com>2010-02-02 17:58:29 +0200
committerIgor Borovkov <iborovkov@productengine.com>2010-02-02 17:58:29 +0200
commit250680a07871001bdb108b5aab33f04847ab823f (patch)
tree7d99129bd71d6de87962a633d4325c70a7892a3d
parent85cb82fdda339c573ecddf5010d9e78f8e9a984d (diff)
fixed EXT-4755 Own context menu in voice chat participants list has 'Add Friend' and 'Pay' enabled
--HG-- branch : product-engine
-rw-r--r--indra/newview/lllogchat.cpp12
-rw-r--r--indra/newview/llnotificationhandlerutil.cpp6
-rw-r--r--indra/newview/llparticipantlist.cpp3
-rw-r--r--indra/newview/skins/default/xui/en/floater_im_session.xml1
-rw-r--r--indra/newview/skins/default/xui/en/menu_participant_list.xml3
5 files changed, 20 insertions, 5 deletions
diff --git a/indra/newview/lllogchat.cpp b/indra/newview/lllogchat.cpp
index dc187bf36c..96ce01c05f 100644
--- a/indra/newview/lllogchat.cpp
+++ b/indra/newview/lllogchat.cpp
@@ -138,16 +138,20 @@ void LLLogChat::saveHistory(const std::string& filename,
const LLUUID& from_id,
const std::string& line)
{
- if(!filename.size())
+ std::string tmp_filename = filename;
+ LLStringUtil::trim(tmp_filename);
+ if (tmp_filename.empty())
{
- llinfos << "Filename is Empty!" << llendl;
+ std::string warn = "Chat history filename [" + filename + "] is empty!";
+ llwarning(warn, 666);
+ llassert(tmp_filename.size());
return;
}
-
+
llofstream file (LLLogChat::makeLogFileName(filename), std::ios_base::app);
if (!file.is_open())
{
- llinfos << "Couldn't open chat history log!" << llendl;
+ llwarns << "Couldn't open chat history log! - " + filename << llendl;
return;
}
diff --git a/indra/newview/llnotificationhandlerutil.cpp b/indra/newview/llnotificationhandlerutil.cpp
index e2a748a1c5..b8e0892b02 100644
--- a/indra/newview/llnotificationhandlerutil.cpp
+++ b/indra/newview/llnotificationhandlerutil.cpp
@@ -168,6 +168,12 @@ void LLHandlerUtil::logToIMP2P(const LLNotificationPtr& notification, bool to_fi
session_name = "chat";
}
+ //there still appears a log history file with weird name " .txt"
+ if (" " == session_name || "{waiting}" == session_name || "{nobody}" == session_name)
+ {
+ llwarning("Weird session name (" + session_name + ") for notification " + notification->getName(), 666)
+ }
+
if(to_file_only)
{
logToIM(IM_NOTHING_SPECIAL, session_name, name, notification->getMessage(),
diff --git a/indra/newview/llparticipantlist.cpp b/indra/newview/llparticipantlist.cpp
index f83f3eba96..ad47e351ee 100644
--- a/indra/newview/llparticipantlist.cpp
+++ b/indra/newview/llparticipantlist.cpp
@@ -583,7 +583,8 @@ void LLParticipantList::LLParticipantListMenu::moderateVoiceOtherParticipants(co
bool LLParticipantList::LLParticipantListMenu::enableContextMenuItem(const LLSD& userdata)
{
std::string item = userdata.asString();
- if (item == "can_mute_text" || "can_block" == item || "can_share" == item || "can_im" == item)
+ if (item == "can_mute_text" || "can_block" == item || "can_share" == item || "can_im" == item
+ || "can_pay" == item || "can_add" == item)
{
return mUUIDs.front() != gAgentID;
}
diff --git a/indra/newview/skins/default/xui/en/floater_im_session.xml b/indra/newview/skins/default/xui/en/floater_im_session.xml
index 9aaa660574..f8fd40632c 100644
--- a/indra/newview/skins/default/xui/en/floater_im_session.xml
+++ b/indra/newview/skins/default/xui/en/floater_im_session.xml
@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater
+ can_tear_off="false"
legacy_header_height="18"
background_visible="true"
follows="all"
diff --git a/indra/newview/skins/default/xui/en/menu_participant_list.xml b/indra/newview/skins/default/xui/en/menu_participant_list.xml
index 805ffbae66..d03a7e3d41 100644
--- a/indra/newview/skins/default/xui/en/menu_participant_list.xml
+++ b/indra/newview/skins/default/xui/en/menu_participant_list.xml
@@ -78,6 +78,9 @@
name="Pay">
<menu_item_call.on_click
function="Avatar.Pay" />
+ <menu_item_call.on_enable
+ function="ParticipantList.EnableItem"
+ parameter="can_pay" />
</menu_item_call>
<menu_item_separator
layout="topleft" />