summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Nelson <none@none>2010-09-10 18:06:42 -0700
committerRichard Nelson <none@none>2010-09-10 18:06:42 -0700
commitfbcde287363f38a4f73a14bbf3501e34b9698c68 (patch)
tree785cb941f9ac063844f16ffcea17569e13066757
parentdb538aa945c5b977fcdc294f7946870cdc8b5d30 (diff)
EXP-23 FIX Tail for chat box hint should be slantways instead of horizontal
-rw-r--r--indra/newview/llbottomtray.cpp2
-rw-r--r--indra/newview/llfirstuse.cpp2
-rw-r--r--indra/newview/llhints.cpp26
-rw-r--r--indra/newview/skins/default/textures/textures.xml1
-rw-r--r--indra/newview/skins/default/textures/windows/hint_arrow_lower_left.pngbin0 -> 3081 bytes
-rw-r--r--indra/newview/skins/default/xui/en/widgets/hint_popup.xml1
6 files changed, 28 insertions, 4 deletions
diff --git a/indra/newview/llbottomtray.cpp b/indra/newview/llbottomtray.cpp
index fba15693c8..8c3d30237f 100644
--- a/indra/newview/llbottomtray.cpp
+++ b/indra/newview/llbottomtray.cpp
@@ -470,6 +470,8 @@ BOOL LLBottomTray::postBuild()
gMenuHolder->addChild(mBottomTrayContextMenu);
mNearbyChatBar = findChild<LLNearbyChatBar>("chat_bar");
+ LLHints::registerHintTarget("chat_bar", mNearbyChatBar->LLView::getHandle());
+
mChatBarContainer = getChild<LLLayoutPanel>("chat_bar_layout_panel");
mToolbarStack = getChild<LLLayoutStack>("toolbar_stack");
diff --git a/indra/newview/llfirstuse.cpp b/indra/newview/llfirstuse.cpp
index ead06d59f9..b864ba6a36 100644
--- a/indra/newview/llfirstuse.cpp
+++ b/indra/newview/llfirstuse.cpp
@@ -74,7 +74,7 @@ void LLFirstUse::resetFirstUse()
// static
void LLFirstUse::otherAvatarChatFirst(bool enable)
{
- firstUseNotification("FirstOtherChatBeforeUser", enable, "HintChat", LLSD(), LLSD().with("target", "incoming_chat").with("direction", "right"));
+ firstUseNotification("FirstOtherChatBeforeUser", enable, "HintChat", LLSD(), LLSD().with("target", "chat_bar").with("direction", "top_right").with("distance", 24));
}
// static
diff --git a/indra/newview/llhints.cpp b/indra/newview/llhints.cpp
index 0c91dd473d..21383109dc 100644
--- a/indra/newview/llhints.cpp
+++ b/indra/newview/llhints.cpp
@@ -43,7 +43,8 @@ public:
LEFT,
TOP,
RIGHT,
- BOTTOM
+ BOTTOM,
+ TOP_RIGHT
} EPopupDirection;
struct PopupDirections : public LLInitParam::TypeValuesHelper<LLHintPopup::EPopupDirection, PopupDirections>
@@ -54,6 +55,7 @@ public:
declare("right", LLHintPopup::RIGHT);
declare("top", LLHintPopup::TOP);
declare("bottom", LLHintPopup::BOTTOM);
+ declare("top_right", LLHintPopup::TOP_RIGHT);
}
};
@@ -76,7 +78,9 @@ public:
Optional<LLUIImage*> left_arrow,
up_arrow,
right_arrow,
- down_arrow;
+ down_arrow,
+ lower_left_arrow;
+
Optional<S32> left_arrow_offset,
up_arrow_offset,
right_arrow_offset,
@@ -90,6 +94,7 @@ public:
up_arrow("up_arrow"),
right_arrow("right_arrow"),
down_arrow("down_arrow"),
+ lower_left_arrow("lower_left_arrow"),
left_arrow_offset("left_arrow_offset"),
up_arrow_offset("up_arrow_offset"),
right_arrow_offset("right_arrow_offset"),
@@ -115,7 +120,8 @@ private:
LLUIImagePtr mArrowLeft,
mArrowUp,
mArrowRight,
- mArrowDown;
+ mArrowDown,
+ mArrowDownAndLeft;
S32 mArrowLeftOffset,
mArrowUpOffset,
mArrowRightOffset,
@@ -137,6 +143,7 @@ LLHintPopup::LLHintPopup(const LLHintPopup::Params& p)
mArrowUp(p.up_arrow),
mArrowRight(p.right_arrow),
mArrowDown(p.down_arrow),
+ mArrowDownAndLeft(p.lower_left_arrow),
mArrowLeftOffset(p.left_arrow_offset),
mArrowUpOffset(p.up_arrow_offset),
mArrowRightOffset(p.right_arrow_offset),
@@ -272,6 +279,19 @@ void LLHintPopup::draw()
arrow_imagep = mArrowUp;
}
break;
+ case TOP_RIGHT:
+ my_rect.setCenterAndSize( target_rect.mRight + (my_local_rect.getWidth() / 2),
+ target_rect.mTop + (my_local_rect.getHeight() / 2 + mDistance),
+ my_local_rect.getWidth(),
+ my_local_rect.getHeight());
+ if (mArrowDownAndLeft)
+ {
+ arrow_rect.setCenterAndSize(my_local_rect.mLeft + mArrowDownAndLeft->getWidth() / 2 + mArrowLeftOffset,
+ my_local_rect.mBottom - mArrowDownAndLeft->getHeight() / 2 + mArrowDownOffset,
+ mArrowDownAndLeft->getWidth(),
+ mArrowDownAndLeft->getHeight());
+ arrow_imagep = mArrowDownAndLeft;
+ }
}
setShape(my_rect);
LLPanel::draw();
diff --git a/indra/newview/skins/default/textures/textures.xml b/indra/newview/skins/default/textures/textures.xml
index 8d6a564687..7c8574609c 100644
--- a/indra/newview/skins/default/textures/textures.xml
+++ b/indra/newview/skins/default/textures/textures.xml
@@ -651,6 +651,7 @@ with the same filename but different name
<texture name="hint_arrow_right" file_name="windows/hint_arrow_right.png" preload="false"/>
<texture name="hint_arrow_up" file_name="windows/hint_arrow_up.png" preload="false"/>
<texture name="hint_arrow_down" file_name="windows/hint_arrow_down.png" preload="false"/>
+ <texture name="hint_arrow_lower_left" file_name="windows/hint_arrow_lower_left.png" preload="false"/>
<texture name="Yellow_Gradient" file_name="windows/yellow_gradient.png"/>
<texture name="Popup_Caution" file_name="icons/pop_up_caution.png"/>
diff --git a/indra/newview/skins/default/textures/windows/hint_arrow_lower_left.png b/indra/newview/skins/default/textures/windows/hint_arrow_lower_left.png
new file mode 100644
index 0000000000..0dfc99898d
--- /dev/null
+++ b/indra/newview/skins/default/textures/windows/hint_arrow_lower_left.png
Binary files differ
diff --git a/indra/newview/skins/default/xui/en/widgets/hint_popup.xml b/indra/newview/skins/default/xui/en/widgets/hint_popup.xml
index a9975941af..92080df154 100644
--- a/indra/newview/skins/default/xui/en/widgets/hint_popup.xml
+++ b/indra/newview/skins/default/xui/en/widgets/hint_popup.xml
@@ -11,6 +11,7 @@
up_arrow="hint_arrow_up"
right_arrow="hint_arrow_right"
down_arrow="hint_arrow_down"
+ lower_left_arrow="hint_arrow_lower_left"
left_arrow_offset="3"
up_arrow_offset="-2"
right_arrow_offset="-3"