Adjust chat log opening functions to use LLLogChat functions to determine log file

This eliminates the possibility of the history button not opening the log file, which has been reported in the past.
This also corrects cases where log files named with date would not be opened.
This commit is contained in:
Inusaito Sayori
2013-08-15 21:52:40 -04:00
parent 1e64d41bdc
commit a5287ee975
2 changed files with 3 additions and 7 deletions

View File

@@ -1079,12 +1079,10 @@ void LLFloaterIMPanel::onClickHistory()
{
if (mOtherParticipantUUID.notNull())
{
char command[256];
// [Ansariel: Display name support]
//std::string fullname(gDirUtilp->getScrubbedFileName(getTitle()));
std::string fullname(gDirUtilp->getScrubbedFileName(mSessionLabel));
//std::string command("\"" + LLLogChat::makeLogFileName(getTitle()) + "\"");
std::string command("\"" + LLLogChat::makeLogFileName(mSessionLabel) + "\"");
// [/Ansariel: Display name support]
sprintf(command, "\"%s%s%s.txt\"", gDirUtilp->getPerAccountChatLogsDir().c_str(), gDirUtilp->getDirDelimiter().c_str(), fullname.c_str());
gViewerWindow->getWindow()->ShellEx(command);
llinfos << command << llendl;