summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorsimon <none@none>2013-08-05 14:54:05 -0700
committersimon <none@none>2013-08-05 14:54:05 -0700
commitd5aa619146d84c17a3e59432b1608d33bd4b64aa (patch)
tree1eac4c12114bac56483aca29aeabdb11b5f438b5 /indra
parente238ddf54bbf6b6adfc115e32bff03de75a8f4ac (diff)
parent48f702029f498b83c6a9ade54c3814def0df4bc8 (diff)
Merge
Diffstat (limited to 'indra')
-rwxr-xr-xindra/llui/llcombobox.cpp7
-rwxr-xr-xindra/llui/llcombobox.h2
-rwxr-xr-xindra/llui/llcommandmanager.cpp2
-rwxr-xr-xindra/llui/llcommandmanager.h4
-rwxr-xr-xindra/llui/lltabcontainer.cpp23
-rwxr-xr-xindra/llui/lltabcontainer.h11
-rwxr-xr-xindra/llui/lltoolbar.cpp1
-rwxr-xr-xindra/newview/app_settings/commands.xml7
-rwxr-xr-xindra/newview/llfloaterwebcontent.cpp2
-rwxr-xr-xindra/newview/skins/default/textures/textures.xml1
-rw-r--r--indra/newview/skins/default/textures/toolbar_icons/highlighting.pngbin0 -> 500 bytes
-rwxr-xr-xindra/newview/skins/default/xui/en/floater_web_content.xml5
-rwxr-xr-xindra/newview/skins/default/xui/en/panel_people.xml3
-rwxr-xr-xindra/newview/skins/default/xui/en/widgets/tab_container.xml15
14 files changed, 72 insertions, 11 deletions
diff --git a/indra/llui/llcombobox.cpp b/indra/llui/llcombobox.cpp
index d4e14d9419..56be52f69a 100755
--- a/indra/llui/llcombobox.cpp
+++ b/indra/llui/llcombobox.cpp
@@ -534,6 +534,13 @@ void LLComboBox::createLineEditor(const LLComboBox::Params& p)
}
}
+void LLComboBox::setLeftTextPadding(S32 pad)
+{
+ S32 left_pad, right_pad;
+ mTextEntry->getTextPadding(&left_pad, &right_pad);
+ mTextEntry->setTextPadding(pad, right_pad);
+}
+
void* LLComboBox::getCurrentUserdata()
{
LLScrollListItem* item = mList->getFirstSelected();
diff --git a/indra/llui/llcombobox.h b/indra/llui/llcombobox.h
index 64dbaea306..1e04fb0866 100755
--- a/indra/llui/llcombobox.h
+++ b/indra/llui/llcombobox.h
@@ -190,6 +190,8 @@ public:
virtual BOOL operateOnAll(EOperation op);
//========================================================================
+
+ void setLeftTextPadding(S32 pad);
void* getCurrentUserdata();
diff --git a/indra/llui/llcommandmanager.cpp b/indra/llui/llcommandmanager.cpp
index 625fb8e870..ab37ee48b6 100755
--- a/indra/llui/llcommandmanager.cpp
+++ b/indra/llui/llcommandmanager.cpp
@@ -50,6 +50,7 @@ const LLCommandId LLCommandId::null = LLCommandId("null command");
LLCommand::Params::Params()
: available_in_toybox("available_in_toybox", false)
, icon("icon")
+ , hover_icon("hover_icon")
, label_ref("label_ref")
, name("name")
, tooltip_ref("tooltip_ref")
@@ -71,6 +72,7 @@ LLCommand::LLCommand(const LLCommand::Params& p)
: mIdentifier(p.name)
, mAvailableInToybox(p.available_in_toybox)
, mIcon(p.icon)
+ , mHoverIcon(p.hover_icon)
, mLabelRef(p.label_ref)
, mName(p.name)
, mTooltipRef(p.tooltip_ref)
diff --git a/indra/llui/llcommandmanager.h b/indra/llui/llcommandmanager.h
index ff5a8a3257..47a9b86785 100755
--- a/indra/llui/llcommandmanager.h
+++ b/indra/llui/llcommandmanager.h
@@ -96,6 +96,8 @@ public:
Mandatory<std::string> name;
Mandatory<std::string> tooltip_ref;
+ Optional<std::string> hover_icon;
+
Mandatory<std::string> execute_function;
Optional<LLSD> execute_parameters;
@@ -124,6 +126,7 @@ public:
const std::string& labelRef() const { return mLabelRef; }
const std::string& name() const { return mName; }
const std::string& tooltipRef() const { return mTooltipRef; }
+ const std::string& hoverIcon() const {return mHoverIcon; }
const std::string& executeFunctionName() const { return mExecuteFunction; }
const LLSD& executeParameters() const { return mExecuteParameters; }
@@ -150,6 +153,7 @@ private:
std::string mLabelRef;
std::string mName;
std::string mTooltipRef;
+ std::string mHoverIcon;
std::string mExecuteFunction;
LLSD mExecuteParameters;
diff --git a/indra/llui/lltabcontainer.cpp b/indra/llui/lltabcontainer.cpp
index fd98155704..9b08d8a9f5 100755
--- a/indra/llui/lltabcontainer.cpp
+++ b/indra/llui/lltabcontainer.cpp
@@ -193,12 +193,15 @@ LLTabContainer::TabParams::TabParams()
: tab_top_image_unselected("tab_top_image_unselected"),
tab_top_image_selected("tab_top_image_selected"),
tab_top_image_flash("tab_top_image_flash"),
+ tab_top_image_hovered("tab_top_image_hovered"),
tab_bottom_image_unselected("tab_bottom_image_unselected"),
tab_bottom_image_selected("tab_bottom_image_selected"),
tab_bottom_image_flash("tab_bottom_image_flash"),
+ tab_bottom_image_hovered("tab_bottom_image_hovered"),
tab_left_image_unselected("tab_left_image_unselected"),
tab_left_image_selected("tab_left_image_selected"),
- tab_left_image_flash("tab_left_image_flash")
+ tab_left_image_flash("tab_left_image_flash"),
+ tab_left_image_hovered("tab_left_image_hovered")
{}
LLTabContainer::Params::Params()
@@ -218,7 +221,8 @@ LLTabContainer::Params::Params()
open_tabs_on_drag_and_drop("open_tabs_on_drag_and_drop", false),
tab_icon_ctrl_pad("tab_icon_ctrl_pad", 0),
use_ellipses("use_ellipses"),
- font_halign("halign")
+ font_halign("halign"),
+ use_highlighting_on_hover("use_highlighting_on_hover",false)
{}
LLTabContainer::LLTabContainer(const LLTabContainer::Params& p)
@@ -254,7 +258,8 @@ LLTabContainer::LLTabContainer(const LLTabContainer::Params& p)
mCustomIconCtrlUsed(p.use_custom_icon_ctrl),
mOpenTabsOnDragAndDrop(p.open_tabs_on_drag_and_drop),
mTabIconCtrlPad(p.tab_icon_ctrl_pad),
- mUseTabEllipses(p.use_ellipses)
+ mUseTabEllipses(p.use_ellipses),
+ mUseHighlightingOnHover(p.use_highlighting_on_hover)
{
static LLUICachedControl<S32> tabcntr_vert_tab_min_width ("UITabCntrVertTabMinWidth", 0);
@@ -891,18 +896,30 @@ void LLTabContainer::update_images(LLTabTuple* tuple, TabParams params, LLTabCon
tuple->mButton->setImageUnselected(static_cast<LLUIImage*>(params.tab_top_image_unselected));
tuple->mButton->setImageSelected(static_cast<LLUIImage*>(params.tab_top_image_selected));
tuple->mButton->setImageFlash(static_cast<LLUIImage*>(params.tab_top_image_flash));
+ if(mUseHighlightingOnHover)
+ {
+ tuple->mButton->setImageHoverUnselected(static_cast<LLUIImage*>(params.tab_top_image_hovered));
+ }
}
else if (pos == LLTabContainer::BOTTOM)
{
tuple->mButton->setImageUnselected(static_cast<LLUIImage*>(params.tab_bottom_image_unselected));
tuple->mButton->setImageSelected(static_cast<LLUIImage*>(params.tab_bottom_image_selected));
tuple->mButton->setImageFlash(static_cast<LLUIImage*>(params.tab_bottom_image_flash));
+ if(mUseHighlightingOnHover)
+ {
+ tuple->mButton->setImageHoverUnselected(static_cast<LLUIImage*>(params.tab_bottom_image_hovered));
+ }
}
else if (pos == LLTabContainer::LEFT)
{
tuple->mButton->setImageUnselected(static_cast<LLUIImage*>(params.tab_left_image_unselected));
tuple->mButton->setImageSelected(static_cast<LLUIImage*>(params.tab_left_image_selected));
tuple->mButton->setImageFlash(static_cast<LLUIImage*>(params.tab_left_image_flash));
+ if(mUseHighlightingOnHover)
+ {
+ tuple->mButton->setImageHoverUnselected(static_cast<LLUIImage*>(params.tab_left_image_hovered));
+ }
}
}
}
diff --git a/indra/llui/lltabcontainer.h b/indra/llui/lltabcontainer.h
index 57862fc626..7e7d4ac6e6 100755
--- a/indra/llui/lltabcontainer.h
+++ b/indra/llui/lltabcontainer.h
@@ -62,12 +62,15 @@ public:
Optional<LLUIImage*> tab_top_image_unselected,
tab_top_image_selected,
tab_top_image_flash,
+ tab_top_image_hovered,
tab_bottom_image_unselected,
tab_bottom_image_selected,
tab_bottom_image_flash,
+ tab_bottom_image_hovered,
tab_left_image_unselected,
tab_left_image_selected,
- tab_left_image_flash;
+ tab_left_image_flash,
+ tab_left_image_hovered;
TabParams();
};
@@ -114,6 +117,11 @@ public:
*/
Optional<S32> tab_icon_ctrl_pad;
+ /**
+ * This variable is used to found out should we highlight tab button on hover
+ */
+ Optional<bool> use_highlighting_on_hover;
+
Params();
};
@@ -307,6 +315,7 @@ private:
bool mOpenTabsOnDragAndDrop;
S32 mTabIconCtrlPad;
bool mUseTabEllipses;
+ bool mUseHighlightingOnHover;
};
#endif // LL_TABCONTAINER_H
diff --git a/indra/llui/lltoolbar.cpp b/indra/llui/lltoolbar.cpp
index 3d9f5cbbc2..8383d61034 100755
--- a/indra/llui/lltoolbar.cpp
+++ b/indra/llui/lltoolbar.cpp
@@ -928,6 +928,7 @@ LLToolBarButton* LLToolBar::createButton(const LLCommandId& id)
button_p.label = LLTrans::getString(commandp->labelRef());
button_p.tool_tip = LLTrans::getString(commandp->tooltipRef());
button_p.image_overlay = LLUI::getUIImage(commandp->icon());
+ button_p.image_hover_unselected = LLUI::getUIImage(commandp->hoverIcon());
button_p.button_flash_enable = commandp->isFlashingAllowed();
button_p.overwriteFrom(mButtonParams[mButtonType]);
LLToolBarButton* button = LLUICtrlFactory::create<LLToolBarButton>(button_p);
diff --git a/indra/newview/app_settings/commands.xml b/indra/newview/app_settings/commands.xml
index 4659673333..aa8e3b5166 100755
--- a/indra/newview/app_settings/commands.xml
+++ b/indra/newview/app_settings/commands.xml
@@ -13,6 +13,7 @@
<command name="appearance"
available_in_toybox="true"
icon="Command_Appearance_Icon"
+ hover_icon="Command_Highlighting_Icon"
label_ref="Command_Appearance_Label"
tooltip_ref="Command_Appearance_Tooltip"
execute_function="Floater.ToggleOrBringToFront"
@@ -23,6 +24,7 @@
<command name="avatar"
available_in_toybox="true"
icon="Command_Avatar_Icon"
+ hover_icon="Command_Highlighting_Icon"
label_ref="Command_Avatar_Label"
tooltip_ref="Command_Avatar_Tooltip"
execute_function="Floater.ToggleOrBringToFront"
@@ -94,6 +96,7 @@
<command name="inventory"
available_in_toybox="true"
icon="Command_Inventory_Icon"
+ hover_icon="Command_Highlighting_Icon"
label_ref="Command_Inventory_Label"
tooltip_ref="Command_Inventory_Tooltip"
execute_function="Floater.ToggleOrBringToFront"
@@ -121,6 +124,7 @@
<command name="minimap"
available_in_toybox="true"
icon="Command_MiniMap_Icon"
+ hover_icon="Command_Highlighting_Icon"
label_ref="Command_MiniMap_Label"
tooltip_ref="Command_MiniMap_Tooltip"
execute_function="Floater.ToggleOrBringToFront"
@@ -171,6 +175,7 @@
<command name="places"
available_in_toybox="true"
icon="Command_Places_Icon"
+ hover_icon="Command_Highlighting_Icon"
label_ref="Command_Places_Label"
tooltip_ref="Command_Places_Tooltip"
execute_function="Floater.ToggleOrBringToFront"
@@ -199,6 +204,7 @@
<command name="search"
available_in_toybox="true"
icon="Command_Search_Icon"
+ hover_icon="Command_Highlighting_Icon"
label_ref="Command_Search_Label"
tooltip_ref="Command_Search_Tooltip"
execute_function="Floater.ToggleOrBringToFront"
@@ -209,6 +215,7 @@
<command name="snapshot"
available_in_toybox="true"
icon="Command_Snapshot_Icon"
+ hover_icon="Command_Highlighting_Icon"
label_ref="Command_Snapshot_Label"
tooltip_ref="Command_Snapshot_Tooltip"
execute_function="Floater.ToggleOrBringToFront"
diff --git a/indra/newview/llfloaterwebcontent.cpp b/indra/newview/llfloaterwebcontent.cpp
index 3fe2518de6..c8b48ea6ca 100755
--- a/indra/newview/llfloaterwebcontent.cpp
+++ b/indra/newview/llfloaterwebcontent.cpp
@@ -350,10 +350,12 @@ void LLFloaterWebContent::handleMediaEvent(LLPluginClassMedia* self, EMediaEvent
if(test_prefix == prefix)
{
mSecureLockIcon->setVisible(true);
+ mAddressCombo->setLeftTextPadding(22);
}
else
{
mSecureLockIcon->setVisible(false);
+ mAddressCombo->setLeftTextPadding(2);
}
}
else if(event == MEDIA_EVENT_CLOSE_REQUEST)
diff --git a/indra/newview/skins/default/textures/textures.xml b/indra/newview/skins/default/textures/textures.xml
index b0e4b71d21..82a3e70d7c 100755
--- a/indra/newview/skins/default/textures/textures.xml
+++ b/indra/newview/skins/default/textures/textures.xml
@@ -152,6 +152,7 @@ with the same filename but different name
<texture name="Command_Speak_Icon" file_name="toolbar_icons/speak.png" preload="true" />
<texture name="Command_View_Icon" file_name="toolbar_icons/view.png" preload="true" />
<texture name="Command_Voice_Icon" file_name="toolbar_icons/nearbyvoice.png" preload="true" />
+ <texture name="Command_Highlighting_Icon" file_name="toolbar_icons/highlighting.png" preload="true" />
<texture name="Caret_Bottom_Icon" file_name="toolbar_icons/caret_bottom.png" preload="true" scale.left="1" scale.top="23" scale.right="15" scale.bottom="1" />
<texture name="Caret_Right_Icon" file_name="toolbar_icons/caret_right.png" preload="true" scale.left="5" scale.top="15" scale.right="28" scale.bottom="1" />
<texture name="Caret_Left_Icon" file_name="toolbar_icons/caret_left.png" preload="true" scale.left="1" scale.top="15" scale.right="23" scale.bottom="1" />
diff --git a/indra/newview/skins/default/textures/toolbar_icons/highlighting.png b/indra/newview/skins/default/textures/toolbar_icons/highlighting.png
new file mode 100644
index 0000000000..093bace257
--- /dev/null
+++ b/indra/newview/skins/default/textures/toolbar_icons/highlighting.png
Binary files differ
diff --git a/indra/newview/skins/default/xui/en/floater_web_content.xml b/indra/newview/skins/default/xui/en/floater_web_content.xml
index cea10adca8..4ba056f904 100755
--- a/indra/newview/skins/default/xui/en/floater_web_content.xml
+++ b/indra/newview/skins/default/xui/en/floater_web_content.xml
@@ -125,11 +125,10 @@
<icon
name="media_secure_lock_flag"
height="16"
- follows="top|right"
image_name="Lock2"
layout="topleft"
- left_delta="620"
- top_delta="2"
+ left_delta="4"
+ top="2"
visible="false"
tool_tip="Secured Browsing"
width="16" />
diff --git a/indra/newview/skins/default/xui/en/panel_people.xml b/indra/newview/skins/default/xui/en/panel_people.xml
index 7ce2627be9..fcd737737d 100755
--- a/indra/newview/skins/default/xui/en/panel_people.xml
+++ b/indra/newview/skins/default/xui/en/panel_people.xml
@@ -66,7 +66,8 @@ Looking for people to hang out with? Try the [secondlife:///app/worldmap World M
tab_position="top"
top="0"
halign="center"
- right="-5">
+ right="-5"
+ use_highlighting_on_hover="true">
<!-- ================================= NEARBY tab =========================== -->
diff --git a/indra/newview/skins/default/xui/en/widgets/tab_container.xml b/indra/newview/skins/default/xui/en/widgets/tab_container.xml
index 0586119681..9559be214a 100755
--- a/indra/newview/skins/default/xui/en/widgets/tab_container.xml
+++ b/indra/newview/skins/default/xui/en/widgets/tab_container.xml
@@ -24,17 +24,26 @@ label_pad_left - padding to the left of tab button labels
tab_bottom_image_unselected="Toolbar_Left_Off"
tab_bottom_image_selected="Toolbar_Left_Selected"
tab_left_image_unselected="SegmentedBtn_Left_Disabled"
- tab_left_image_selected="SegmentedBtn_Left_Selected_Over"/>
+ tab_left_image_selected="SegmentedBtn_Left_Selected_Over"
+ tab_top_image_hovered="TabTop_Left_Selected"
+ tab_button_image_hovered="Toolbar_Left_Selected"
+ tab_left_image_hovered="SegmentedBtn_Left_Selected_Over"/>
<middle_tab tab_top_image_unselected="TabTop_Middle_Off"
tab_top_image_selected="TabTop_Middle_Selected"
tab_bottom_image_unselected="Toolbar_Middle_Off"
tab_bottom_image_selected="Toolbar_Middle_Selected"
tab_left_image_unselected="SegmentedBtn_Left_Disabled"
- tab_left_image_selected="SegmentedBtn_Left_Selected_Over"/>
+ tab_left_image_selected="SegmentedBtn_Left_Selected_Over"
+ tab_top_image_hovered="TabTop_Middle_Selected"
+ tab_button_image_hovered="Toolbar_Middle_Selected"
+ tab_left_image_hovered="SegmentedBtn_Left_Selected_Over"/>
<last_tab tab_top_image_unselected="TabTop_Right_Off"
tab_top_image_selected="TabTop_Right_Selected"
tab_bottom_image_unselected="Toolbar_Right_Off"
tab_bottom_image_selected="Toolbar_Right_Selected"
tab_left_image_unselected="SegmentedBtn_Left_Disabled"
- tab_left_image_selected="SegmentedBtn_Left_Selected_Over"/>
+ tab_left_image_selected="SegmentedBtn_Left_Selected_Over"
+ tab_top_image_hovered="TabTop_Right_Selected"
+ tab_button_image_hovered="Toolbar_Right_Selected"
+ tab_left_image_hovered="SegmentedBtn_Left_Selected_Over"/>
</tab_container>