summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorPaul ProductEngine <pguslisty@productengine.com>2012-09-18 18:07:16 +0300
committerPaul ProductEngine <pguslisty@productengine.com>2012-09-18 18:07:16 +0300
commit3fb222e939de7ef71630c5754d964fb81e08fce1 (patch)
tree4ffd8c154190c08fcea53ba8e5fc73e806c9de84 /indra
parenta3607a8d8c86b2c25bfa0abda1b0fc9b00f2c099 (diff)
CHUI-348 FIXED (Voice call icon still shows in conversation log)
- Removed code responsible for showing voice icon
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llconversationlog.cpp18
-rw-r--r--indra/newview/llconversationlog.h5
-rw-r--r--indra/newview/llconversationloglistitem.cpp12
3 files changed, 9 insertions, 26 deletions
diff --git a/indra/newview/llconversationlog.cpp b/indra/newview/llconversationlog.cpp
index 44bee70427..7a5a476efb 100644
--- a/indra/newview/llconversationlog.cpp
+++ b/indra/newview/llconversationlog.cpp
@@ -36,8 +36,7 @@ struct Conversation_params
{
Conversation_params(time_t time)
: mTime(time),
- mTimestamp(LLConversation::createTimestamp(time)),
- mIsVoice(false)
+ mTimestamp(LLConversation::createTimestamp(time))
{}
time_t mTime;
@@ -47,7 +46,6 @@ struct Conversation_params
std::string mHistoryFileName;
LLUUID mSessionID;
LLUUID mParticipantID;
- bool mIsVoice;
bool mHasOfflineIMs;
};
@@ -63,7 +61,6 @@ LLConversation::LLConversation(const Conversation_params& params)
mHistoryFileName(params.mHistoryFileName),
mSessionID(params.mSessionID),
mParticipantID(params.mParticipantID),
- mIsVoice(params.mIsVoice),
mHasOfflineIMs(params.mHasOfflineIMs)
{
setListenIMFloaterOpened();
@@ -77,7 +74,6 @@ LLConversation::LLConversation(const LLIMModel::LLIMSession& session)
mHistoryFileName(session.mHistoryFileName),
mSessionID(session.isOutgoingAdHoc() ? session.generateOutgouigAdHocHash() : session.mSessionID),
mParticipantID(session.mOtherParticipantID),
- mIsVoice(session.mStartedAsIMCall),
mHasOfflineIMs(session.mHasOfflineMessage)
{
setListenIMFloaterOpened();
@@ -92,7 +88,6 @@ LLConversation::LLConversation(const LLConversation& conversation)
mHistoryFileName = conversation.getHistoryFileName();
mSessionID = conversation.getSessionID();
mParticipantID = conversation.getParticipantID();
- mIsVoice = conversation.isVoice();
mHasOfflineIMs = conversation.hasOfflineMessages();
setListenIMFloaterOpened();
@@ -147,12 +142,11 @@ void LLConversation::setListenIMFloaterOpened()
{
LLIMFloater* floater = LLIMFloater::findInstance(mSessionID);
- bool has_offline_ims = !mIsVoice && mHasOfflineIMs;
bool offline_ims_visible = LLIMFloater::isVisible(floater) && floater->hasFocus();
// we don't need to listen for im floater with this conversation is opened
// if floater is already opened or this conversation doesn't have unread offline messages
- if (has_offline_ims && !offline_ims_visible)
+ if (mHasOfflineIMs && !offline_ims_visible)
{
mIMFloaterShowedConnection = LLIMFloater::setIMFloaterShowedCallback(boost::bind(&LLConversation::onIMFloaterShown, this, _1));
}
@@ -393,7 +387,7 @@ bool LLConversationLog::saveToFile(const std::string& filename)
fprintf(fp, "[%d] %d %d %d %s| %s %s %s|\n",
(S32)conv_it->getTime(),
(S32)conv_it->getConversationType(),
- (S32)conv_it->isVoice(),
+ (S32)0,
(S32)conv_it->hasOfflineMessages(),
conv_it->getConversationName().c_str(),
participant_id.c_str(),
@@ -423,10 +417,11 @@ bool LLConversationLog::loadFromFile(const std::string& filename)
char part_id_buffer[MAX_STRING];
char conv_id_buffer[MAX_STRING];
char history_file_name[MAX_STRING];
- int is_voice;
int has_offline_ims;
int stype;
S32 time;
+ // before CHUI-348 it was a flag of conversation voice state
+ int prereserved_unused;
while (!feof(fp) && fgets(buffer, MAX_STRING, fp))
{
@@ -437,7 +432,7 @@ bool LLConversationLog::loadFromFile(const std::string& filename)
sscanf(buffer, "[%d] %d %d %d %[^|]| %s %s %[^|]|",
&time,
&stype,
- &is_voice,
+ &prereserved_unused,
&has_offline_ims,
conv_name_buffer,
part_id_buffer,
@@ -446,7 +441,6 @@ bool LLConversationLog::loadFromFile(const std::string& filename)
Conversation_params params(time);
params.mConversationType = (SessionType)stype;
- params.mIsVoice = is_voice;
params.mHasOfflineIMs = has_offline_ims;
params.mConversationName = std::string(conv_name_buffer);
params.mParticipantID = LLUUID(part_id_buffer);
diff --git a/indra/newview/llconversationlog.h b/indra/newview/llconversationlog.h
index 6fff7d6772..373406aa6f 100644
--- a/indra/newview/llconversationlog.h
+++ b/indra/newview/llconversationlog.h
@@ -56,11 +56,9 @@ public:
const LLUUID& getParticipantID() const { return mParticipantID; }
const std::string& getTimestamp() const { return mTimestamp; }
const time_t& getTime() const { return mTime; }
- bool isVoice() const { return mIsVoice; }
bool hasOfflineMessages() const { return mHasOfflineIMs; }
- void setIsVoice(bool is_voice);
- void setConverstionName(std::string conv_name) { mConversationName = conv_name; }
+ void setConverstionName(std::string conv_name) { mConversationName = conv_name; }
bool isOlderThan(U32 days) const;
@@ -95,7 +93,6 @@ private:
std::string mHistoryFileName;
LLUUID mSessionID;
LLUUID mParticipantID;
- bool mIsVoice;
bool mHasOfflineIMs;
std::string mTimestamp; // last interaction time in form of: mm/dd/yyyy hh:mm
};
diff --git a/indra/newview/llconversationloglistitem.cpp b/indra/newview/llconversationloglistitem.cpp
index fac6130371..b4ae5f19da 100644
--- a/indra/newview/llconversationloglistitem.cpp
+++ b/indra/newview/llconversationloglistitem.cpp
@@ -49,10 +49,9 @@ LLConversationLogListItem::LLConversationLogListItem(const LLConversation* conve
LLIMFloater* floater = LLIMFloater::findInstance(mConversation->getSessionID());
- bool has_offline_ims = !mConversation->isVoice() && mConversation->hasOfflineMessages();
bool ims_are_read = LLIMFloater::isVisible(floater) && floater->hasFocus();
- if (has_offline_ims && !ims_are_read)
+ if (mConversation->hasOfflineMessages() && !ims_are_read)
{
mIMFloaterShowedConnection = LLIMFloater::setIMFloaterShowedCallback(boost::bind(&LLConversationLogListItem::onIMFloaterShown, this, _1));
}
@@ -104,16 +103,9 @@ void LLConversationLogListItem::initIcons()
break;
}
- if (mConversation->isVoice())
+ if (mConversation->hasOfflineMessages())
{
- getChild<LLIconCtrl>("voice_session_icon")->setVisible(TRUE);
- }
- else
- {
- if (mConversation->hasOfflineMessages())
- {
getChild<LLIconCtrl>("unread_ims_icon")->setVisible(TRUE);
- }
}
}