summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/app_settings/commands.xml4
-rwxr-xr-xindra/newview/llagent.cpp27
-rw-r--r--indra/newview/llagent.h4
-rw-r--r--indra/newview/lltoolbarview.cpp7
-rw-r--r--indra/newview/skins/default/textures/toolbar_icons/caret_bottom.pngbin139 -> 169 bytes
-rw-r--r--indra/newview/skins/default/textures/toolbar_icons/caret_left.pngbin893 -> 913 bytes
-rw-r--r--indra/newview/skins/default/textures/toolbar_icons/caret_right.pngbin892 -> 911 bytes
-rw-r--r--indra/newview/skins/default/xui/en/panel_toolbar_view.xml13
8 files changed, 22 insertions, 33 deletions
diff --git a/indra/newview/app_settings/commands.xml b/indra/newview/app_settings/commands.xml
index 296d992b34..3625ce5088 100644
--- a/indra/newview/app_settings/commands.xml
+++ b/indra/newview/app_settings/commands.xml
@@ -215,9 +215,9 @@
icon="Command_Speak_Icon"
label_ref="Command_Speak_Label"
tooltip_ref="Command_Speak_Tooltip"
- execute_function="Agent.ToggleMicrophone"
+ execute_function="Agent.PressMicrophone"
execute_parameters="speak"
- execute_stop_function=""
+ execute_stop_function="Agent.ReleaseMicrophone"
execute_stop_parameters="speak"
is_enabled_function="Agent.IsActionAllowed"
is_enabled_parameters="speak"
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp
index 8303a5942d..31a73c8c31 100755
--- a/indra/newview/llagent.cpp
+++ b/indra/newview/llagent.cpp
@@ -188,28 +188,23 @@ bool LLAgent::isActionAllowed(const LLSD& sdname)
}
// static
-void LLAgent::toggleMicrophone(const LLSD& name)
+void LLAgent::pressMicrophone(const LLSD& name)
{
- gAgent.mMicrophoneOn = ! gAgent.mMicrophoneOn;
+ LLFirstUse::speak(false);
- if ( gAgent.mMicrophoneOn )
- {
- LLFirstUse::speak(false);
+ LLVoiceClient::getInstance()->inputUserControlState(true);
+}
- LLVoiceClient::getInstance()->inputUserControlState(true);
- LLVoiceClient::getInstance()->inputUserControlState(false);
- }
- else
- {
- LLVoiceClient::getInstance()->inputUserControlState(false);
- LLVoiceClient::getInstance()->inputUserControlState(true);
- }
+// static
+void LLAgent::releaseMicrophone(const LLSD& name)
+{
+ LLVoiceClient::getInstance()->inputUserControlState(false);
}
// static
bool LLAgent::isMicrophoneOn(const LLSD& sdname)
{
- return gAgent.mMicrophoneOn;
+ return LLVoiceClient::getInstance()->getUserPTTState();
}
// ************************************************************
@@ -294,7 +289,6 @@ LLAgent::LLAgent() :
mGenderChosen(FALSE),
mVoiceConnected(false),
- mMicrophoneOn(false),
mAppearanceSerialNum(0),
@@ -314,7 +308,8 @@ LLAgent::LLAgent() :
LLViewerParcelMgr::getInstance()->addAgentParcelChangedCallback(boost::bind(&LLAgent::parcelChangedCallback));
LLUICtrl::EnableCallbackRegistry::currentRegistrar().add("Agent.IsActionAllowed", boost::bind(&LLAgent::isActionAllowed, _2));
- LLUICtrl::CommitCallbackRegistry::currentRegistrar().add("Agent.ToggleMicrophone", boost::bind(&LLAgent::toggleMicrophone, _2));
+ LLUICtrl::CommitCallbackRegistry::currentRegistrar().add("Agent.PressMicrophone", boost::bind(&LLAgent::pressMicrophone, _2));
+ LLUICtrl::CommitCallbackRegistry::currentRegistrar().add("Agent.ReleaseMicrophone", boost::bind(&LLAgent::releaseMicrophone, _2));
LLUICtrl::EnableCallbackRegistry::currentRegistrar().add("Agent.IsMicrophoneOn", boost::bind(&LLAgent::isMicrophoneOn, _2));
}
diff --git a/indra/newview/llagent.h b/indra/newview/llagent.h
index 0355e68b6e..0f7ed9ce68 100644
--- a/indra/newview/llagent.h
+++ b/indra/newview/llagent.h
@@ -290,12 +290,12 @@ public:
bool isVoiceConnected() const { return mVoiceConnected; }
void setVoiceConnected(const bool b) { mVoiceConnected = b; }
- static void toggleMicrophone(const LLSD& name);
+ static void pressMicrophone(const LLSD& name);
+ static void releaseMicrophone(const LLSD& name);
static bool isMicrophoneOn(const LLSD& sdname);
private:
bool mVoiceConnected;
- bool mMicrophoneOn;
//--------------------------------------------------------------------
// Chat
diff --git a/indra/newview/lltoolbarview.cpp b/indra/newview/lltoolbarview.cpp
index 7977faeab7..8ae9328f6d 100644
--- a/indra/newview/lltoolbarview.cpp
+++ b/indra/newview/lltoolbarview.cpp
@@ -330,7 +330,6 @@ void LLToolBarView::draw()
void LLToolBarView::startDragTool( S32 x, S32 y, const LLUUID& uuid)
{
- llinfos << "Merov debug: startDragTool() : x = " << x << ", y = " << y << ", uuid = " << uuid << llendl;
// Flag the tool dragging but don't start it yet
gToolBarView->mDragStarted = false;
gToolBarView->mDragCommand = LLCommandId::null;
@@ -345,7 +344,6 @@ BOOL LLToolBarView::handleDragTool( S32 x, S32 y, const LLUUID& uuid, LLAssetTyp
{
if (!gToolBarView->mDragStarted)
{
- llinfos << "Merov debug: handleDragTool() : x = " << x << ", y = " << y << ", uuid = " << uuid << llendl;
// Start the tool dragging:
// First, create the global drag and drop object
@@ -357,7 +355,6 @@ BOOL LLToolBarView::handleDragTool( S32 x, S32 y, const LLUUID& uuid, LLAssetTyp
LLToolDragAndDrop::ESource src = LLToolDragAndDrop::SOURCE_VIEWER;
LLUUID srcID;
LLToolDragAndDrop::getInstance()->beginMultiDrag(types, cargo_ids, src, srcID);
- llinfos << "Merov debug: beginMultiDrag() launched" << llendl;
// Second, check if the command is present in one of the 3 toolbars
// If it is, store the command, the toolbar and the rank in the toolbar and
@@ -383,7 +380,6 @@ BOOL LLToolBarView::handleDragTool( S32 x, S32 y, const LLUUID& uuid, LLAssetTyp
}
*/
- llinfos << "Merov debug: Drag started cleanly" << llendl;
gToolBarView->mDragStarted = true;
return TRUE;
}
@@ -399,12 +395,10 @@ BOOL LLToolBarView::handleDragTool( S32 x, S32 y, const LLUUID& uuid, LLAssetTyp
BOOL LLToolBarView::handleDropTool( void* cargo_data, S32 x, S32 y, LLToolBar* toolbar)
{
LLInventoryItem* inv_item = (LLInventoryItem*)cargo_data;
- //llinfos << "Merov debug : handleDropTool. Drop " << inv_item->getUUID() << " named " << inv_item->getName() << " of type " << inv_item->getType() << llendl;
LLAssetType::EType type = inv_item->getType();
if (type == LLAssetType::AT_WIDGET)
{
- //llinfos << "Merov debug : handleDropTool. Drop source is a widget -> drop it in place..." << llendl;
// Get the command from its uuid
LLCommandManager& mgr = LLCommandManager::instance();
LLCommandId command_id(inv_item->getUUID());
@@ -419,7 +413,6 @@ BOOL LLToolBarView::handleDropTool( void* cargo_data, S32 x, S32 y, LLToolBar* t
}
// Suppress the command from the toolbars (including the one it's dropped in,
// this will handle move position).
- llinfos << "Merov debug : handleDropTool, " << command_id.name() << ", " << command_id.uuid() << llendl;
gToolBarView->mToolbarLeft->removeCommand(command_id);
gToolBarView->mToolbarRight->removeCommand(command_id);
gToolBarView->mToolbarBottom->removeCommand(command_id);
diff --git a/indra/newview/skins/default/textures/toolbar_icons/caret_bottom.png b/indra/newview/skins/default/textures/toolbar_icons/caret_bottom.png
index 82f58b22b9..d506cda5c9 100644
--- a/indra/newview/skins/default/textures/toolbar_icons/caret_bottom.png
+++ b/indra/newview/skins/default/textures/toolbar_icons/caret_bottom.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/toolbar_icons/caret_left.png b/indra/newview/skins/default/textures/toolbar_icons/caret_left.png
index 75eecc84ed..b1284aaf79 100644
--- a/indra/newview/skins/default/textures/toolbar_icons/caret_left.png
+++ b/indra/newview/skins/default/textures/toolbar_icons/caret_left.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/toolbar_icons/caret_right.png b/indra/newview/skins/default/textures/toolbar_icons/caret_right.png
index 677459ae1c..bf6a4ed66c 100644
--- a/indra/newview/skins/default/textures/toolbar_icons/caret_right.png
+++ b/indra/newview/skins/default/textures/toolbar_icons/caret_right.png
Binary files differ
diff --git a/indra/newview/skins/default/xui/en/panel_toolbar_view.xml b/indra/newview/skins/default/xui/en/panel_toolbar_view.xml
index 5d6967ed32..9ffd62f7a9 100644
--- a/indra/newview/skins/default/xui/en/panel_toolbar_view.xml
+++ b/indra/newview/skins/default/xui/en/panel_toolbar_view.xml
@@ -48,8 +48,8 @@
side="left"
button_display_mode="icons_only">
<icon layout="topleft"
- height="7"
- width="5"
+ height="10"
+ width="10"
follows="left|top"
top="20"
left="10"
@@ -99,8 +99,8 @@
side="right"
button_display_mode="icons_only">
<icon layout="topleft"
- height="7"
- width="5"
+ height="10"
+ width="10"
follows="left|top"
top="20"
left="10"
@@ -130,13 +130,14 @@
button_display_mode="icons_with_text"
visible="true">
<icon layout="topleft"
- height="5"
- width="7"
+ height="10"
+ width="10"
follows="left|top"
top="20"
left="10"
tab_stop="false"
visible="false"
+ use_draw_context_alpha="false"
image_name="Caret_Bottom_Icon"
name="caret" />
</toolbar>