diff options
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/llchatitemscontainerctrl.cpp | 26 | ||||
-rw-r--r-- | indra/newview/llchatitemscontainerctrl.h | 1 | ||||
-rw-r--r-- | indra/newview/llimview.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llvoicechannel.cpp | 21 | ||||
-rw-r--r-- | indra/newview/llvoiceclient.cpp | 10 | ||||
-rw-r--r-- | indra/newview/llvoiceclient.h | 1 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/panel_instant_message.xml | 3 |
7 files changed, 56 insertions, 8 deletions
diff --git a/indra/newview/llchatitemscontainerctrl.cpp b/indra/newview/llchatitemscontainerctrl.cpp index 92df281307..60a37ac4af 100644 --- a/indra/newview/llchatitemscontainerctrl.cpp +++ b/indra/newview/llchatitemscontainerctrl.cpp @@ -253,10 +253,32 @@ void LLNearbyChatToastPanel::onMouseEnter (S32 x, S32 y, MASK mask) BOOL LLNearbyChatToastPanel::handleMouseDown (S32 x, S32 y, MASK mask) { + return LLPanel::handleMouseDown(x,y,mask); +} + +BOOL LLNearbyChatToastPanel::handleMouseUp (S32 x, S32 y, MASK mask) +{ if(mSourceType != CHAT_SOURCE_AGENT) - return LLPanel::handleMouseDown(x,y,mask); + return LLPanel::handleMouseUp(x,y,mask); + + LLChatMsgBox* text_box = getChild<LLChatMsgBox>("msg_text", false); + S32 local_x = x - text_box->getRect().mLeft; + S32 local_y = y - text_box->getRect().mBottom; + + //if text_box process mouse up (ussually this is click on url) - we didn't show nearby_chat. + if (text_box->pointInView(local_x, local_y) ) + { + if (text_box->handleMouseUp(local_x,local_y,mask) == TRUE) + return TRUE; + else + { + LLFloaterReg::showInstance("nearby_chat",LLSD()); + return FALSE; + } + } + LLFloaterReg::showInstance("nearby_chat",LLSD()); - return LLPanel::handleMouseDown(x,y,mask); + return LLPanel::handleMouseUp(x,y,mask); } void LLNearbyChatToastPanel::setHeaderVisibility(EShowItemHeader e) diff --git a/indra/newview/llchatitemscontainerctrl.h b/indra/newview/llchatitemscontainerctrl.h index 0a85c52401..f4b8655054 100644 --- a/indra/newview/llchatitemscontainerctrl.h +++ b/indra/newview/llchatitemscontainerctrl.h @@ -68,6 +68,7 @@ public: void onMouseLeave (S32 x, S32 y, MASK mask); void onMouseEnter (S32 x, S32 y, MASK mask); BOOL handleMouseDown (S32 x, S32 y, MASK mask); + BOOL handleMouseUp (S32 x, S32 y, MASK mask); virtual BOOL postBuild(); diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp index 40227539d0..b9af49a50d 100644 --- a/indra/newview/llimview.cpp +++ b/indra/newview/llimview.cpp @@ -781,7 +781,7 @@ LLIMSpeakerMgr* LLIMModel::getSpeakerManager( const LLUUID& session_id ) const LLIMSession* session = findIMSession(session_id); if (!session) { - llwarns << "session " << session_id << "does not exist " << llendl; + llwarns << "session " << session_id << " does not exist " << llendl; return NULL; } diff --git a/indra/newview/llvoicechannel.cpp b/indra/newview/llvoicechannel.cpp index 18cdd23ed9..917d69fe16 100644 --- a/indra/newview/llvoicechannel.cpp +++ b/indra/newview/llvoicechannel.cpp @@ -278,10 +278,14 @@ void LLVoiceChannel::deactivate() if (callStarted()) { setState(STATE_HUNG_UP); - // mute the microphone if required when returning to the proximal channel - if (gSavedSettings.getBOOL("AutoDisengageMic") && sCurrentVoiceChannel == this) + + //Default mic is OFF when leaving voice calls + if (gSavedSettings.getBOOL("AutoDisengageMic") && + sCurrentVoiceChannel == this && + gVoiceClient->getUserPTTState()) { gSavedSettings.setBOOL("PTTCurrentlyEnabled", true); + gVoiceClient->inputUserControlState(true); } } @@ -498,6 +502,13 @@ void LLVoiceChannelGroup::activate() LLRecentPeople::instance().add(buddy_id); } #endif + + //Mic default state is OFF on initiating/joining Ad-Hoc/Group calls + if (gVoiceClient->getUserPTTState() && gVoiceClient->getPTTIsToggle()) + { + gVoiceClient->inputUserControlState(true); + } + } } @@ -811,6 +822,12 @@ void LLVoiceChannelP2P::activate() // Add the party to the list of people with which we've recently interacted. LLRecentPeople::instance().add(mOtherUserID); + + //Default mic is ON on initiating/joining P2P calls + if (!gVoiceClient->getUserPTTState() && gVoiceClient->getPTTIsToggle()) + { + gVoiceClient->inputUserControlState(true); + } } } diff --git a/indra/newview/llvoiceclient.cpp b/indra/newview/llvoiceclient.cpp index c2d26a1971..423c46e14c 100644 --- a/indra/newview/llvoiceclient.cpp +++ b/indra/newview/llvoiceclient.cpp @@ -4445,7 +4445,7 @@ void LLVoiceClient::participantUpdatedEvent( participant->mVolume = volume; - // *HACH: mantipov: added while working on EXT-3544 + // *HACK: mantipov: added while working on EXT-3544 /* Sometimes LLVoiceClient::participantUpdatedEvent callback is called BEFORE LLViewerChatterBoxSessionAgentListUpdates::post() sometimes AFTER. @@ -4462,7 +4462,9 @@ void LLVoiceClient::participantUpdatedEvent( in LLCallFloater::draw() */ LLVoiceChannel* voice_cnl = LLVoiceChannel::getCurrentVoiceChannel(); - if (voice_cnl) + + // ignore session ID of local chat + if (voice_cnl && voice_cnl->getSessionID().notNull()) { LLSpeakerMgr* speaker_manager = LLIMModel::getInstance()->getSpeakerManager(voice_cnl->getSessionID()); if (speaker_manager) @@ -5883,6 +5885,10 @@ void LLVoiceClient::setPTTIsToggle(bool PTTIsToggle) mPTTIsToggle = PTTIsToggle; } +bool LLVoiceClient::getPTTIsToggle() +{ + return mPTTIsToggle; +} void LLVoiceClient::setPTTKey(std::string &key) { diff --git a/indra/newview/llvoiceclient.h b/indra/newview/llvoiceclient.h index 347fae6156..724179847d 100644 --- a/indra/newview/llvoiceclient.h +++ b/indra/newview/llvoiceclient.h @@ -193,6 +193,7 @@ static void updatePosition(void); static bool voiceEnabled(); void setUsePTT(bool usePTT); void setPTTIsToggle(bool PTTIsToggle); + bool getPTTIsToggle(); void setPTTKey(std::string &key); void setEarLocation(S32 loc); void setVoiceVolume(F32 volume); diff --git a/indra/newview/skins/default/xui/en/panel_instant_message.xml b/indra/newview/skins/default/xui/en/panel_instant_message.xml index ccd754ac5e..7204e57479 100644 --- a/indra/newview/skins/default/xui/en/panel_instant_message.xml +++ b/indra/newview/skins/default/xui/en/panel_instant_message.xml @@ -21,6 +21,7 @@ label="im_header" layout="topleft" left="5" + mouse_opaque="false" name="im_header" top="5" width="295"> @@ -30,7 +31,7 @@ image_name="Generic_Person" layout="topleft" left="3" - mouse_opaque="true" + mouse_opaque="false" name="avatar_icon" top="3" width="18" /> |