From 5b7f40df4e2125cee36fdeed53a10e6ebd624929 Mon Sep 17 00:00:00 2001 From: Eugene Mutavchi Date: Mon, 2 Nov 2009 19:18:24 +0200 Subject: Implemented normal sub-task EXT-1909 (Update IM Control Panels buttons according to the spec) - added 'Open Voice Controls' button. Note Teleport and Pay buttons will be implemented in EXT-957 --HG-- branch : product-engine --- indra/newview/llpanelimcontrolpanel.cpp | 12 ++++++++++-- indra/newview/llpanelimcontrolpanel.h | 1 + .../skins/default/xui/en/floater_im_session.xml | 10 +++++----- .../default/xui/en/panel_adhoc_control_panel.xml | 11 +++++++++-- .../default/xui/en/panel_group_control_panel.xml | 15 +++++++++++---- .../default/xui/en/panel_im_control_panel.xml | 22 +++++++++++++++------- 6 files changed, 51 insertions(+), 20 deletions(-) (limited to 'indra') diff --git a/indra/newview/llpanelimcontrolpanel.cpp b/indra/newview/llpanelimcontrolpanel.cpp index f9eeaf1e9e..b54975b76b 100644 --- a/indra/newview/llpanelimcontrolpanel.cpp +++ b/indra/newview/llpanelimcontrolpanel.cpp @@ -54,10 +54,16 @@ void LLPanelChatControlPanel::onEndCallButtonClicked() gIMMgr->endCall(mSessionId); } +void LLPanelChatControlPanel::onOpenVoiceControlsClicked() +{ + // TODO: implement Voice Control Panel opening +} + BOOL LLPanelChatControlPanel::postBuild() { childSetAction("call_btn", boost::bind(&LLPanelChatControlPanel::onCallButtonClicked, this)); childSetAction("end_call_btn", boost::bind(&LLPanelChatControlPanel::onEndCallButtonClicked, this)); + childSetAction("voice_ctrls_btn", boost::bind(&LLPanelChatControlPanel::onOpenVoiceControlsClicked, this)); return TRUE; } @@ -73,8 +79,10 @@ void LLPanelChatControlPanel::draw() LLVoiceChannel* voice_channel = session->mVoiceChannel; if (voice_channel && voice_enabled) { - childSetVisible("end_call_btn", voice_channel->getState() >= LLVoiceChannel::STATE_CALL_STARTED); - childSetVisible("call_btn", voice_channel->getState() < LLVoiceChannel::STATE_CALL_STARTED); + bool is_call_started = ( voice_channel->getState() >= LLVoiceChannel::STATE_CALL_STARTED ); + childSetVisible("end_call_btn", is_call_started); + childSetVisible("voice_ctrls_btn", is_call_started); + childSetVisible("call_btn", ! is_call_started); } bool session_initialized = session->mSessionInitialized; diff --git a/indra/newview/llpanelimcontrolpanel.h b/indra/newview/llpanelimcontrolpanel.h index 220b7b14ba..d25f33935a 100644 --- a/indra/newview/llpanelimcontrolpanel.h +++ b/indra/newview/llpanelimcontrolpanel.h @@ -50,6 +50,7 @@ public: void onCallButtonClicked(); void onEndCallButtonClicked(); + void onOpenVoiceControlsClicked(); virtual void setSessionId(const LLUUID& session_id) { mSessionId = session_id; } 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 d9c3ff77d9..26d2f4e497 100644 --- a/indra/newview/skins/default/xui/en/floater_im_session.xml +++ b/indra/newview/skins/default/xui/en/floater_im_session.xml @@ -3,7 +3,7 @@ legacy_header_height="18" background_visible="true" follows="left|top|right|bottom" - height="250" + height="270" layout="topleft" left="0" name="panel_im" @@ -17,7 +17,7 @@ min_width="200" min_height="150"> -