Skip to content
Snippets Groups Projects
Commit 5b7f40df authored by Eugene Mutavchi's avatar Eugene Mutavchi
Browse files

Implemented normal sub-task EXT-1909 (Update IM Control Panels buttons...

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
parent 3dc509be
No related branches found
No related tags found
No related merge requests found
...@@ -54,10 +54,16 @@ void LLPanelChatControlPanel::onEndCallButtonClicked() ...@@ -54,10 +54,16 @@ void LLPanelChatControlPanel::onEndCallButtonClicked()
gIMMgr->endCall(mSessionId); gIMMgr->endCall(mSessionId);
} }
void LLPanelChatControlPanel::onOpenVoiceControlsClicked()
{
// TODO: implement Voice Control Panel opening
}
BOOL LLPanelChatControlPanel::postBuild() BOOL LLPanelChatControlPanel::postBuild()
{ {
childSetAction("call_btn", boost::bind(&LLPanelChatControlPanel::onCallButtonClicked, this)); childSetAction("call_btn", boost::bind(&LLPanelChatControlPanel::onCallButtonClicked, this));
childSetAction("end_call_btn", boost::bind(&LLPanelChatControlPanel::onEndCallButtonClicked, this)); childSetAction("end_call_btn", boost::bind(&LLPanelChatControlPanel::onEndCallButtonClicked, this));
childSetAction("voice_ctrls_btn", boost::bind(&LLPanelChatControlPanel::onOpenVoiceControlsClicked, this));
return TRUE; return TRUE;
} }
...@@ -73,8 +79,10 @@ void LLPanelChatControlPanel::draw() ...@@ -73,8 +79,10 @@ void LLPanelChatControlPanel::draw()
LLVoiceChannel* voice_channel = session->mVoiceChannel; LLVoiceChannel* voice_channel = session->mVoiceChannel;
if (voice_channel && voice_enabled) if (voice_channel && voice_enabled)
{ {
childSetVisible("end_call_btn", voice_channel->getState() >= LLVoiceChannel::STATE_CALL_STARTED); bool is_call_started = ( voice_channel->getState() >= LLVoiceChannel::STATE_CALL_STARTED );
childSetVisible("call_btn", 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; bool session_initialized = session->mSessionInitialized;
......
...@@ -50,6 +50,7 @@ class LLPanelChatControlPanel : public LLPanel ...@@ -50,6 +50,7 @@ class LLPanelChatControlPanel : public LLPanel
void onCallButtonClicked(); void onCallButtonClicked();
void onEndCallButtonClicked(); void onEndCallButtonClicked();
void onOpenVoiceControlsClicked();
virtual void setSessionId(const LLUUID& session_id) { mSessionId = session_id; } virtual void setSessionId(const LLUUID& session_id) { mSessionId = session_id; }
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
legacy_header_height="18" legacy_header_height="18"
background_visible="true" background_visible="true"
follows="left|top|right|bottom" follows="left|top|right|bottom"
height="250" height="270"
layout="topleft" layout="topleft"
left="0" left="0"
name="panel_im" name="panel_im"
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
min_width="200" min_width="200"
min_height="150"> min_height="150">
<layout_stack follows="left|top|right|bottom" <layout_stack follows="left|top|right|bottom"
height="235" height="255"
width="365" width="365"
layout="topleft" layout="topleft"
orientation="horizontal" orientation="horizontal"
...@@ -29,11 +29,11 @@ ...@@ -29,11 +29,11 @@
layout="topleft" layout="topleft"
top_delta="-3" top_delta="-3"
width="146" width="146"
height="225" height="255"
follows="left" follows="left"
label="IM Control Panel" label="IM Control Panel"
user_resize="false" /> user_resize="false" />
<layout_panel height="235" <layout_panel height="255"
width="200" width="200"
left_delta="146" left_delta="146"
top="0" top="0"
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
length="1" length="1"
follows="left|top|right|bottom" follows="left|top|right|bottom"
font="SansSerif" font="SansSerif"
height="185" height="205"
layout="topleft" layout="topleft"
name="chat_history" name="chat_history"
parse_highlights="true" parse_highlights="true"
......
...@@ -20,12 +20,19 @@ ...@@ -20,12 +20,19 @@
<button <button
name="call_btn" name="call_btn"
label="Call" label="Call"
width="90" width="125"
height="20" /> height="20" />
<button <button
name="end_call_btn" name="end_call_btn"
label="End Call" label="End Call"
width="90" width="125"
height="20" height="20"
visible="false"/> visible="false"/>
<button
enabled="false"
name="voice_ctrls_btn"
label="Open Voice Controls"
width="125"
height="20"
visible="false"/>
</panel> </panel>
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<panel <panel
name="panel_im_control_panel" name="panel_im_control_panel"
width="146" width="146"
height="215" height="238"
border="false"> border="false">
<avatar_list <avatar_list
color="DkGray2" color="DkGray2"
...@@ -21,17 +21,24 @@ ...@@ -21,17 +21,24 @@
name="group_info_btn" name="group_info_btn"
label="Group Info" label="Group Info"
left_delta="3" left_delta="3"
width="90" width="125"
height="20" /> height="20" />
<button <button
name="call_btn" name="call_btn"
label="Call" label="Call"
width="90" width="125"
height="20" /> height="20" />
<button <button
name="end_call_btn" name="end_call_btn"
label="End Call" label="End Call"
width="90" width="125"
height="20" height="20"
visible="false"/> visible="false"/>
<button
enabled="false"
name="voice_ctrls_btn"
label="Open Voice Controls"
width="125"
height="20"
visible="false"/>
</panel> </panel>
<?xml version="1.0" encoding="utf-8" standalone="yes" ?> <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<panel name="panel_im_control_panel" <panel name="panel_im_control_panel"
width="96" width="125"
height="225" height="248"
border="false"> border="false">
<avatar_icon name="avatar_icon" <avatar_icon name="avatar_icon"
...@@ -11,17 +11,17 @@ ...@@ -11,17 +11,17 @@
<button name="view_profile_btn" <button name="view_profile_btn"
label="View Profile" label="View Profile"
left_delta="3" left_delta="3"
width="90" width="125"
height="20" /> height="20" />
<button name="add_friend_btn" <button name="add_friend_btn"
label="Add Friend" label="Add Friend"
width="90" width="125"
height="20" /> height="20" />
<button name="call_btn" <button name="call_btn"
label="Call" label="Call"
width="90" width="125"
height="20" /> height="20" />
<button <button
...@@ -29,11 +29,19 @@ ...@@ -29,11 +29,19 @@
label="End Call" label="End Call"
name="end_call_btn" name="end_call_btn"
visible="false" visible="false"
width="90" /> width="125" />
<button
enabled="false"
name="voice_ctrls_btn"
label="Open Voice Controls"
width="125"
height="20"
visible="false"/>
<button name="share_btn" <button name="share_btn"
label="Share" label="Share"
width="90" width="125"
height="20" /> height="20" />
</panel> </panel>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment