Merge remote-tracking branch 'singu/master'

This commit is contained in:
Aleric Inglewood
2013-11-26 22:15:00 +01:00
14 changed files with 67 additions and 36 deletions

View File

@@ -4694,6 +4694,14 @@ void LLAppViewer::handleLoginComplete()
gDebugInfo["MainloopTimeoutState"] = LLAppViewer::instance()->mMainloopTimeout->getState(); gDebugInfo["MainloopTimeoutState"] = LLAppViewer::instance()->mMainloopTimeout->getState();
} }
// After login is complete, check if the crash report has been sent in this session
// If it has, insert a notification
if (LLCrashLogger::sReportID)
{
LLNotificationsUtil::add("CrashReportSent", LLSD().with("REPORT_ID", llformat("%d", LLCrashLogger::sReportID)));
LLCrashLogger::sReportID = 0;
}
mOnLoginCompleted(); mOnLoginCompleted();
writeDebugInfo(); writeDebugInfo();

View File

@@ -63,11 +63,17 @@ public:
virtual void result(const LLSD& content) virtual void result(const LLSD& content)
{ {
std::string msg = "Crash report successfully sent"; std::string msg = "Crash report successfully sent";
if (content.has("message")) if (content.has("message"))
{ {
msg += ": " + content["message"].asString(); msg += ": " + content["message"].asString();
} }
llinfos << msg << llendl; llinfos << msg << llendl;
if (content.has("report_id"))
{
LLCrashLogger::sReportID = content["report_id"].asInteger();
}
} }
virtual AIHTTPTimeoutPolicy const& getHTTPTimeoutPolicy(void) const virtual AIHTTPTimeoutPolicy const& getHTTPTimeoutPolicy(void) const
@@ -93,6 +99,8 @@ LLCrashLogger::~LLCrashLogger()
} }
/*static*/ S32 LLCrashLogger::sReportID = 0;
// TRIM_SIZE must remain larger than LINE_SEARCH_SIZE. // TRIM_SIZE must remain larger than LINE_SEARCH_SIZE.
const int TRIM_SIZE = 128000; const int TRIM_SIZE = 128000;
const int LINE_SEARCH_DIST = 500; const int LINE_SEARCH_DIST = 500;

View File

@@ -40,13 +40,14 @@ public:
LLCrashLogger(); LLCrashLogger();
virtual ~LLCrashLogger(); virtual ~LLCrashLogger();
S32 loadCrashBehaviorSetting(); S32 loadCrashBehaviorSetting();
bool readDebugFromXML(LLSD& dest, const std::string& filename ); static S32 sReportID;
bool readDebugFromXML(LLSD& dest, const std::string& filename );
void gatherFiles(); void gatherFiles();
void mergeLogs( LLSD src_sd ); void mergeLogs( LLSD src_sd );
virtual void gatherPlatformSpecificFiles() {} virtual void gatherPlatformSpecificFiles() {}
bool saveCrashBehaviorSetting(S32 crash_behavior); bool saveCrashBehaviorSetting(S32 crash_behavior);
bool sendCrashLog(std::string dump_dir); bool sendCrashLog(std::string dump_dir);
LLSD constructPostData(); LLSD constructPostData();
void setUserText(const std::string& text) { mCrashInfo["UserNotes"] = text; } void setUserText(const std::string& text) { mCrashInfo["UserNotes"] = text; }
S32 getCrashBehavior() { return mCrashBehavior; } S32 getCrashBehavior() { return mCrashBehavior; }

View File

@@ -37,7 +37,7 @@
#include "llfloaterfriends.h" #include "llfloaterfriends.h"
#include "llsdutil_math.h"
#include "llagent.h" #include "llagent.h"
#include "llavataractions.h" #include "llavataractions.h"
#include "llavatarnamecache.h" #include "llavatarnamecache.h"
@@ -426,6 +426,9 @@ BOOL LLPanelFriends::addFriend(const LLUUID& agent_id)
friend_column["value"] = fullname; friend_column["value"] = fullname;
friend_column["font"] = "SANSSERIF"; friend_column["font"] = "SANSSERIF";
friend_column["font-style"] = "NORMAL"; friend_column["font-style"] = "NORMAL";
static const LLCachedControl<LLColor4> sDefaultColor(gColors, "DefaultListText");
static const LLCachedControl<LLColor4> sMutedColor("AscentMutedColor");
friend_column["color"] = ll_sd_from_color4(LLAvatarActions::isBlocked(agent_id) ? sMutedColor : sDefaultColor);
LLSD& online_status_column = element["columns"][LIST_ONLINE_STATUS]; LLSD& online_status_column = element["columns"][LIST_ONLINE_STATUS];
online_status_column["column"] = "icon_online_status"; online_status_column["column"] = "icon_online_status";

View File

@@ -1313,7 +1313,7 @@ void LLFloaterTools::getMediaState()
getChildView("media_tex")->setEnabled(bool_has_media && editable); getChildView("media_tex")->setEnabled(bool_has_media && editable);
getChildView("edit_media")->setEnabled(bool_has_media && LLFloaterMediaSettings::getInstance()->mIdenticalHasMediaInfo && editable ); getChildView("edit_media")->setEnabled(bool_has_media && LLFloaterMediaSettings::getInstance()->mIdenticalHasMediaInfo && editable );
getChildView("delete_media")->setEnabled(bool_has_media && editable ); getChildView("delete_media")->setEnabled(bool_has_media && editable );
getChildView("add_media")->setEnabled(( ! bool_has_media ) && editable ); getChildView("add_media")->setEnabled(editable);
// TODO: display a list of all media on the face - use 'identical' flag // TODO: display a list of all media on the face - use 'identical' flag
} }
else // not all face has media but at least one does. else // not all face has media but at least one does.
@@ -1343,7 +1343,7 @@ void LLFloaterTools::getMediaState()
getChildView("media_tex")->setEnabled(TRUE); getChildView("media_tex")->setEnabled(TRUE);
getChildView("edit_media")->setEnabled(LLFloaterMediaSettings::getInstance()->mIdenticalHasMediaInfo); getChildView("edit_media")->setEnabled(LLFloaterMediaSettings::getInstance()->mIdenticalHasMediaInfo);
getChildView("delete_media")->setEnabled(TRUE); getChildView("delete_media")->setEnabled(TRUE);
getChildView("add_media")->setEnabled(FALSE ); getChildView("add_media")->setEnabled(editable);
} }
media_info->setText(media_title); media_info->setText(media_title);
@@ -1353,6 +1353,8 @@ void LLFloaterTools::getMediaState()
if(mTitleMedia) if(mTitleMedia)
LLFloaterMediaSettings::initValues(mMediaSettings, editable ); LLFloaterMediaSettings::initValues(mMediaSettings, editable );
} }
////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////
// called when a user wants to add media to a prim or prim face // called when a user wants to add media to a prim or prim face
void LLFloaterTools::onClickBtnAddMedia() void LLFloaterTools::onClickBtnAddMedia()

View File

@@ -995,6 +995,11 @@ void LLGroupMgr::processGroupMembersReply(LLMessageSystem* msg, void** data)
static std::string localized_online(LLTrans::getString("group_member_status_online")); static std::string localized_online(LLTrans::getString("group_member_status_online"));
online_status = localized_online; online_status = localized_online;
} }
else if (online_status == "unknown")
{
static std::string localized_unknown(LLTrans::getString("group_member_status_unknown"));
online_status = localized_unknown;
}
else else
{ {
formatDateString(online_status); // reformat for sorting, e.g. 12/25/2008 -> 2008/12/25 formatDateString(online_status); // reformat for sorting, e.g. 12/25/2008 -> 2008/12/25
@@ -2058,6 +2063,8 @@ void LLGroupMgr::processCapGroupMembersRequest(const LLSD& content)
online_status = member_info["last_login"].asString(); online_status = member_info["last_login"].asString();
if (online_status == "Online") if (online_status == "Online")
online_status = LLTrans::getString("group_member_status_online"); online_status = LLTrans::getString("group_member_status_online");
else if (online_status == "unknown")
online_status = LLTrans::getString("group_member_status_unknown");
else else
formatDateString(online_status); formatDateString(online_status);
} }

View File

@@ -867,7 +867,7 @@ BOOL LLFloaterIMPanel::handleDragAndDrop(S32 x, S32 y, MASK mask, BOOL drop,
std::string& tooltip_msg) std::string& tooltip_msg)
{ {
if (mDialog == IM_NOTHING_SPECIAL) if (mSessionType == P2P_SESSION)
{ {
LLToolDragAndDrop::handleGiveDragAndDrop(mOtherParticipantUUID, mSessionUUID, drop, LLToolDragAndDrop::handleGiveDragAndDrop(mOtherParticipantUUID, mSessionUUID, drop,
cargo_type, cargo_data, accept); cargo_type, cargo_data, accept);
@@ -898,28 +898,23 @@ BOOL LLFloaterIMPanel::handleDragAndDrop(S32 x, S32 y, MASK mask, BOOL drop,
BOOL LLFloaterIMPanel::dropCallingCard(LLInventoryItem* item, BOOL drop) BOOL LLFloaterIMPanel::dropCallingCard(LLInventoryItem* item, BOOL drop)
{ {
BOOL rv = isInviteAllowed(); if (item && item->getCreatorUUID().notNull())
if(rv && item && item->getCreatorUUID().notNull())
{ {
if(drop) if (drop)
{ {
LLDynamicArray<LLUUID> ids; LLDynamicArray<LLUUID> ids;
ids.put(item->getCreatorUUID()); ids.put(item->getCreatorUUID());
inviteToSession(ids); inviteToSession(ids);
} }
return true;
} }
else // return false if creator uuid is null.
{ return false;
// set to false if creator uuid is null.
rv = FALSE;
}
return rv;
} }
BOOL LLFloaterIMPanel::dropCategory(LLInventoryCategory* category, BOOL drop) BOOL LLFloaterIMPanel::dropCategory(LLInventoryCategory* category, BOOL drop)
{ {
BOOL rv = isInviteAllowed(); if (category)
if(rv && category)
{ {
LLInventoryModel::cat_array_t cats; LLInventoryModel::cat_array_t cats;
LLInventoryModel::item_array_t items; LLInventoryModel::item_array_t items;
@@ -932,7 +927,7 @@ BOOL LLFloaterIMPanel::dropCategory(LLInventoryCategory* category, BOOL drop)
S32 count = items.count(); S32 count = items.count();
if(count == 0) if(count == 0)
{ {
rv = FALSE; return false;
} }
else if(drop) else if(drop)
{ {
@@ -944,14 +939,12 @@ BOOL LLFloaterIMPanel::dropCategory(LLInventoryCategory* category, BOOL drop)
inviteToSession(ids); inviteToSession(ids);
} }
} }
return rv; return true;
} }
bool LLFloaterIMPanel::isInviteAllowed() const bool LLFloaterIMPanel::isInviteAllowed() const
{ {
return mSessionType == ADHOC_SESSION;
return ( (IM_SESSION_CONFERENCE_START == mDialog)
|| (IM_SESSION_INVITE == mDialog) );
} }
void LLFloaterIMPanel::removeDynamics(LLComboBox* flyout) void LLFloaterIMPanel::removeDynamics(LLComboBox* flyout)

View File

@@ -279,6 +279,9 @@ void LLMediaRemoteCtrl::enableMediaButtons()
LLChat chat; LLChat chat;
chat.mText = getString("Now_playing") + " " + info_text; chat.mText = getString("Now_playing") + " " + info_text;
chat.mSourceType = CHAT_SOURCE_SYSTEM; chat.mSourceType = CHAT_SOURCE_SYSTEM;
// Lie to RLVa so it won't filter this
chat.mRlvLocFiltered = true;
chat.mRlvNamesFiltered = true;
LLFloaterChat::addChat(chat); LLFloaterChat::addChat(chat);
} }
} }

View File

@@ -9475,7 +9475,6 @@ class ListStartIM : public view_listener_t
} }
}; };
/* Singu TODO: Figure out why this wouldn't work
class ListAbuseReport : public view_listener_t class ListAbuseReport : public view_listener_t
{ {
bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata) bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
@@ -9484,7 +9483,6 @@ class ListAbuseReport : public view_listener_t
return true; return true;
} }
}; };
*/
// Create the args for administrative notifications used in lists, tossing the selected names into it. // Create the args for administrative notifications used in lists, tossing the selected names into it.
LLSD create_args(const uuid_vec_t& ids, const std::string& token) LLSD create_args(const uuid_vec_t& ids, const std::string& token)
@@ -9899,7 +9897,7 @@ void initialize_menus()
addMenu(new ListStartCall(), "List.StartCall"); addMenu(new ListStartCall(), "List.StartCall");
addMenu(new ListStartConference(), "List.StartConference"); addMenu(new ListStartConference(), "List.StartConference");
addMenu(new ListStartIM(), "List.StartIM"); addMenu(new ListStartIM(), "List.StartIM");
//addMenu(new ListAbuseReport(), "List.AbuseReport"); addMenu(new ListAbuseReport(), "List.AbuseReport");
addMenu(new ListEject(), "List.ParcelEject"); addMenu(new ListEject(), "List.ParcelEject");
addMenu(new ListFreeze(), "List.Freeze"); addMenu(new ListFreeze(), "List.Freeze");
addMenu(new ListEstateBan(), "List.EstateBan"); addMenu(new ListEstateBan(), "List.EstateBan");

View File

@@ -4018,7 +4018,7 @@ void process_chat_from_simulator(LLMessageSystem *msg, void **user_data)
std::string prefix = mesg.substr(0, 4); std::string prefix = mesg.substr(0, 4);
if (prefix == "/me " || prefix == "/me'") if (prefix == "/me " || prefix == "/me'")
{ {
chat.mText = from_name; chat.mText = chat.mFromName;
mesg = mesg.substr(3); mesg = mesg.substr(3);
ircstyle = TRUE; ircstyle = TRUE;
// This block was moved up to allow bubbles with italicized chat // This block was moved up to allow bubbles with italicized chat
@@ -4191,7 +4191,7 @@ void process_chat_from_simulator(LLMessageSystem *msg, void **user_data)
break; break;
} }
chat.mText = from_name + verb + mesg; chat.mText = chat.mFromName + verb + mesg;
} }
if (chatter) if (chatter)

View File

@@ -54,14 +54,14 @@
</menu_item_call> </menu_item_call>
<menu_item_separator/> <menu_item_separator/>
<menu_item_call label="Mute/Unmute" name="Mute/Unmute"> <menu_item_call label="Mute/Unmute" name="Mute/Unmute">
<on_click function="List.Mute"/> <on_click function="List.ToggleMute"/>
<on_enable function="List.EnableMute"/> <on_enable function="List.EnableMute"/>
<on_visible function="List.EnableAnySelected"/> <on_visible function="List.EnableAnySelected"/>
</menu_item_call> </menu_item_call>
<!--menu_item_call label="Report Abuse" name="Report Abuse"> <menu_item_call label="Report Abuse" name="Report Abuse">
<on_click function="List.ReportAbuse"/> <on_click function="List.AbuseReport"/>
<on_visible function="List.EnableSingleSelected"/> <on_visible function="List.EnableSingleSelected"/>
</menu_item_call--> </menu_item_call>
<menu_item_call label="Copy Key" name="Copy Key"> <menu_item_call label="Copy Key" name="Copy Key">
<on_click function="List.CopyUUIDs"/> <on_click function="List.CopyUUIDs"/>
<on_enable function="List.EnableAnySelected"/> <on_enable function="List.EnableAnySelected"/>

View File

@@ -129,14 +129,14 @@
</menu> </menu>
<menu label="Moderation" name="Moderation" create_jump_keys="true"> <menu label="Moderation" name="Moderation" create_jump_keys="true">
<menu_item_call label="Mute/Unmute" name="Mute/Unmute"> <menu_item_call label="Mute/Unmute" name="Mute/Unmute">
<on_click function="List.Mute"/> <on_click function="List.ToggleMute"/>
<on_enable function="List.EnableMute"/> <on_enable function="List.EnableMute"/>
<on_visible function="List.EnableAnySelected"/> <on_visible function="List.EnableAnySelected"/>
</menu_item_call> </menu_item_call>
<!--menu_item_call label="Report Abuse" name="Report Abuse"> <menu_item_call label="Report Abuse" name="Report Abuse">
<on_click function="List.ReportAbuse"/> <on_click function="List.AbuseReport"/>
<on_visible function="List.EnableSingleSelected"/> <on_visible function="List.EnableSingleSelected"/>
</menu_item_call--> </menu_item_call>
<menu_item_separator/> <menu_item_separator/>
<menu_item_call label="Freeze" name="Freeze"> <menu_item_call label="Freeze" name="Freeze">
<on_click function="List.Freeze"/> <on_click function="List.Freeze"/>

View File

@@ -9742,4 +9742,11 @@ Do you wish to export anyway?
Object successfully exported to: [FILENAME] Object successfully exported to: [FILENAME]
</notification> </notification>
<notification
icon="notifytip.tga"
name="CrashReportSent"
type="notifytip">
Thank you for submitting the crash report! Report ID is [REPORT_ID]
</notification>
</notifications> </notifications>

View File

@@ -4244,6 +4244,7 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
<string name="group_role_officers">Officers</string> <string name="group_role_officers">Officers</string>
<string name="group_role_owners">Owners</string> <string name="group_role_owners">Owners</string>
<string name="group_member_status_online">Online</string> <string name="group_member_status_online">Online</string>
<string name="group_member_status_unknown">Unknown</string>
<string name="uploading_abuse_report">Uploading... <string name="uploading_abuse_report">Uploading...