summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rw-r--r--indra/llui/llslider.cpp134
-rw-r--r--indra/llui/llslider.h21
-rw-r--r--indra/llui/lltextbase.cpp4
-rw-r--r--indra/llui/lltextbase.h2
-rw-r--r--indra/llui/lltextbox.cpp4
-rw-r--r--indra/llui/lltextbox.h2
-rw-r--r--indra/llui/lltexteditor.cpp4
-rw-r--r--indra/llui/lltexteditor.h2
-rw-r--r--indra/llui/lluicolortable.cpp10
-rw-r--r--indra/newview/CMakeLists.txt2
-rw-r--r--indra/newview/app_settings/settings.xml4
-rwxr-xr-xindra/newview/linux_tools/wrapper.sh2
-rw-r--r--indra/newview/llagent.cpp4
-rw-r--r--indra/newview/llavatarlistitem.cpp15
-rw-r--r--indra/newview/llavatarlistitem.h2
-rw-r--r--indra/newview/llbottomtray.cpp264
-rw-r--r--indra/newview/llbottomtray.h2
-rw-r--r--indra/newview/llchathistory.cpp27
-rw-r--r--indra/newview/llchathistory.h4
-rw-r--r--indra/newview/llchatitemscontainerctrl.cpp57
-rw-r--r--indra/newview/llchatitemscontainerctrl.h6
-rw-r--r--indra/newview/llchatmsgbox.cpp4
-rw-r--r--indra/newview/llchatmsgbox.h2
-rw-r--r--indra/newview/llchiclet.cpp52
-rw-r--r--indra/newview/llexpandabletextbox.cpp4
-rw-r--r--indra/newview/llexpandabletextbox.h2
-rw-r--r--indra/newview/llfloatercamera.cpp92
-rw-r--r--indra/newview/llfloatercamera.h3
-rw-r--r--indra/newview/llimfloater.cpp27
-rw-r--r--indra/newview/llimview.cpp6
-rw-r--r--indra/newview/llinventorypanel.cpp3
-rw-r--r--indra/newview/llnearbychat.cpp107
-rw-r--r--indra/newview/llnearbychat.h6
-rw-r--r--indra/newview/llnearbychathandler.cpp11
-rw-r--r--indra/newview/llnotificationtiphandler.cpp1
-rw-r--r--indra/newview/llpanelobjectinventory.cpp4
-rw-r--r--indra/newview/llparticipantlist.cpp2
-rw-r--r--indra/newview/llscreenchannel.cpp28
-rw-r--r--indra/newview/llscreenchannel.h7
-rw-r--r--indra/newview/llspatialpartition.cpp2
-rw-r--r--indra/newview/llsyswellwindow.cpp9
-rw-r--r--indra/newview/llviewerchat.cpp203
-rw-r--r--indra/newview/llviewerchat.h53
-rw-r--r--indra/newview/llviewermedia.cpp95
-rw-r--r--indra/newview/llviewermedia.h5
-rw-r--r--indra/newview/llviewermessage.cpp9
-rw-r--r--indra/newview/llviewertexture.cpp16
-rw-r--r--indra/newview/llviewertexture.h17
-rw-r--r--indra/newview/llviewertexturelist.cpp26
-rw-r--r--indra/newview/llviewertexturelist.h14
-rw-r--r--indra/newview/llworldmipmap.cpp2
-rw-r--r--indra/newview/skins/default/xui/en/floater_camera.xml69
-rw-r--r--indra/newview/skins/default/xui/en/floater_test_slider.xml8
-rw-r--r--indra/newview/skins/default/xui/en/floater_tools.xml18
-rw-r--r--indra/newview/skins/default/xui/en/floater_tos.xml18
-rw-r--r--indra/newview/skins/default/xui/en/panel_activeim_row.xml42
-rw-r--r--indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml2
-rw-r--r--indra/newview/skins/default/xui/en/panel_sidetray_home_tab.xml2
-rw-r--r--indra/newview/skins/default/xui/en/panel_toast.xml28
-rw-r--r--indra/newview/skins/default/xui/en/widgets/slider_bar.xml8
-rw-r--r--indra/viewer_components/login/tests/lllogin_test.cpp2
61 files changed, 1082 insertions, 499 deletions
diff --git a/indra/llui/llslider.cpp b/indra/llui/llslider.cpp
index f86776384a..da2fc7c68b 100644
--- a/indra/llui/llslider.cpp
+++ b/indra/llui/llslider.cpp
@@ -47,14 +47,17 @@ static LLDefaultChildRegistry::Register<LLSlider> r1("slider_bar");
// have ambigious template lookup problem
LLSlider::Params::Params()
-: track_color("track_color"),
+: orientation ("orientation", std::string ("horizontal")),
+ track_color("track_color"),
thumb_outline_color("thumb_outline_color"),
thumb_center_color("thumb_center_color"),
thumb_image("thumb_image"),
thumb_image_pressed("thumb_image_pressed"),
thumb_image_disabled("thumb_image_disabled"),
- track_image("track_image"),
- track_highlight_image("track_highlight_image"),
+ track_image_horizontal("track_image_horizontal"),
+ track_image_vertical("track_image_vertical"),
+ track_highlight_horizontal_image("track_highlight_horizontal_image"),
+ track_highlight_vertical_image("track_highlight_vertical_image"),
mouse_down_callback("mouse_down_callback"),
mouse_up_callback("mouse_up_callback")
{
@@ -64,14 +67,17 @@ LLSlider::Params::Params()
LLSlider::LLSlider(const LLSlider::Params& p)
: LLF32UICtrl(p),
mMouseOffset( 0 ),
+ mOrientation ((p.orientation() == "horizontal") ? HORIZONTAL : VERTICAL),
mTrackColor(p.track_color()),
mThumbOutlineColor(p.thumb_outline_color()),
mThumbCenterColor(p.thumb_center_color()),
mThumbImage(p.thumb_image),
mThumbImagePressed(p.thumb_image_pressed),
mThumbImageDisabled(p.thumb_image_disabled),
- mTrackImage(p.track_image),
- mTrackHighlightImage(p.track_highlight_image)
+ mTrackImageHorizontal(p.track_image_horizontal),
+ mTrackImageVertical(p.track_image_vertical),
+ mTrackHighlightHorizontalImage(p.track_highlight_horizontal_image),
+ mTrackHighlightVerticalImage(p.track_highlight_vertical_image)
{
mViewModel->setValue(p.initial_value);
updateThumbRect();
@@ -111,14 +117,29 @@ void LLSlider::updateThumbRect()
S32 thumb_width = mThumbImage ? mThumbImage->getWidth() : DEFAULT_THUMB_SIZE;
S32 thumb_height = mThumbImage ? mThumbImage->getHeight() : DEFAULT_THUMB_SIZE;
- S32 left_edge = (thumb_width / 2);
- S32 right_edge = getRect().getWidth() - (thumb_width / 2);
-
- S32 x = left_edge + S32( t * (right_edge - left_edge) );
- mThumbRect.mLeft = x - (thumb_width / 2);
- mThumbRect.mRight = mThumbRect.mLeft + thumb_width;
- mThumbRect.mBottom = getLocalRect().getCenterY() - (thumb_height / 2);
- mThumbRect.mTop = mThumbRect.mBottom + thumb_height;
+
+ if ( mOrientation == HORIZONTAL )
+ {
+ S32 left_edge = (thumb_width / 2);
+ S32 right_edge = getRect().getWidth() - (thumb_width / 2);
+
+ S32 x = left_edge + S32( t * (right_edge - left_edge) );
+ mThumbRect.mLeft = x - (thumb_width / 2);
+ mThumbRect.mRight = mThumbRect.mLeft + thumb_width;
+ mThumbRect.mBottom = getLocalRect().getCenterY() - (thumb_height / 2);
+ mThumbRect.mTop = mThumbRect.mBottom + thumb_height;
+ }
+ else
+ {
+ S32 top_edge = (thumb_height / 2);
+ S32 bottom_edge = getRect().getHeight() - (thumb_height / 2);
+
+ S32 y = top_edge + S32( t * (bottom_edge - top_edge) );
+ mThumbRect.mLeft = getLocalRect().getCenterX() - (thumb_width / 2);
+ mThumbRect.mRight = mThumbRect.mLeft + thumb_width;
+ mThumbRect.mBottom = y - (thumb_height / 2);
+ mThumbRect.mTop = mThumbRect.mBottom + thumb_height;
+ }
}
@@ -138,18 +159,32 @@ BOOL LLSlider::handleHover(S32 x, S32 y, MASK mask)
{
if( hasMouseCapture() )
{
- S32 thumb_half_width = mThumbImage->getWidth()/2;
- S32 left_edge = thumb_half_width;
- S32 right_edge = getRect().getWidth() - (thumb_half_width);
+ if ( mOrientation == HORIZONTAL )
+ {
+ S32 thumb_half_width = mThumbImage->getWidth()/2;
+ S32 left_edge = thumb_half_width;
+ S32 right_edge = getRect().getWidth() - (thumb_half_width);
- x += mMouseOffset;
- x = llclamp( x, left_edge, right_edge );
+ x += mMouseOffset;
+ x = llclamp( x, left_edge, right_edge );
- F32 t = F32(x - left_edge) / (right_edge - left_edge);
- setValueAndCommit(t * (mMaxValue - mMinValue) + mMinValue );
+ F32 t = F32(x - left_edge) / (right_edge - left_edge);
+ setValueAndCommit(t * (mMaxValue - mMinValue) + mMinValue );
+ }
+ else // mOrientation == VERTICAL
+ {
+ S32 thumb_half_height = mThumbImage->getHeight()/2;
+ S32 top_edge = thumb_half_height;
+ S32 bottom_edge = getRect().getHeight() - (thumb_half_height);
+
+ y += mMouseOffset;
+ y = llclamp(y, top_edge, bottom_edge);
+ F32 t = F32(y - top_edge) / (bottom_edge - top_edge);
+ setValueAndCommit(t * (mMaxValue - mMinValue) + mMinValue );
+ }
getWindow()->setCursor(UI_CURSOR_ARROW);
- lldebugst(LLERR_USER_INPUT) << "hover handled by " << getName() << " (active)" << llendl;
+ lldebugst(LLERR_USER_INPUT) << "hover handled by " << getName() << " (active)" << llendl;
}
else
{
@@ -198,7 +233,9 @@ BOOL LLSlider::handleMouseDown(S32 x, S32 y, MASK mask)
// Find the offset of the actual mouse location from the center of the thumb.
if (mThumbRect.pointInRect(x,y))
{
- mMouseOffset = (mThumbRect.mLeft + mThumbImage->getWidth()/2) - x;
+ mMouseOffset = (mOrientation == HORIZONTAL)
+ ? (mThumbRect.mLeft + mThumbImage->getWidth()/2) - x
+ : (mThumbRect.mBottom + mThumbImage->getHeight()/2) - y;
}
else
{
@@ -220,15 +257,12 @@ BOOL LLSlider::handleKeyHere(KEY key, MASK mask)
BOOL handled = FALSE;
switch(key)
{
- case KEY_UP:
case KEY_DOWN:
- // eat up and down keys to be consistent
- handled = TRUE;
- break;
case KEY_LEFT:
setValueAndCommit(getValueF32() - getIncrement());
handled = TRUE;
break;
+ case KEY_UP:
case KEY_RIGHT:
setValueAndCommit(getValueF32() + getIncrement());
handled = TRUE;
@@ -239,6 +273,17 @@ BOOL LLSlider::handleKeyHere(KEY key, MASK mask)
return handled;
}
+BOOL LLSlider::handleScrollWheel(S32 x, S32 y, S32 clicks)
+{
+ if ( mOrientation == VERTICAL )
+ {
+ F32 new_val = getValueF32() - clicks * getIncrement();
+ setValueAndCommit(new_val);
+ return TRUE;
+ }
+ return LLF32UICtrl::handleScrollWheel(x,y,clicks);
+}
+
void LLSlider::draw()
{
F32 alpha = getDrawContext().mAlpha;
@@ -252,13 +297,36 @@ void LLSlider::draw()
gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
// Track
- LLRect track_rect(mThumbImage->getWidth() / 2,
- getLocalRect().getCenterY() + (mTrackImage->getHeight() / 2),
- getRect().getWidth() - mThumbImage->getWidth() / 2,
- getLocalRect().getCenterY() - (mTrackImage->getHeight() / 2) );
- LLRect highlight_rect(track_rect.mLeft, track_rect.mTop, mThumbRect.getCenterX(), track_rect.mBottom);
- mTrackImage->draw(track_rect, LLColor4::white % alpha);
- mTrackHighlightImage->draw(highlight_rect, LLColor4::white % alpha);
+ LLPointer<LLUIImage>& trackImage = ( mOrientation == HORIZONTAL )
+ ? mTrackImageHorizontal
+ : mTrackImageVertical;
+
+ LLPointer<LLUIImage>& trackHighlightImage = ( mOrientation == HORIZONTAL )
+ ? mTrackHighlightHorizontalImage
+ : mTrackHighlightVerticalImage;
+
+ LLRect track_rect;
+ LLRect highlight_rect;
+
+ if ( mOrientation == HORIZONTAL )
+ {
+ track_rect.set(mThumbImage->getWidth() / 2,
+ getLocalRect().getCenterY() + (trackImage->getHeight() / 2),
+ getRect().getWidth() - mThumbImage->getWidth() / 2,
+ getLocalRect().getCenterY() - (trackImage->getHeight() / 2) );
+ highlight_rect.set(track_rect.mLeft, track_rect.mTop, mThumbRect.getCenterX(), track_rect.mBottom);
+ }
+ else
+ {
+ track_rect.set(getLocalRect().getCenterX() - (trackImage->getWidth() / 2),
+ getRect().getHeight(),
+ getLocalRect().getCenterX() + (trackImage->getWidth() / 2),
+ 0);
+ highlight_rect.set(track_rect.mLeft, track_rect.mTop, track_rect.mRight, track_rect.mBottom);
+ }
+
+ trackImage->draw(track_rect, LLColor4::white % alpha);
+ trackHighlightImage->draw(highlight_rect, LLColor4::white % alpha);
// Thumb
if (hasFocus())
diff --git a/indra/llui/llslider.h b/indra/llui/llslider.h
index e2a94e4d8c..6ab0ed7922 100644
--- a/indra/llui/llslider.h
+++ b/indra/llui/llslider.h
@@ -39,8 +39,12 @@
class LLSlider : public LLF32UICtrl
{
public:
+ enum ORIENTATION { HORIZONTAL, VERTICAL };
+
struct Params : public LLInitParam::Block<Params, LLF32UICtrl::Params>
{
+ Optional<std::string> orientation;
+
Optional<LLUIColor> track_color,
thumb_outline_color,
thumb_center_color;
@@ -48,8 +52,10 @@ public:
Optional<LLUIImage*> thumb_image,
thumb_image_pressed,
thumb_image_disabled,
- track_image,
- track_highlight_image;
+ track_image_horizontal,
+ track_image_vertical,
+ track_highlight_horizontal_image,
+ track_highlight_vertical_image;
Optional<CommitCallbackParam> mouse_down_callback,
mouse_up_callback;
@@ -77,6 +83,7 @@ public:
virtual BOOL handleMouseUp(S32 x, S32 y, MASK mask);
virtual BOOL handleMouseDown(S32 x, S32 y, MASK mask);
virtual BOOL handleKeyHere(KEY key, MASK mask);
+ virtual BOOL handleScrollWheel(S32 x, S32 y, S32 clicks);
virtual void draw();
private:
@@ -90,10 +97,14 @@ private:
LLPointer<LLUIImage> mThumbImage;
LLPointer<LLUIImage> mThumbImagePressed;
LLPointer<LLUIImage> mThumbImageDisabled;
- LLPointer<LLUIImage> mTrackImage;
- LLPointer<LLUIImage> mTrackHighlightImage;
+ LLPointer<LLUIImage> mTrackImageHorizontal;
+ LLPointer<LLUIImage> mTrackImageVertical;
+ LLPointer<LLUIImage> mTrackHighlightHorizontalImage;
+ LLPointer<LLUIImage> mTrackHighlightVerticalImage;
+
+ const ORIENTATION mOrientation;
- LLRect mThumbRect;
+ LLRect mThumbRect;
LLUIColor mTrackColor;
LLUIColor mThumbOutlineColor;
LLUIColor mThumbCenterColor;
diff --git a/indra/llui/lltextbase.cpp b/indra/llui/lltextbase.cpp
index 9706878a57..7b1aaac35c 100644
--- a/indra/llui/lltextbase.cpp
+++ b/indra/llui/lltextbase.cpp
@@ -1451,7 +1451,7 @@ void LLTextBase::createUrlContextMenu(S32 x, S32 y, const std::string &in_url)
}
}
-void LLTextBase::setText(const LLStringExplicit &utf8str)
+void LLTextBase::setText(const LLStringExplicit &utf8str ,const LLStyle::Params& input_params)
{
// clear out the existing text and segments
getViewModel()->setDisplay(LLWStringUtil::null);
@@ -1466,7 +1466,7 @@ void LLTextBase::setText(const LLStringExplicit &utf8str)
std::string text(utf8str);
LLStringUtil::removeCRLF(text);
- appendText(text, false);
+ appendText(text, false, input_params);
onValueChange(0, getLength());
}
diff --git a/indra/llui/lltextbase.h b/indra/llui/lltextbase.h
index fb01cd1e7c..70d78c77cd 100644
--- a/indra/llui/lltextbase.h
+++ b/indra/llui/lltextbase.h
@@ -137,7 +137,7 @@ public:
// Text accessors
// TODO: add optional style parameter
- virtual void setText(const LLStringExplicit &utf8str); // uses default style
+ virtual void setText(const LLStringExplicit &utf8str , const LLStyle::Params& input_params = LLStyle::Params()); // uses default style
virtual std::string getText() const;
// wide-char versions
diff --git a/indra/llui/lltextbox.cpp b/indra/llui/lltextbox.cpp
index 00f1d833a3..4c4123cf45 100644
--- a/indra/llui/lltextbox.cpp
+++ b/indra/llui/lltextbox.cpp
@@ -112,12 +112,12 @@ BOOL LLTextBox::handleHover(S32 x, S32 y, MASK mask)
return handled;
}
-void LLTextBox::setText(const LLStringExplicit& text)
+void LLTextBox::setText(const LLStringExplicit& text , const LLStyle::Params& input_params )
{
// does string argument insertion
mText.assign(text);
- LLTextBase::setText(mText.getString());
+ LLTextBase::setText(mText.getString(), input_params );
}
void LLTextBox::setClickedCallback( boost::function<void (void*)> cb, void* userdata /*= NULL */ )
diff --git a/indra/llui/lltextbox.h b/indra/llui/lltextbox.h
index 73f8a7c299..01b4bfa5ed 100644
--- a/indra/llui/lltextbox.h
+++ b/indra/llui/lltextbox.h
@@ -58,7 +58,7 @@ public:
/*virtual*/ BOOL handleMouseUp(S32 x, S32 y, MASK mask);
/*virtual*/ BOOL handleHover(S32 x, S32 y, MASK mask);
- /*virtual*/ void setText( const LLStringExplicit& text );
+ /*virtual*/ void setText( const LLStringExplicit& text, const LLStyle::Params& input_params = LLStyle::Params() );
void setRightAlign() { mHAlign = LLFontGL::RIGHT; }
void setHAlign( LLFontGL::HAlign align ) { mHAlign = align; }
diff --git a/indra/llui/lltexteditor.cpp b/indra/llui/lltexteditor.cpp
index d136c6b49d..224f066968 100644
--- a/indra/llui/lltexteditor.cpp
+++ b/indra/llui/lltexteditor.cpp
@@ -311,12 +311,12 @@ LLTextEditor::~LLTextEditor()
// LLTextEditor
// Public methods
-void LLTextEditor::setText(const LLStringExplicit &utf8str)
+void LLTextEditor::setText(const LLStringExplicit &utf8str, const LLStyle::Params& input_params)
{
blockUndo();
deselect();
- LLTextBase::setText(utf8str);
+ LLTextBase::setText(utf8str, input_params);
resetDirty();
}
diff --git a/indra/llui/lltexteditor.h b/indra/llui/lltexteditor.h
index 10fc94dedc..fb014b86bf 100644
--- a/indra/llui/lltexteditor.h
+++ b/indra/llui/lltexteditor.h
@@ -168,7 +168,7 @@ public:
void appendWidget(const LLInlineViewSegment::Params& params, const std::string& text, bool allow_undo);
// Non-undoable
- void setText(const LLStringExplicit &utf8str);
+ void setText(const LLStringExplicit &utf8str, const LLStyle::Params& input_params = LLStyle::Params());
// Removes text from the end of document
diff --git a/indra/llui/lluicolortable.cpp b/indra/llui/lluicolortable.cpp
index f1e3000547..9be33483d0 100644
--- a/indra/llui/lluicolortable.cpp
+++ b/indra/llui/lluicolortable.cpp
@@ -192,19 +192,27 @@ void LLUIColorTable::clear()
LLUIColor LLUIColorTable::getColor(const std::string& name, const LLColor4& default_color) const
{
string_color_map_t::const_iterator iter = mUserSetColors.find(name);
+
if(iter != mUserSetColors.end())
{
return LLUIColor(&iter->second);
}
iter = mLoadedColors.find(name);
- return (iter != mLoadedColors.end() ? LLUIColor(&iter->second) : LLUIColor(default_color));
+
+ if(iter != mLoadedColors.end())
+ {
+ return LLUIColor(&iter->second);
+ }
+
+ return LLUIColor(default_color);
}
// update user color, loaded colors are parsed on initialization
void LLUIColorTable::setColor(const std::string& name, const LLColor4& color)
{
setColor(name, color, mUserSetColors);
+ setColor(name, color, mLoadedColors);
}
bool LLUIColorTable::loadFromSettings()
diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt
index 9d44f34ea8..4adef84cd3 100644
--- a/indra/newview/CMakeLists.txt
+++ b/indra/newview/CMakeLists.txt
@@ -447,6 +447,7 @@ set(viewer_SOURCE_FILES
llviewerassettype.cpp
llvieweraudio.cpp
llviewercamera.cpp
+ llviewerchat.cpp
llviewercontrol.cpp
llviewercontrollistener.cpp
llviewerdisplay.cpp
@@ -946,6 +947,7 @@ set(viewer_HEADER_FILES
llvieweraudio.h
llviewerbuild.h
llviewercamera.h
+ llviewerchat.h
llviewercontrol.h
llviewercontrollistener.h
llviewerdisplay.h
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index eb4148f92f..8ad52784d3 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -3563,7 +3563,7 @@
<key>Type</key>
<string>S32</string>
<key>Value</key>
- <integer>400</integer>
+ <integer>305</integer>
</map>
<key>HelpUseLocal</key>
<map>
@@ -4917,7 +4917,7 @@
<key>Type</key>
<string>S32</string>
<key>Value</key>
- <integer>350</integer>
+ <integer>305</integer>
</map>
<key>NotificationToastLifeTime</key>
<map>
diff --git a/indra/newview/linux_tools/wrapper.sh b/indra/newview/linux_tools/wrapper.sh
index 3209654498..f84102e1fb 100755
--- a/indra/newview/linux_tools/wrapper.sh
+++ b/indra/newview/linux_tools/wrapper.sh
@@ -118,7 +118,7 @@ if [ -n "$LL_TCMALLOC" ]; then
fi
fi
-export SL_ENV='LD_LIBRARY_PATH="`pwd`"/lib:"`pwd`"/app_settings/mozilla-runtime-linux-i686:"${LD_LIBRARY_PATH}"'
+export SL_ENV='LD_LIBRARY_PATH="`pwd`"/lib:"${LD_LIBRARY_PATH}"'
export SL_CMD='$LL_WRAPPER bin/do-not-directly-run-secondlife-bin'
export SL_OPT="`cat etc/gridargs.dat` $@"
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp
index d2c8558f0b..ca1688ad1f 100644
--- a/indra/newview/llagent.cpp
+++ b/indra/newview/llagent.cpp
@@ -3080,10 +3080,6 @@ void LLAgent::updateCamera()
mOrbitLeftKey > 0.f, // right
mOrbitDownKey > 0.f); // bottom
- camera_floater->mZoom->setToggleState(
- mOrbitInKey > 0.f, // top
- mOrbitOutKey > 0.f); // bottom
-
camera_floater->mTrack->setToggleState(
mPanLeftKey > 0.f, // left
mPanUpKey > 0.f, // top
diff --git a/indra/newview/llavatarlistitem.cpp b/indra/newview/llavatarlistitem.cpp
index 7df278d887..c670a65bcc 100644
--- a/indra/newview/llavatarlistitem.cpp
+++ b/indra/newview/llavatarlistitem.cpp
@@ -311,3 +311,18 @@ void LLAvatarListItem::onNameCache(const std::string& first_name, const std::str
mAvatarName->setValue(name);
mAvatarName->setToolTip(name);
}
+
+void LLAvatarListItem::reshapeAvatarName()
+{
+ S32 width_delta = 0;
+ width_delta += mShowProfileBtn ? mProfileBtnWidth : 0;
+ width_delta += mSpeakingIndicator->getVisible() ? mSpeakingIndicatorWidth : 0;
+ width_delta += mAvatarIcon->getVisible() ? mIconWidth : 0;
+ width_delta += mShowInfoBtn ? mInfoBtnWidth : 0;
+ width_delta += mLastInteractionTime->getVisible() ? mLastInteractionTime->getRect().getWidth() : 0;
+
+ S32 height = mAvatarName->getRect().getHeight();
+ S32 width = getRect().getWidth() - width_delta;
+
+ mAvatarName->reshape(width, height);
+}
diff --git a/indra/newview/llavatarlistitem.h b/indra/newview/llavatarlistitem.h
index d379797a46..9d48101a44 100644
--- a/indra/newview/llavatarlistitem.h
+++ b/indra/newview/llavatarlistitem.h
@@ -82,6 +82,8 @@ public:
void setContextMenu(ContextMenu* menu) { mContextMenu = menu; }
+ void reshapeAvatarName();
+
private:
typedef enum e_online_status {
diff --git a/indra/newview/llbottomtray.cpp b/indra/newview/llbottomtray.cpp
index ab685b69ad..8d57c68cf2 100644
--- a/indra/newview/llbottomtray.cpp
+++ b/indra/newview/llbottomtray.cpp
@@ -261,22 +261,22 @@ void LLBottomTray::showBottomTrayContextMenu(S32 x, S32 y, MASK mask)
void LLBottomTray::showGestureButton(BOOL visible)
{
- mGesturePanel->setVisible(visible);
+ showTrayButton(RS_BUTTON_GESTURES, visible);
}
void LLBottomTray::showMoveButton(BOOL visible)
{
- mMovementPanel->setVisible(visible);
+ showTrayButton(RS_BUTTON_MOVEMENT, visible);
}
void LLBottomTray::showCameraButton(BOOL visible)
{
- mCamPanel->setVisible(visible);
+ showTrayButton(RS_BUTTON_CAMERA, visible);
}
void LLBottomTray::showSnapshotButton(BOOL visible)
{
- mSnapshotPanel->setVisible(visible);
+ showTrayButton(RS_BUTTON_SNAPSHOT, visible);
}
namespace
@@ -401,8 +401,6 @@ void LLBottomTray::reshape(S32 width, S32 height, BOOL called_from_parent)
void LLBottomTray::updateResizeState(S32 new_width, S32 cur_width)
{
mResizeState = RS_NORESIZE;
- MASK compensative_view_item_mask = RS_CHATBAR_INPUT;
- LLPanel* compansative_view = mNearbyChatBar;
S32 delta_width = new_width - cur_width;
// if (delta_width == 0) return;
@@ -422,153 +420,113 @@ void LLBottomTray::updateResizeState(S32 new_width, S32 cur_width)
<< ", chiclet_panel_min_width: " << chiclet_panel_min_width
<< llendl;
- bool still_should_be_processed = true;
// bottom tray is narrowed
if (shrink)
{
- S32 compensative_delta_width = 0;
- if (chiclet_panel_width > chiclet_panel_min_width)
- {
- // we have some space to decrease chiclet panel
- S32 panel_delta_min = chiclet_panel_width - chiclet_panel_min_width;
- mResizeState |= RS_CHICLET_PANEL;
-
- S32 delta_panel = llmin(-delta_width, panel_delta_min);
+ processWidthDecreased(delta_width);
+ }
+ // bottom tray is widen
+ else
+ {
+ processWidthIncreased(delta_width);
+ }
- lldebugs << "delta_width: " << delta_width
- << ", panel_delta_min: " << panel_delta_min
- << ", delta_panel: " << delta_panel
- << llendl;
+ lldebugs << "New resize state: " << mResizeState << llendl;
+}
- // is chiclet panel width enough to process resizing?
- delta_width += panel_delta_min;
+void LLBottomTray::processWidthDecreased(S32 delta_width)
+{
+ bool still_should_be_processed = true;
- still_should_be_processed = delta_width < 0;
+ const S32 chiclet_panel_width = mChicletPanel->getParent()->getRect().getWidth();
+ const S32 chiclet_panel_min_width = mChicletPanel->getMinWidth();
- mChicletPanel->getParent()->reshape(mChicletPanel->getParent()->getRect().getWidth() - delta_panel, mChicletPanel->getParent()->getRect().getHeight());
- log(mChicletPanel, "after processing panel decreasing via chiclet panel");
+ if (chiclet_panel_width > chiclet_panel_min_width)
+ {
+ // we have some space to decrease chiclet panel
+ S32 panel_delta_min = chiclet_panel_width - chiclet_panel_min_width;
+ mResizeState |= RS_CHICLET_PANEL;
- lldebugs << "RS_CHICLET_PANEL"
- << ", delta_width: " << delta_width
- << llendl;
- }
-
- if (still_should_be_processed && chatbar_panel_width > chatbar_panel_min_width)
- {
- // we have some space to decrease chatbar panel
- S32 panel_delta_min = chatbar_panel_width - chatbar_panel_min_width;
- mResizeState |= RS_CHATBAR_INPUT;
+ S32 delta_panel = llmin(-delta_width, panel_delta_min);
- S32 delta_panel = llmin(-delta_width, panel_delta_min);
+ lldebugs << "delta_width: " << delta_width
+ << ", panel_delta_min: " << panel_delta_min
+ << ", delta_panel: " << delta_panel
+ << llendl;
- // is chatbar panel width enough to process resizing?
- delta_width += panel_delta_min;
-
+ // is chiclet panel width enough to process resizing?
+ delta_width += panel_delta_min;
- still_should_be_processed = delta_width < 0;
+ still_should_be_processed = delta_width < 0;
- mNearbyChatBar->reshape(mNearbyChatBar->getRect().getWidth() - delta_panel, mNearbyChatBar->getRect().getHeight());
+ mChicletPanel->getParent()->reshape(mChicletPanel->getParent()->getRect().getWidth() - delta_panel, mChicletPanel->getParent()->getRect().getHeight());
+ log(mChicletPanel, "after processing panel decreasing via chiclet panel");
- lldebugs << "RS_CHATBAR_INPUT"
- << ", delta_panel: " << delta_panel
- << ", delta_width: " << delta_width
- << llendl;
+ lldebugs << "RS_CHICLET_PANEL"
+ << ", delta_width: " << delta_width
+ << llendl;
+ }
- log(mChicletPanel, "after nearby was processed");
+ const S32 chatbar_panel_width = mNearbyChatBar->getRect().getWidth();
+ const S32 chatbar_panel_min_width = mNearbyChatBar->getMinWidth();
+ if (still_should_be_processed && chatbar_panel_width > chatbar_panel_min_width)
+ {
+ // we have some space to decrease chatbar panel
+ S32 panel_delta_min = chatbar_panel_width - chatbar_panel_min_width;
+ mResizeState |= RS_CHATBAR_INPUT;
- }
- if (still_should_be_processed)
- {
- mResizeState |= compensative_view_item_mask;
+ S32 delta_panel = llmin(-delta_width, panel_delta_min);
- if (mSnapshotPanel->getVisible())
- {
- mResizeState |= RS_BUTTON_SNAPSHOT;
- delta_width += mSnapshotPanel->getRect().getWidth();
-
- if (delta_width > 0)
- {
- compensative_delta_width += delta_width;
- }
- lldebugs << "RS_BUTTON_SNAPSHOT"
- << ", compensative_delta_width: " << compensative_delta_width
- << ", delta_width: " << delta_width
- << llendl;
- showSnapshotButton(false);
- }
+ // is chatbar panel width enough to process resizing?
+ delta_width += panel_delta_min;
- if (delta_width < 0 && mCamPanel->getVisible())
- {
- mResizeState |= RS_BUTTON_CAMERA;
- delta_width += mCamPanel->getRect().getWidth();
- if (delta_width > 0)
- {
- compensative_delta_width += delta_width;
- }
- lldebugs << "RS_BUTTON_CAMERA"
- << ", compensative_delta_width: " << compensative_delta_width
- << ", delta_width: " << delta_width
- << llendl;
- showCameraButton(false);
- }
- if (delta_width < 0 && mMovementPanel->getVisible())
- {
- mResizeState |= RS_BUTTON_MOVEMENT;
- delta_width += mMovementPanel->getRect().getWidth();
- if (delta_width > 0)
- {
- compensative_delta_width += delta_width;
- }
- lldebugs << "RS_BUTTON_MOVEMENT"
- << ", compensative_delta_width: " << compensative_delta_width
- << ", delta_width: " << delta_width
- << llendl;
- showMoveButton(false);
- }
+ still_should_be_processed = delta_width < 0;
- if (delta_width < 0 && mGesturePanel->getVisible())
- {
- mResizeState |= RS_BUTTON_GESTURES;
- delta_width += mGesturePanel->getRect().getWidth();
- if (delta_width > 0)
- {
- compensative_delta_width += delta_width;
- }
- lldebugs << "RS_BUTTON_GESTURES"
- << ", compensative_delta_width: " << compensative_delta_width
- << ", delta_width: " << delta_width
- << llendl;
- showGestureButton(false);
- }
+ mNearbyChatBar->reshape(mNearbyChatBar->getRect().getWidth() - delta_panel, mNearbyChatBar->getRect().getHeight());
- if (delta_width < 0)
- {
- llwarns << "WARNING: there is no enough room for bottom tray, resizing still should be processed" << llendl;
- }
+ lldebugs << "RS_CHATBAR_INPUT"
+ << ", delta_panel: " << delta_panel
+ << ", delta_width: " << delta_width
+ << llendl;
- if (compensative_delta_width != 0)
- {
- if (compansative_view) log(compansative_view, "before applying compensative width: ");
- compansative_view->reshape(compansative_view->getRect().getWidth() + compensative_delta_width, compansative_view->getRect().getHeight() );
- if (compansative_view) log(compansative_view, "after applying compensative width: ");
- lldebugs << compensative_delta_width << llendl;
+ log(mChicletPanel, "after nearby was processed");
- }
- }
}
- // bottom tray is widen
- else
+
+ S32 buttons_freed_width = 0;
+ if (still_should_be_processed)
{
- processWidthIncreased(delta_width);
- }
+ processHideButton(RS_BUTTON_SNAPSHOT, &delta_width, &buttons_freed_width);
- lldebugs << "New resize state: " << mResizeState << llendl;
-}
+ if (delta_width < 0)
+ {
+ processHideButton(RS_BUTTON_CAMERA, &delta_width, &buttons_freed_width);
+ }
-void LLBottomTray::processWidthDecreased(S32 delta_width)
-{
+ if (delta_width < 0)
+ {
+ processHideButton(RS_BUTTON_MOVEMENT, &delta_width, &buttons_freed_width);
+ }
+ if (delta_width < 0)
+ {
+ processHideButton(RS_BUTTON_GESTURES, &delta_width, &buttons_freed_width);
+ }
+
+ if (delta_width < 0)
+ {
+ llwarns << "WARNING: there is no enough room for bottom tray, resizing still should be processed" << llendl;
+ }
+
+ if (buttons_freed_width > 0)
+ {
+ log(mNearbyChatBar, "before applying compensative width");
+ mNearbyChatBar->reshape(mNearbyChatBar->getRect().getWidth() + buttons_freed_width, mNearbyChatBar->getRect().getHeight() );
+ log(mNearbyChatBar, "after applying compensative width");
+ lldebugs << buttons_freed_width << llendl;
+ }
+ }
}
void LLBottomTray::processWidthIncreased(S32 delta_width)
@@ -627,9 +585,9 @@ void LLBottomTray::processWidthIncreased(S32 delta_width)
chatbar_shrink_width = chatbar_available_shrink_width;
}
- log(mNearbyChatBar, "increase width: before applying compensative width: ");
+ log(mNearbyChatBar, "increase width: before applying compensative width");
mNearbyChatBar->reshape(mNearbyChatBar->getRect().getWidth() - chatbar_shrink_width, mNearbyChatBar->getRect().getHeight() );
- if (mNearbyChatBar) log(mNearbyChatBar, "after applying compensative width: ");
+ if (mNearbyChatBar) log(mNearbyChatBar, "after applying compensative width");
lldebugs << chatbar_shrink_width << llendl;
// 3. use width available via decreasing of chiclet panel
@@ -678,24 +636,42 @@ bool LLBottomTray::processShowButton(EResizeState shown_object_type, S32* availa
*available_width -= required_width;
*buttons_required_width += required_width;
- switch (shown_object_type)
- {
- case RS_BUTTON_GESTURES: showGestureButton(true); break;
- case RS_BUTTON_MOVEMENT: showMoveButton(true); break;
- case RS_BUTTON_CAMERA: showCameraButton(true); break;
- case RS_BUTTON_SNAPSHOT: showSnapshotButton(true); break;
- default:
- llwarns << "Unexpected type of button to be shown: " << shown_object_type << llendl;
- }
+ showTrayButton(shown_object_type, true);
lldebugs << "processing object type: " << shown_object_type
- << ", buttons_required_width: " << buttons_required_width
+ << ", buttons_required_width: " << *buttons_required_width
<< llendl;
}
}
return can_be_shown;
}
+void LLBottomTray::processHideButton(EResizeState shown_object_type, S32* required_width, S32* buttons_freed_width)
+{
+ LLPanel* panel = mStateProcessedObjectMap[shown_object_type];
+ if (NULL == panel)
+ {
+ lldebugs << "There is no object to process for state: " << shown_object_type << llendl;
+ return;
+ }
+
+ if (panel->getVisible())
+ {
+ *required_width += panel->getRect().getWidth();
+
+ if (*required_width > 0)
+ {
+ *buttons_freed_width += *required_width;
+ }
+
+ showTrayButton(shown_object_type, false);
+
+ lldebugs << "processing object type: " << shown_object_type
+ << ", buttons_freed_width: " << *buttons_freed_width
+ << llendl;
+ }
+}
+
bool LLBottomTray::canButtonBeShown(LLPanel* panel) const
{
bool can_be_shown = !panel->getVisible();
@@ -713,4 +689,16 @@ void LLBottomTray::initStateProcessedObjectMap()
mStateProcessedObjectMap.insert(std::make_pair(RS_BUTTON_CAMERA, mCamPanel));
mStateProcessedObjectMap.insert(std::make_pair(RS_BUTTON_SNAPSHOT, mSnapshotPanel));
}
+
+void LLBottomTray::showTrayButton(EResizeState shown_object_type, bool visible)
+{
+ LLPanel* panel = mStateProcessedObjectMap[shown_object_type];
+ if (NULL == panel)
+ {
+ lldebugs << "There is no object to show for state: " << shown_object_type << llendl;
+ return;
+ }
+
+ panel->setVisible(visible);
+}
//EOF
diff --git a/indra/newview/llbottomtray.h b/indra/newview/llbottomtray.h
index c88bdeda1c..3847168ae1 100644
--- a/indra/newview/llbottomtray.h
+++ b/indra/newview/llbottomtray.h
@@ -107,8 +107,10 @@ private:
void processWidthIncreased(S32 delta_width);
void log(LLView* panel, const std::string& descr);
bool processShowButton(EResizeState shown_object_type, S32* available_width, S32* buttons_required_width);
+ void processHideButton(EResizeState shown_object_type, S32* required_width, S32* buttons_freed_width);
bool canButtonBeShown(LLPanel* panel) const;
void initStateProcessedObjectMap();
+ void showTrayButton(EResizeState shown_object_type, bool visible);
MASK mResizeState;
diff --git a/indra/newview/llchathistory.cpp b/indra/newview/llchathistory.cpp
index d1922cfd6e..0070e654ee 100644
--- a/indra/newview/llchathistory.cpp
+++ b/indra/newview/llchathistory.cpp
@@ -131,7 +131,7 @@ public:
menu = LLUICtrlFactory::getInstance()->createFromFile<LLMenuGL>("menu_object_icon.xml", gMenuHolder, LLViewerMenuHolderGL::child_registry_t::instance());
mPopupMenuHandleObject = menu->getHandle();
- setMouseDownCallback(boost::bind(&LLChatHistoryHeader::onHeaderPanelClick, this, _2, _3, _4));
+ setDoubleClickCallback(boost::bind(&LLChatHistoryHeader::onHeaderPanelClick, this, _2, _3, _4));
return LLPanel::postBuild();
}
@@ -167,7 +167,15 @@ public:
void onHeaderPanelClick(S32 x, S32 y, MASK mask)
{
- LLFloaterReg::showInstance("inspect_avatar", LLSD().insert("avatar_id", mAvatarID));
+ if (mSourceType == CHAT_SOURCE_OBJECT)
+ {
+ LLFloaterReg::showInstance("inspect_object", LLSD().insert("object_id", mAvatarID));
+ }
+ else if (mSourceType == CHAT_SOURCE_AGENT)
+ {
+ LLFloaterReg::showInstance("inspect_avatar", LLSD().insert("avatar_id", mAvatarID));
+ }
+ //if chat source is system, you may add "else" here to define behaviour.
}
const LLUUID& getAvatarId () const { return mAvatarID;}
@@ -333,16 +341,28 @@ LLView* LLChatHistory::getHeader(const LLChat& chat,const LLStyle::Params& style
return header;
}
-void LLChatHistory::appendWidgetMessage(const LLChat& chat, LLStyle::Params& style_params)
+void LLChatHistory::appendWidgetMessage(const LLChat& chat)
{
LLView* view = NULL;
std::string view_text = "\n[" + formatCurrentTime() + "] " + chat.mFromName + ": ";
+
LLInlineViewSegment::Params p;
p.force_newline = true;
p.left_pad = mLeftWidgetPad;
p.right_pad = mRightWidgetPad;
+
+ LLColor4 txt_color = LLUIColorTable::instance().getColor("White");
+ LLViewerChat::getChatColor(chat,txt_color);
+ LLFontGL* fontp = LLViewerChat::getChatFont();
+
+ LLStyle::Params style_params;
+ style_params.color(txt_color);
+ style_params.readonly_color(txt_color);
+ style_params.font(fontp);
+
+
if (mLastFromName == chat.mFromName)
{
view = getSeparator();
@@ -357,6 +377,7 @@ void LLChatHistory::appendWidgetMessage(const LLChat& chat, LLStyle::Params& sty
else
p.top_pad = mTopHeaderPad;
p.bottom_pad = mBottomHeaderPad;
+
}
p.view = view;
diff --git a/indra/newview/llchathistory.h b/indra/newview/llchathistory.h
index f0944042af..f689a225fe 100644
--- a/indra/newview/llchathistory.h
+++ b/indra/newview/llchathistory.h
@@ -34,7 +34,7 @@
#define LLCHATHISTORY_H_
#include "lltexteditor.h"
-#include "llchat.h"
+#include "llviewerchat.h"
//Chat log widget allowing addition of a message as a widget
class LLChatHistory : public LLTextEditor
@@ -109,7 +109,7 @@ class LLChatHistory : public LLTextEditor
* @param time time of a message.
* @param message message itself.
*/
- void appendWidgetMessage(const LLChat& chat, LLStyle::Params& style_params);
+ void appendWidgetMessage(const LLChat& chat);
private:
std::string mLastFromName;
diff --git a/indra/newview/llchatitemscontainerctrl.cpp b/indra/newview/llchatitemscontainerctrl.cpp
index 63b9fd8e66..d2e3247250 100644
--- a/indra/newview/llchatitemscontainerctrl.cpp
+++ b/indra/newview/llchatitemscontainerctrl.cpp
@@ -120,10 +120,10 @@ std::string LLNearbyChatToastPanel::appendTime()
-void LLNearbyChatToastPanel::addText (const std::string& message)
+void LLNearbyChatToastPanel::addText (const std::string& message , const LLStyle::Params& input_params)
{
LLChatMsgBox* msg_text = getChild<LLChatMsgBox>("msg_text", false);
- msg_text->addText(message);
+ msg_text->addText(message , input_params);
mMessages.push_back(message);
}
@@ -134,9 +134,34 @@ void LLNearbyChatToastPanel::init(LLSD& notification)
mText = notification["message"].asString(); // UTF-8 line of text
mFromName = notification["from"].asString(); // agent or object name
mFromID = notification["from_id"].asUUID(); // agent id or object id
+
int sType = notification["source"].asInteger();
mSourceType = (EChatSourceType)sType;
-
+
+ std::string color_name = notification["text_color"].asString();
+
+ mTextColor = LLUIColorTable::instance().getColor(color_name);
+ mTextColor.mV[VALPHA] =notification["color_alpha"].asReal();
+
+ S32 font_size = notification["font_size"].asInteger();
+ switch(font_size)
+ {
+ case 0:
+ mFont = LLFontGL::getFontSansSerifSmall();
+ break;
+ default:
+ case 1:
+ mFont = LLFontGL::getFontSansSerif();
+ break;
+ case 2:
+ mFont = LLFontGL::getFontSansSerifBig();
+ break;
+ }
+
+ LLStyle::Params style_params;
+ style_params.color(mTextColor);
+ style_params.font(mFont);
+
std::string str_sender;
if(gAgentID != mFromID)
@@ -144,13 +169,13 @@ void LLNearbyChatToastPanel::init(LLSD& notification)
else
str_sender = LLTrans::getString("You");;
- caption->getChild<LLTextBox>("sender_name", false)->setText(str_sender);
+ caption->getChild<LLTextBox>("sender_name", false)->setText(str_sender , style_params);
- caption->getChild<LLTextBox>("msg_time", false)->setText(appendTime());
+ caption->getChild<LLTextBox>("msg_time", false)->setText(appendTime() , style_params );
LLChatMsgBox* msg_text = getChild<LLChatMsgBox>("msg_text", false);
- msg_text->setText(mText);
+ msg_text->setText(mText, style_params);
LLUICtrl* msg_inspector = caption->getChild<LLUICtrl>("msg_inspector");
if(mSourceType != CHAT_SOURCE_AGENT)
@@ -171,7 +196,15 @@ void LLNearbyChatToastPanel::setMessage (const LLChat& chat_msg)
notification["from_id"] = chat_msg.mFromID;
notification["time"] = chat_msg.mTime;
notification["source"] = (S32)chat_msg.mSourceType;
-
+
+ std::string r_color_name="White";
+ F32 r_color_alpha = 1.0f;
+ LLViewerChat::getChatColor( chat_msg, r_color_name, r_color_alpha);
+
+ notification["text_color"] = r_color_name;
+ notification["color_alpha"] = r_color_alpha;
+
+ notification["font_size"] = (S32)LLViewerChat::getChatFontSize() ;
init(notification);
}
@@ -201,11 +234,17 @@ void LLNearbyChatToastPanel::setWidth(S32 width)
text_box->reshape(width - msg_left_offset - msg_right_offset,100/*its not magic number, we just need any number*/);
LLChatMsgBox* msg_text = getChild<LLChatMsgBox>("msg_text", false);
+
+ LLStyle::Params style_params;
+ style_params.color(mTextColor);
+ style_params.font(mFont);
+
+
if(mText.length())
- msg_text->setText(mText);
+ msg_text->setText(mText, style_params);
for(size_t i=0;i<mMessages.size();++i)
- msg_text->addText(mMessages[i]);
+ msg_text->addText(mMessages[i] , style_params);
setRect(LLRect(getRect().mLeft, getRect().mTop, getRect().mLeft + width , getRect().mBottom));
snapToMessageHeight ();
diff --git a/indra/newview/llchatitemscontainerctrl.h b/indra/newview/llchatitemscontainerctrl.h
index 8fb045b6d9..a65bfedd09 100644
--- a/indra/newview/llchatitemscontainerctrl.h
+++ b/indra/newview/llchatitemscontainerctrl.h
@@ -36,7 +36,7 @@
#include "llpanel.h"
#include "llscrollbar.h"
#include "string"
-#include "llchat.h"
+#include "llviewerchat.h"
#include "lltoastpanel.h"
typedef enum e_show_item_header
@@ -59,7 +59,7 @@ public:
const LLUUID& getFromID() const { return mFromID;}
- void addText (const std::string& message);
+ void addText (const std::string& message , const LLStyle::Params& input_params = LLStyle::Params());
void setMessage (const LLChat& msg);
void setWidth (S32 width);
void snapToMessageHeight ();
@@ -89,6 +89,8 @@ private:
std::string mFromName; // agent or object name
LLUUID mFromID; // agent id or object id
EChatSourceType mSourceType;
+ LLColor4 mTextColor;
+ LLFontGL* mFont;
std::vector<std::string> mMessages;
diff --git a/indra/newview/llchatmsgbox.cpp b/indra/newview/llchatmsgbox.cpp
index 12626e3b43..bb0ec2db27 100644
--- a/indra/newview/llchatmsgbox.cpp
+++ b/indra/newview/llchatmsgbox.cpp
@@ -84,7 +84,7 @@ LLChatMsgBox::LLChatMsgBox(const Params& p) :
mBlockSpacing(p.block_spacing)
{}
-void LLChatMsgBox::addText( const LLStringExplicit& text )
+void LLChatMsgBox::addText( const LLStringExplicit& text , const LLStyle::Params& input_params )
{
S32 length = getLength();
// if there is existing text, add a separator
@@ -94,5 +94,5 @@ void LLChatMsgBox::addText( const LLStringExplicit& text )
insertSegment(new ChatSeparator(length - 1, length - 1));
}
// prepend newline only if there is some existing text
- appendText(text, length > 0);
+ appendText(text, length > 0, input_params);
}
diff --git a/indra/newview/llchatmsgbox.h b/indra/newview/llchatmsgbox.h
index df29db58c3..9e16616729 100644
--- a/indra/newview/llchatmsgbox.h
+++ b/indra/newview/llchatmsgbox.h
@@ -61,7 +61,7 @@ protected:
friend class LLUICtrlFactory;
public:
- void addText(const LLStringExplicit &text);
+ void addText(const LLStringExplicit &text, const LLStyle::Params& input_params = LLStyle::Params());
private:
S32 mBlockSpacing;
diff --git a/indra/newview/llchiclet.cpp b/indra/newview/llchiclet.cpp
index b919195fb2..fd86192650 100644
--- a/indra/newview/llchiclet.cpp
+++ b/indra/newview/llchiclet.cpp
@@ -54,10 +54,12 @@ static LLDefaultChildRegistry::Register<LLChicletPanel> t1("chiclet_panel");
static LLDefaultChildRegistry::Register<LLNotificationChiclet> t2("chiclet_notification");
static LLDefaultChildRegistry::Register<LLIMP2PChiclet> t3("chiclet_im_p2p");
static LLDefaultChildRegistry::Register<LLIMGroupChiclet> t4("chiclet_im_group");
+static LLDefaultChildRegistry::Register<LLAdHocChiclet> t5("chiclet_im_adhoc");
static const LLRect CHICLET_RECT(0, 25, 25, 0);
-static const LLRect CHICLET_ICON_RECT(0, 24, 24, 0);
+static const LLRect CHICLET_ICON_RECT(0, 22, 22, 0);
static const LLRect VOICE_INDICATOR_RECT(25, 25, 45, 0);
+static const S32 OVERLAY_ICON_SHIFT = 2; // used for shifting of an overlay icon for new massages in a chiclet
// static
const S32 LLChicletPanel::s_scroll_ratio = 10;
@@ -217,13 +219,15 @@ LLIMChiclet::LLIMChiclet(const LLIMChiclet::Params& p)
icon_params.visible = false;
icon_params.image = LLUI::getUIImage(p.new_messages_icon_name);
mNewMessagesIcon = LLUICtrlFactory::create<LLIconCtrl>(icon_params);
+ addChild(mNewMessagesIcon);
+
// adjust size and position of an icon
LLRect chiclet_rect = p.rect;
- LLRect overlay_icon_rect = LLRect(chiclet_rect.getWidth()/2, chiclet_rect.mTop, chiclet_rect.mRight, chiclet_rect.getHeight()/2);
- // shift an icon a little bit to the right and up corner of a chiclet
- overlay_icon_rect.translate(overlay_icon_rect.getWidth()/5, overlay_icon_rect.getHeight()/5);
+ LLRect overlay_icon_rect = LLRect(chiclet_rect.getWidth()/2, chiclet_rect.getHeight(), chiclet_rect.getWidth(), chiclet_rect.getHeight()/2);
mNewMessagesIcon->setRect(overlay_icon_rect);
- addChild(mNewMessagesIcon);
+
+ // shift an icon a little bit to the right and up corner of a chiclet
+ overlay_icon_rect.translate(OVERLAY_ICON_SHIFT, OVERLAY_ICON_SHIFT);
setShowCounter(false);
}
@@ -423,7 +427,6 @@ void LLIMP2PChiclet::updateMenuItems()
bool is_friend = LLAvatarActions::isFriend(getOtherParticipantId());
mPopupMenu->getChild<LLUICtrl>("Add Friend")->setEnabled(!is_friend);
- mPopupMenu->getChild<LLUICtrl>("Remove Friend")->setEnabled(is_friend);
}
BOOL LLIMP2PChiclet::handleRightMouseDown(S32 x, S32 y, MASK mask)
@@ -602,6 +605,9 @@ BOOL LLAdHocChiclet::handleRightMouseDown(S32 x, S32 y, MASK mask)
LLIMGroupChiclet::Params::Params()
: group_icon("group_icon")
+, unread_notifications("unread_notifications")
+, speaker("speaker")
+, show_speaker("show_speaker")
{
rect(CHICLET_RECT);
@@ -830,8 +836,13 @@ LLChicletPanel::~LLChicletPanel()
void im_chiclet_callback(LLChicletPanel* panel, const LLSD& data){
LLUUID session_id = data["session_id"].asUUID();
- S32 unread = data["num_unread"].asInteger();
+ LLUUID from_id = data["from_id"].asUUID();
+ const std::string from = data["from"].asString();
+
+ //we do not show balloon (indicator of new messages) for system messages and our own messages
+ if (from_id.isNull() || from_id == gAgentID || SYSTEM_FROM == from) return;
+ S32 unread = data["num_unread"].asInteger();
LLIMFloater* im_floater = LLIMFloater::findInstance(session_id);
if (im_floater && im_floater->getVisible())
{
@@ -880,19 +891,34 @@ BOOL LLChicletPanel::postBuild()
void LLChicletPanel::onCurrentVoiceChannelChanged(const LLUUID& session_id)
{
- for(chiclet_list_t::iterator it = mChicletList.begin(); it != mChicletList.end(); ++it)
+ static LLUUID s_previous_active_voice_session_id;
+
+ std::list<LLChiclet*> chiclets = LLIMChiclet::sFindChicletsSignal(session_id);
+
+ for(std::list<LLChiclet *>::iterator it = chiclets.begin(); it != chiclets.end(); ++it)
{
LLIMChiclet* chiclet = dynamic_cast<LLIMChiclet*>(*it);
if(chiclet)
{
- if(chiclet->getSessionId() == session_id)
+ chiclet->setShowSpeaker(true);
+ }
+ }
+
+ if(!s_previous_active_voice_session_id.isNull() && s_previous_active_voice_session_id != session_id)
+ {
+ chiclets = LLIMChiclet::sFindChicletsSignal(s_previous_active_voice_session_id);
+
+ for(std::list<LLChiclet *>::iterator it = chiclets.begin(); it != chiclets.end(); ++it)
+ {
+ LLIMChiclet* chiclet = dynamic_cast<LLIMChiclet*>(*it);
+ if(chiclet)
{
- chiclet->setShowSpeaker(true);
- continue;
+ chiclet->setShowSpeaker(false);
}
- chiclet->setShowSpeaker(false);
- }
+ }
}
+
+ s_previous_active_voice_session_id = session_id;
}
S32 LLChicletPanel::calcChickletPanleWidth()
diff --git a/indra/newview/llexpandabletextbox.cpp b/indra/newview/llexpandabletextbox.cpp
index 424d635321..6d7da107ac 100644
--- a/indra/newview/llexpandabletextbox.cpp
+++ b/indra/newview/llexpandabletextbox.cpp
@@ -129,12 +129,12 @@ void LLExpandableTextBox::LLTextBoxEx::reshape(S32 width, S32 height, BOOL calle
}
}
-void LLExpandableTextBox::LLTextBoxEx::setText(const LLStringExplicit& text)
+void LLExpandableTextBox::LLTextBoxEx::setText(const LLStringExplicit& text,const LLStyle::Params& input_params)
{
// LLTextBox::setText will obliterate the expander segment, so make sure
// we generate it again by clearing mExpanderVisible
mExpanderVisible = false;
- LLTextBox::setText(text);
+ LLTextBox::setText(text, input_params);
// text contents have changed, segments are cleared out
// so hide the expander and determine if we need it
diff --git a/indra/newview/llexpandabletextbox.h b/indra/newview/llexpandabletextbox.h
index 3fe646c29c..7c989cfa50 100644
--- a/indra/newview/llexpandabletextbox.h
+++ b/indra/newview/llexpandabletextbox.h
@@ -60,7 +60,7 @@ protected:
// adds or removes "More" link as needed
/*virtual*/ void reshape(S32 width, S32 height, BOOL called_from_parent = TRUE);
- /*virtual*/ void setText(const LLStringExplicit& text);
+ /*virtual*/ void setText(const LLStringExplicit& text, const LLStyle::Params& input_params = LLStyle::Params());
/**
* Returns difference between text box height and text height.
diff --git a/indra/newview/llfloatercamera.cpp b/indra/newview/llfloatercamera.cpp
index d1317f7c36..92e958b32d 100644
--- a/indra/newview/llfloatercamera.cpp
+++ b/indra/newview/llfloatercamera.cpp
@@ -40,10 +40,12 @@
// Viewer includes
#include "lljoystickbutton.h"
#include "llviewercontrol.h"
+#include "llviewercamera.h"
#include "llbottomtray.h"
#include "llagent.h"
#include "lltoolmgr.h"
#include "lltoolfocus.h"
+#include "llslider.h"
// Constants
const F32 CAMERA_BUTTON_DELAY = 0.0f;
@@ -54,6 +56,93 @@ const F32 CAMERA_BUTTON_DELAY = 0.0f;
#define PRESETS "camera_presets"
#define CONTROLS "controls"
+// Zoom the camera in and out
+class LLPanelCameraZoom
+: public LLPanel
+{
+ LOG_CLASS(LLPanelCameraZoom);
+public:
+ LLPanelCameraZoom();
+
+ /* virtual */ BOOL postBuild();
+ /* virtual */ void onOpen(const LLSD& key);
+
+protected:
+ void onZoomPlusHeldDown();
+ void onZoomMinusHeldDown();
+ void onSliderValueChanged();
+
+private:
+ F32 mSavedSliderVal;
+ LLButton* mPlusBtn;
+ LLButton* mMinusBtn;
+ LLSlider* mSlider;
+};
+
+static LLRegisterPanelClassWrapper<LLPanelCameraZoom> t_camera_zoom_panel("camera_zoom_panel");
+
+//-------------------------------------------------------------------------------
+// LLPanelCameraZoom
+//-------------------------------------------------------------------------------
+
+LLPanelCameraZoom::LLPanelCameraZoom()
+: mPlusBtn( NULL ),
+ mMinusBtn( NULL ),
+ mSlider( NULL ),
+ mSavedSliderVal(0.f)
+{
+ mCommitCallbackRegistrar.add("Zoom.minus", boost::bind(&LLPanelCameraZoom::onZoomPlusHeldDown, this));
+ mCommitCallbackRegistrar.add("Zoom.plus", boost::bind(&LLPanelCameraZoom::onZoomMinusHeldDown, this));
+ mCommitCallbackRegistrar.add("Slider.value_changed", boost::bind(&LLPanelCameraZoom::onSliderValueChanged, this));
+}
+
+BOOL LLPanelCameraZoom::postBuild()
+{
+ mPlusBtn = getChild <LLButton> ("zoom_plus_btn");
+ mMinusBtn = getChild <LLButton> ("zoom_minus_btn");
+ mSlider = getChild <LLSlider> ("zoom_slider");
+ mSlider->setMinValue(.0f);
+ mSlider->setMaxValue(8.f);
+ return LLPanel::postBuild();
+}
+
+void LLPanelCameraZoom::onOpen(const LLSD& key)
+{
+ LLVector3d to_focus = gAgent.getPosGlobalFromAgent(LLViewerCamera::getInstance()->getOrigin()) - gAgent.calcFocusPositionTargetGlobal();
+ mSavedSliderVal = 8.f - (F32)to_focus.magVec(); // maximum minus current
+ mSlider->setValue( mSavedSliderVal );
+}
+
+void LLPanelCameraZoom::onZoomPlusHeldDown()
+{
+ F32 val = mSlider->getValueF32();
+ F32 inc = mSlider->getIncrement();
+ mSlider->setValue(val - inc);
+ // commit only if value changed
+ if (val != mSlider->getValueF32())
+ mSlider->onCommit();
+}
+
+void LLPanelCameraZoom::onZoomMinusHeldDown()
+{
+ F32 val = mSlider->getValueF32();
+ F32 inc = mSlider->getIncrement();
+ mSlider->setValue(val + inc);
+ // commit only if value changed
+ if (val != mSlider->getValueF32())
+ mSlider->onCommit();
+}
+
+void LLPanelCameraZoom::onSliderValueChanged()
+{
+ F32 val = mSlider->getValueF32();
+ F32 rate = val - mSavedSliderVal;
+
+ gAgent.unlockView();
+ gAgent.cameraOrbitIn(rate);
+
+ mSavedSliderVal = val;
+}
//
// Member functions
@@ -125,6 +214,7 @@ void LLFloaterCamera::onOpen(const LLSD& key)
anchor_panel, this,
getDockTongue(), LLDockControl::TOP));
+ mZoom->onOpen(key);
}
void LLFloaterCamera::onClose(bool app_quitting)
@@ -147,7 +237,7 @@ BOOL LLFloaterCamera::postBuild()
setIsChrome(TRUE);
mRotate = getChild<LLJoystickCameraRotate>(ORBIT);
- mZoom = getChild<LLJoystickCameraZoom>(ZOOM);
+ mZoom = getChild<LLPanelCameraZoom>(ZOOM);
mTrack = getChild<LLJoystickCameraTrack>(PAN);
assignButton2Mode(CAMERA_CTRL_MODE_ORBIT, "orbit_btn");
diff --git a/indra/newview/llfloatercamera.h b/indra/newview/llfloatercamera.h
index 583f279e62..4873a34e00 100644
--- a/indra/newview/llfloatercamera.h
+++ b/indra/newview/llfloatercamera.h
@@ -39,6 +39,7 @@ class LLJoystickCameraRotate;
class LLJoystickCameraZoom;
class LLJoystickCameraTrack;
class LLFloaterReg;
+class LLPanelCameraZoom;
enum ECameraControlMode
{
@@ -74,7 +75,7 @@ public:
virtual void onClose(bool app_quitting);
LLJoystickCameraRotate* mRotate;
- LLJoystickCameraZoom* mZoom;
+ LLPanelCameraZoom* mZoom;
LLJoystickCameraTrack* mTrack;
private:
diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp
index 54fc6f02fb..0f32d0b313 100644
--- a/indra/newview/llimfloater.cpp
+++ b/indra/newview/llimfloater.cpp
@@ -211,6 +211,7 @@ BOOL LLIMFloater::postBuild()
}
mControlPanel->setSessionId(mSessionID);
+ mControlPanel->setVisible(gSavedSettings.getBOOL("IMShowControlPanel"));
LLButton* slide_left = getChild<LLButton>("slide_left_btn");
slide_left->setVisible(mControlPanel->getVisible());
@@ -356,8 +357,6 @@ LLIMFloater* LLIMFloater::show(const LLUUID& session_id)
LLDockControl::TOP, boost::bind(&LLIMFloater::getAllowedRect, floater, _1)));
}
- floater->childSetVisible("panel_im_control_panel", gSavedSettings.getBOOL("IMShowControlPanel"));
-
return floater;
}
@@ -463,7 +462,7 @@ void LLIMFloater::updateMessages()
if (messages.size())
{
- LLUIColor chat_color = LLUIColorTable::instance().getColor("IMChatColor");
+// LLUIColor chat_color = LLUIColorTable::instance().getColor("IMChatColor");
std::ostringstream message;
std::list<LLSD>::const_reverse_iterator iter = messages.rbegin();
@@ -476,32 +475,12 @@ void LLIMFloater::updateMessages()
LLUUID from_id = msg["from_id"].asUUID();
std::string from = from_id != gAgentID ? msg["from"].asString() : LLTrans::getString("You");
std::string message = msg["message"].asString();
- LLStyle::Params style_params;
- style_params.color(chat_color);
LLChat chat;
chat.mFromID = from_id;
chat.mFromName = from;
- //Handle IRC styled /me messages.
- std::string prefix = message.substr(0, 4);
- if (prefix == "/me " || prefix == "/me'")
- {
- if (from.size() > 0)
- {
- style_params.font.style = "ITALIC";
- chat.mText = from + " ";
- mChatHistory->appendWidgetMessage(chat, style_params);
- }
- message = message.substr(3);
- style_params.font.style = "UNDERLINE";
- mChatHistory->appendText(message, FALSE, style_params);
- }
- else
- {
- chat.mText = message;
- mChatHistory->appendWidgetMessage(chat, style_params);
- }
+ mChatHistory->appendWidgetMessage(chat);
mLastMessageIndex = msg["index"].asInteger();
}
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp
index d48aaf8461..ee785e7ecb 100644
--- a/indra/newview/llimview.cpp
+++ b/indra/newview/llimview.cpp
@@ -441,11 +441,7 @@ bool LLIMModel::addMessage(const LLUUID& session_id, const std::string& from, co
addToHistory(session_id, from, from_id, utf8_text);
if (log2file) logToFile(session_id, from, from_id, utf8_text);
- //we do not count system messages and our messages
- if (from_id.notNull() && from_id != gAgentID && SYSTEM_FROM != from)
- {
- session->mNumUnread++;
- }
+ session->mNumUnread++;
// notify listeners
LLSD arg;
diff --git a/indra/newview/llinventorypanel.cpp b/indra/newview/llinventorypanel.cpp
index dfd4af5c28..97f90ac845 100644
--- a/indra/newview/llinventorypanel.cpp
+++ b/indra/newview/llinventorypanel.cpp
@@ -139,6 +139,7 @@ BOOL LLInventoryPanel::postBuild()
p.name = getName();
p.rect = folder_rect;
p.parent_panel = this;
+ p.tool_tip = p.name;
mFolders = LLUICtrlFactory::create<LLFolderView>(p);
mFolders->setAllowMultiSelect(mAllowMultiSelect);
}
@@ -492,6 +493,7 @@ void LLInventoryPanel::buildNewViews(const LLUUID& id)
p.icon = new_listener->getIcon();
p.root = mFolders;
p.listener = new_listener;
+ p.tool_tip = p.name;
LLFolderViewFolder* folderp = LLUICtrlFactory::create<LLFolderViewFolder>(p);
folderp->setItemSortOrder(mFolders->getSortOrder());
@@ -518,6 +520,7 @@ void LLInventoryPanel::buildNewViews(const LLUUID& id)
params.root(mFolders);
params.listener(new_listener);
params.rect(LLRect (0, 0, 0, 0));
+ params.tool_tip = params.name;
itemp = LLUICtrlFactory::create<LLFolderViewItem> (params);
}
}
diff --git a/indra/newview/llnearbychat.cpp b/indra/newview/llnearbychat.cpp
index ac806d7106..85db69174d 100644
--- a/indra/newview/llnearbychat.cpp
+++ b/indra/newview/llnearbychat.cpp
@@ -132,120 +132,31 @@ void LLNearbyChat::applySavedVariables()
}
}
-LLColor4 nearbychat_get_text_color(const LLChat& chat)
-{
- LLColor4 text_color;
-
- if(chat.mMuted)
- {
- text_color.setVec(0.8f, 0.8f, 0.8f, 1.f);
- }
- else
- {
- switch(chat.mSourceType)
- {
- case CHAT_SOURCE_SYSTEM:
- text_color = LLUIColorTable::instance().getColor("SystemChatColor");
- break;
- case CHAT_SOURCE_AGENT:
- if (chat.mFromID.isNull())
- {
- text_color = LLUIColorTable::instance().getColor("SystemChatColor");
- }
- else
- {
- if(gAgentID == chat.mFromID)
- {
- text_color = LLUIColorTable::instance().getColor("UserChatColor");
- }
- else
- {
- text_color = LLUIColorTable::instance().getColor("AgentChatColor");
- }
- }
- break;
- case CHAT_SOURCE_OBJECT:
- if (chat.mChatType == CHAT_TYPE_DEBUG_MSG)
- {
- text_color = LLUIColorTable::instance().getColor("ScriptErrorColor");
- }
- else if ( chat.mChatType == CHAT_TYPE_OWNER )
- {
- text_color = LLUIColorTable::instance().getColor("llOwnerSayChatColor");
- }
- else
- {
- text_color = LLUIColorTable::instance().getColor("ObjectChatColor");
- }
- break;
- default:
- text_color.setToWhite();
- }
-
- if (!chat.mPosAgent.isExactlyZero())
- {
- LLVector3 pos_agent = gAgent.getPositionAgent();
- F32 distance = dist_vec(pos_agent, chat.mPosAgent);
- if (distance > gAgent.getNearChatRadius())
- {
- // diminish far-off chat
- text_color.mV[VALPHA] = 0.8f;
- }
- }
- }
-
- return text_color;
-}
-
-void LLNearbyChat::add_timestamped_line(const LLChat& chat, const LLColor4& color)
-{
- S32 font_size = gSavedSettings.getS32("ChatFontSize");
-
- const LLFontGL* fontp = NULL;
- switch(font_size)
- {
- case 0:
- fontp = LLFontGL::getFontSansSerifSmall();
- break;
- default:
- case 1:
- fontp = LLFontGL::getFontSansSerif();
- break;
- case 2:
- fontp = LLFontGL::getFontSansSerifBig();
- break;
- }
-
- LLStyle::Params style_params;
- style_params.color(color);
- style_params.font(fontp);
- LLUUID uuid = chat.mFromID;
- std::string from = chat.mFromName;
- std::string message = chat.mText;
- mChatHistory->appendWidgetMessage(chat, style_params);
-}
-
void LLNearbyChat::addMessage(const LLChat& chat)
{
- LLColor4 color = nearbychat_get_text_color(chat);
-
if (chat.mChatType == CHAT_TYPE_DEBUG_MSG)
{
if(gSavedSettings.getBOOL("ShowScriptErrors") == FALSE)
return;
if (gSavedSettings.getS32("ShowScriptErrorsLocation")== 1)// show error in window //("ScriptErrorsAsChat"))
{
+
+ LLColor4 txt_color;
+
+ LLViewerChat::getChatColor(chat,txt_color);
+
LLFloaterScriptDebug::addScriptLine(chat.mText,
chat.mFromName,
- color,
+ txt_color,
chat.mFromID);
return;
}
}
- // could flash the chat button in the status bar here. JC
if (!chat.mMuted)
- add_timestamped_line(chat, color);
+ {
+ mChatHistory->appendWidgetMessage(chat);
+ }
}
void LLNearbyChat::onNearbySpeakers()
diff --git a/indra/newview/llnearbychat.h b/indra/newview/llnearbychat.h
index cb4654654a..3303c388af 100644
--- a/indra/newview/llnearbychat.h
+++ b/indra/newview/llnearbychat.h
@@ -35,7 +35,7 @@
#include "lldockablefloater.h"
#include "llscrollbar.h"
-#include "llchat.h"
+#include "llviewerchat.h"
class LLResizeBar;
class LLChatHistory;
@@ -47,8 +47,7 @@ public:
~LLNearbyChat();
BOOL postBuild ();
- void addMessage (const LLChat& message);
-
+ void addMessage (const LLChat& message);
void onNearbyChatContextMenuItemClicked(const LLSD& userdata);
bool onNearbyChatCheckContextMenuItem(const LLSD& userdata);
@@ -64,7 +63,6 @@ private:
void getAllowedRect (LLRect& rect);
void onNearbySpeakers ();
- void add_timestamped_line(const LLChat& chat, const LLColor4& color);
private:
diff --git a/indra/newview/llnearbychathandler.cpp b/indra/newview/llnearbychathandler.cpp
index e10c506f08..e6665a935e 100644
--- a/indra/newview/llnearbychathandler.cpp
+++ b/indra/newview/llnearbychathandler.cpp
@@ -223,7 +223,7 @@ void LLNearbyChatScreenChannel::addNotification(LLSD& notification)
void LLNearbyChatScreenChannel::arrangeToasts()
{
- if(m_active_toasts.size() == 0 || mIsHovering)
+ if(m_active_toasts.size() == 0 || isHovering())
return;
hideToastsFromScreen();
@@ -351,7 +351,14 @@ void LLNearbyChatHandler::processChat(const LLChat& chat_msg)
notification["time"] = chat_msg.mTime;
notification["source"] = (S32)chat_msg.mSourceType;
notification["chat_type"] = (S32)chat_msg.mChatType;
-
+
+ std::string r_color_name = "White";
+ F32 r_color_alpha = 1.0f;
+ LLViewerChat::getChatColor( chat_msg, r_color_name, r_color_alpha);
+
+ notification["text_color"] = r_color_name;
+ notification["color_alpha"] = r_color_alpha;
+ notification["font_size"] = (S32)LLViewerChat::getChatFontSize() ;
channel->addNotification(notification);
}
diff --git a/indra/newview/llnotificationtiphandler.cpp b/indra/newview/llnotificationtiphandler.cpp
index 823c92a94e..60a27d5154 100644
--- a/indra/newview/llnotificationtiphandler.cpp
+++ b/indra/newview/llnotificationtiphandler.cpp
@@ -91,6 +91,7 @@ bool LLTipHandler::processNotification(const LLSD& notify)
if(nearby_chat)
{
LLChat chat_msg(notification->getMessage());
+ chat_msg.mSourceType = CHAT_SOURCE_SYSTEM;
nearby_chat->addMessage(chat_msg);
// don't show toast if Nearby Chat is opened
diff --git a/indra/newview/llpanelobjectinventory.cpp b/indra/newview/llpanelobjectinventory.cpp
index a5e9407a41..b1fbf789c6 100644
--- a/indra/newview/llpanelobjectinventory.cpp
+++ b/indra/newview/llpanelobjectinventory.cpp
@@ -1570,6 +1570,7 @@ void LLPanelObjectInventory::reset()
p.name = "task inventory";
p.task_id = getTaskUUID();
p.parent_panel = this;
+ p.tool_tip= p.name;
mFolders = LLUICtrlFactory::create<LLFolderView>(p);
// this ensures that we never say "searching..." or "no items found"
mFolders->getFilter()->setShowFolderState(LLInventoryFilter::SHOW_ALL_FOLDERS);
@@ -1711,6 +1712,7 @@ void LLPanelObjectInventory::createFolderViews(LLInventoryObject* inventory_root
p.icon_open = LLUI::getUIImage("Inv_FolderOpen");
p.root = mFolders;
p.listener = bridge;
+ p.tool_tip = p.name;
new_folder = LLUICtrlFactory::create<LLFolderViewFolder>(p);
new_folder->addToFolder(mFolders, mFolders);
new_folder->toggleOpen();
@@ -1751,6 +1753,7 @@ void LLPanelObjectInventory::createViewsForCategory(InventoryObjectList* invento
p.icon_open = LLUI::getUIImage("Inv_FolderOpen");
p.root = mFolders;
p.listener = bridge;
+ p.tool_tip = p.name;
view = LLUICtrlFactory::create<LLFolderViewFolder>(p);
child_categories.put(new obj_folder_pair(obj,
(LLFolderViewFolder*)view));
@@ -1764,6 +1767,7 @@ void LLPanelObjectInventory::createViewsForCategory(InventoryObjectList* invento
params.root(mFolders);
params.listener(bridge);
params.rect(LLRect());
+ params.tool_tip = params.name;
view = LLUICtrlFactory::create<LLFolderViewItem> (params);
}
view->addToFolder(folder, mFolders);
diff --git a/indra/newview/llparticipantlist.cpp b/indra/newview/llparticipantlist.cpp
index f5367c0477..13bd059d45 100644
--- a/indra/newview/llparticipantlist.cpp
+++ b/indra/newview/llparticipantlist.cpp
@@ -130,6 +130,7 @@ void LLParticipantList::onAvatarListRefreshed(LLUICtrl* ctrl, const LLSD& param)
{
name.erase(found, moderator_indicator_len);
item->setName(name);
+ item->reshapeAvatarName();
}
}
}
@@ -151,6 +152,7 @@ void LLParticipantList::onAvatarListRefreshed(LLUICtrl* ctrl, const LLSD& param)
name += " ";
name += moderator_indicator;
item->setName(name);
+ item->reshapeAvatarName();
}
}
}
diff --git a/indra/newview/llscreenchannel.cpp b/indra/newview/llscreenchannel.cpp
index b667fbf5fd..ed606d5457 100644
--- a/indra/newview/llscreenchannel.cpp
+++ b/indra/newview/llscreenchannel.cpp
@@ -63,7 +63,7 @@ LLScreenChannelBase::LLScreenChannelBase(const LLUUID& id) :
,mCanStoreToasts(true)
,mHiddenToastsNum(0)
,mOverflowToastHidden(false)
- ,mIsHovering(false)
+ ,mHoveredToast(NULL)
,mControlHovering(false)
,mShowToasts(true)
{
@@ -216,8 +216,10 @@ void LLScreenChannel::deleteToast(LLToast* toast)
// update channel's Hovering state
// turning hovering off manually because onMouseLeave won't happen if a toast was closed using a keyboard
- if(toast->hasFocus())
- setHovering(false);
+ if(mHoveredToast == toast)
+ {
+ mHoveredToast = NULL;
+ }
// close the toast
toast->closeFloater();
@@ -352,7 +354,7 @@ void LLScreenChannel::modifyToastByNotificationID(LLUUID id, LLPanel* panel)
//--------------------------------------------------------------------------
void LLScreenChannel::redrawToasts()
{
- if(mToastList.size() == 0 || mIsHovering)
+ if(mToastList.size() == 0 || isHovering())
return;
hideToastsFromScreen();
@@ -456,7 +458,6 @@ void LLScreenChannel::createOverflowToast(S32 bottom, F32 timer)
mOverflowToastPanel->setOnFadeCallback(boost::bind(&LLScreenChannel::closeOverflowToastPanel, this));
LLTextBox* text_box = mOverflowToastPanel->getChild<LLTextBox>("toast_text");
- LLIconCtrl* icon = mOverflowToastPanel->getChild<LLIconCtrl>("icon");
std::string text = llformat(mOverflowFormatString.c_str(),mHiddenToastsNum);
if(mHiddenToastsNum == 1)
{
@@ -474,7 +475,6 @@ void LLScreenChannel::createOverflowToast(S32 bottom, F32 timer)
text_box->setValue(text);
text_box->setVisible(TRUE);
- icon->setVisible(TRUE);
mOverflowToastPanel->setVisible(TRUE);
}
@@ -532,7 +532,6 @@ void LLScreenChannel::createStartUpToast(S32 notif_num, F32 timer)
mStartUpToastPanel->setOnFadeCallback(boost::bind(&LLScreenChannel::onStartUpToastHide, this));
LLTextBox* text_box = mStartUpToastPanel->getChild<LLTextBox>("toast_text");
- LLIconCtrl* icon = mStartUpToastPanel->getChild<LLIconCtrl>("icon");
std::string mStartUpFormatString;
@@ -555,8 +554,6 @@ void LLScreenChannel::createStartUpToast(S32 notif_num, F32 timer)
text_box->setValue(text);
text_box->setVisible(TRUE);
- icon->setVisible(TRUE);
-
addChild(mStartUpToastPanel);
mStartUpToastPanel->setVisible(TRUE);
@@ -654,7 +651,14 @@ void LLScreenChannel::onToastHover(LLToast* toast, bool mouse_enter)
// we must check this to prevent incorrect setting for hovering in a channel
std::map<LLToast*, bool>::iterator it_first, it_second;
S32 stack_size = mToastEventStack.size();
- mIsHovering = mouse_enter;
+ if(mouse_enter)
+ {
+ mHoveredToast = toast;
+ }
+ else
+ {
+ mHoveredToast = NULL;
+ }
switch(stack_size)
{
@@ -666,7 +670,7 @@ void LLScreenChannel::onToastHover(LLToast* toast, bool mouse_enter)
if((*it_first).second && !mouse_enter && ((*it_first).first != toast) )
{
mToastEventStack.clear();
- mIsHovering = true;
+ mHoveredToast = toast;
}
else
{
@@ -678,7 +682,7 @@ void LLScreenChannel::onToastHover(LLToast* toast, bool mouse_enter)
LL_ERRS ("LLScreenChannel::onToastHover: stack size error " ) << stack_size << llendl;
}
- if(!mIsHovering)
+ if(!isHovering())
redrawToasts();
}
diff --git a/indra/newview/llscreenchannel.h b/indra/newview/llscreenchannel.h
index fd31690622..f39b94b89d 100644
--- a/indra/newview/llscreenchannel.h
+++ b/indra/newview/llscreenchannel.h
@@ -93,9 +93,10 @@ public:
// Channel's behavior-functions
// set whether a channel will control hovering inside itself or not
virtual void setControlHovering(bool control) { mControlHovering = control; }
- // set Hovering flag for a channel
- virtual void setHovering(bool hovering) { mIsHovering = hovering; }
+
+ bool isHovering() { return mHoveredToast != NULL; }
+
void setCanStoreToasts(bool store) { mCanStoreToasts = store; }
void setDisplayToastsAlways(bool display_toasts) { mDisplayToastsAlways = display_toasts; }
@@ -117,7 +118,7 @@ public:
protected:
// Channel's flags
bool mControlHovering;
- bool mIsHovering;
+ LLToast* mHoveredToast;
bool mCanStoreToasts;
bool mDisplayToastsAlways;
bool mOverflowToastHidden;
diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp
index 8c5439d47e..6ca6734598 100644
--- a/indra/newview/llspatialpartition.cpp
+++ b/indra/newview/llspatialpartition.cpp
@@ -435,7 +435,7 @@ void LLSpatialGroup::clearDrawMap()
BOOL LLSpatialGroup::isRecentlyVisible() const
{
- return (LLDrawable::getCurrentFrame() - (S32)mVisible) < LLDrawable::getMinVisFrameRange() ;
+ return (LLDrawable::getCurrentFrame() - mVisible[LLViewerCamera::sCurCameraID]) < LLDrawable::getMinVisFrameRange() ;
}
BOOL LLSpatialGroup::isVisible() const
diff --git a/indra/newview/llsyswellwindow.cpp b/indra/newview/llsyswellwindow.cpp
index 4422c4b672..2fb6550107 100644
--- a/indra/newview/llsyswellwindow.cpp
+++ b/indra/newview/llsyswellwindow.cpp
@@ -501,14 +501,14 @@ LLSysWellWindow::RowPanel::RowPanel(const LLSysWellWindow* parent, const LLUUID&
switch (im_chiclet_type)
{
case LLIMChiclet::TYPE_GROUP:
+ mChiclet = getChild<LLIMGroupChiclet>("group_chiclet");
+ break;
case LLIMChiclet::TYPE_AD_HOC:
- mChiclet = getChild<LLIMChiclet>("group_chiclet");
- childSetVisible("p2p_chiclet", false);
+ mChiclet = getChild<LLAdHocChiclet>("adhoc_chiclet");
break;
case LLIMChiclet::TYPE_UNKNOWN: // assign mChiclet a non-null value anyway
case LLIMChiclet::TYPE_IM:
- mChiclet = getChild<LLIMChiclet>("p2p_chiclet");
- childSetVisible("group_chiclet", false);
+ mChiclet = getChild<LLIMP2PChiclet>("p2p_chiclet");
break;
}
@@ -517,6 +517,7 @@ LLSysWellWindow::RowPanel::RowPanel(const LLSysWellWindow* parent, const LLUUID&
mChiclet->setSessionId(sessionId);
mChiclet->setIMSessionName(name);
mChiclet->setOtherParticipantId(otherParticipantId);
+ mChiclet->setVisible(true);
LLTextBox* contactName = getChild<LLTextBox>("contact_name");
contactName->setValue(name);
diff --git a/indra/newview/llviewerchat.cpp b/indra/newview/llviewerchat.cpp
new file mode 100644
index 0000000000..d65a060bbc
--- /dev/null
+++ b/indra/newview/llviewerchat.cpp
@@ -0,0 +1,203 @@
+/**
+ * @file llviewerchat.cpp
+ * @brief Builds menus out of items.
+ *
+ * $LicenseInfo:firstyear=2002&license=viewergpl$
+ *
+ * Copyright (c) 2002-2009, Linden Research, Inc.
+ *
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab. Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ *
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ *
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ *
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#include "llviewerprecompiledheaders.h"
+#include "llviewerchat.h"
+
+// newview includes
+#include "llagent.h" // gAgent
+#include "lluicolortable.h"
+#include "llviewercontrol.h" // gSavedSettings
+
+// LLViewerChat
+
+//static
+void LLViewerChat::getChatColor(const LLChat& chat, LLColor4& r_color)
+{
+ if(chat.mMuted)
+ {
+ r_color= LLUIColorTable::instance().getColor("LtGray");
+ }
+ else
+ {
+ switch(chat.mSourceType)
+ {
+ case CHAT_SOURCE_SYSTEM:
+ r_color = LLUIColorTable::instance().getColor("SystemChatColor");
+ break;
+ case CHAT_SOURCE_AGENT:
+ if (chat.mFromID.isNull())
+ {
+ r_color = LLUIColorTable::instance().getColor("SystemChatColor");
+ }
+ else
+ {
+ if(gAgentID == chat.mFromID)
+ {
+ r_color = LLUIColorTable::instance().getColor("UserChatColor");
+ }
+ else
+ {
+ r_color = LLUIColorTable::instance().getColor("AgentChatColor");
+ }
+ }
+ break;
+ case CHAT_SOURCE_OBJECT:
+ if (chat.mChatType == CHAT_TYPE_DEBUG_MSG)
+ {
+ r_color = LLUIColorTable::instance().getColor("ScriptErrorColor");
+ }
+ else if ( chat.mChatType == CHAT_TYPE_OWNER )
+ {
+ r_color = LLUIColorTable::instance().getColor("llOwnerSayChatColor");
+ }
+ else
+ {
+ r_color = LLUIColorTable::instance().getColor("ObjectChatColor");
+ }
+ break;
+ default:
+ r_color.setToWhite();
+ }
+
+ if (!chat.mPosAgent.isExactlyZero())
+ {
+ LLVector3 pos_agent = gAgent.getPositionAgent();
+ F32 distance = dist_vec(pos_agent, chat.mPosAgent);
+ if (distance > gAgent.getNearChatRadius())
+ {
+ // diminish far-off chat
+ r_color.mV[VALPHA] = 0.8f;
+ }
+ }
+ }
+}
+
+
+//static
+void LLViewerChat::getChatColor(const LLChat& chat, std::string& r_color_name, F32& r_color_alpha)
+{
+ if(chat.mMuted)
+ {
+ r_color_name = "LtGray";
+ }
+ else
+ {
+ switch(chat.mSourceType)
+ {
+ case CHAT_SOURCE_SYSTEM:
+ r_color_name = "SystemChatColor";
+ break;
+
+ case CHAT_SOURCE_AGENT:
+ if (chat.mFromID.isNull())
+ {
+ r_color_name = "SystemChatColor";
+ }
+ else
+ {
+ if(gAgentID == chat.mFromID)
+ {
+ r_color_name = "UserChatColor";
+ }
+ else
+ {
+ r_color_name = "AgentChatColor";
+ }
+ }
+ break;
+
+ case CHAT_SOURCE_OBJECT:
+ if (chat.mChatType == CHAT_TYPE_DEBUG_MSG)
+ {
+ r_color_name = "ScriptErrorColor";
+ }
+ else if ( chat.mChatType == CHAT_TYPE_OWNER )
+ {
+ r_color_name = "llOwnerSayChatColor";
+ }
+ else
+ {
+ r_color_name = "ObjectChatColor";
+ }
+ break;
+ default:
+ r_color_name = "White";
+ }
+
+ if (!chat.mPosAgent.isExactlyZero())
+ {
+ LLVector3 pos_agent = gAgent.getPositionAgent();
+ F32 distance = dist_vec(pos_agent, chat.mPosAgent);
+ if (distance > gAgent.getNearChatRadius())
+ {
+ // diminish far-off chat
+ r_color_alpha = 0.8f;
+ }
+ else
+ {
+ r_color_alpha = 1.0f;
+ }
+ }
+ }
+
+}
+
+
+//static
+LLFontGL* LLViewerChat::getChatFont()
+{
+ S32 font_size = gSavedSettings.getS32("ChatFontSize");
+ LLFontGL* fontp = NULL;
+ switch(font_size)
+ {
+ case 0:
+ fontp = LLFontGL::getFontSansSerifSmall();
+ break;
+ default:
+ case 1:
+ fontp = LLFontGL::getFontSansSerif();
+ break;
+ case 2:
+ fontp = LLFontGL::getFontSansSerifBig();
+ break;
+ }
+
+ return fontp;
+
+}
+
+//static
+S32 LLViewerChat::getChatFontSize()
+{
+ return gSavedSettings.getS32("ChatFontSize");
+}
diff --git a/indra/newview/llviewerchat.h b/indra/newview/llviewerchat.h
new file mode 100644
index 0000000000..d8840d5dd2
--- /dev/null
+++ b/indra/newview/llviewerchat.h
@@ -0,0 +1,53 @@
+/**
+ * @file llviewerchat.h
+ * @brief wrapper of LLChat in viewer
+ *
+ * $LicenseInfo:firstyear=2002&license=viewergpl$
+ *
+ * Copyright (c) 2002-2009, Linden Research, Inc.
+ *
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab. Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ *
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ *
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ *
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#ifndef LL_LLVIEWERCHAT_H
+#define LL_LLVIEWERCHAT_H
+
+#include "llchat.h"
+#include "llfontgl.h"
+#include "v4color.h"
+
+
+class LLViewerChat
+{
+public:
+ static void getChatColor(const LLChat& chat, LLColor4& r_color);
+ static void getChatColor(const LLChat& chat, std::string& r_color_name, F32& r_color_alpha);
+ static LLFontGL* getChatFont();
+ static S32 getChatFontSize();
+
+
+
+};
+
+#endif
diff --git a/indra/newview/llviewermedia.cpp b/indra/newview/llviewermedia.cpp
index 493457704b..69d4da373e 100644
--- a/indra/newview/llviewermedia.cpp
+++ b/indra/newview/llviewermedia.cpp
@@ -135,9 +135,19 @@ public:
LLMimeDiscoveryResponder( viewer_media_t media_impl)
: mMediaImpl(media_impl),
mInitialized(false)
- {}
-
+ {
+ if(mMediaImpl->mMimeTypeProbe != NULL)
+ {
+ llerrs << "impl already has an outstanding responder" << llendl;
+ }
+
+ mMediaImpl->mMimeTypeProbe = this;
+ }
+ ~LLMimeDiscoveryResponder()
+ {
+ disconnectOwner();
+ }
virtual void completedHeader(U32 status, const std::string& reason, const LLSD& content)
{
@@ -149,23 +159,54 @@ public:
virtual void error( U32 status, const std::string& reason )
{
+ llwarns << "responder failed with status " << status << ", reason " << reason << llendl;
+ if(mMediaImpl)
+ {
+ mMediaImpl->mMediaSourceFailed = true;
+ }
// completeAny(status, "none/none");
}
void completeAny(U32 status, const std::string& mime_type)
{
- if(!mInitialized && ! mime_type.empty())
+ // the call to initializeMedia may disconnect the responder, which will clear mMediaImpl.
+ // Make a local copy so we can call loadURI() afterwards.
+ LLViewerMediaImpl *impl = mMediaImpl;
+
+ if(impl && !mInitialized && ! mime_type.empty())
{
- if(mMediaImpl->initializeMedia(mime_type))
+ if(impl->initializeMedia(mime_type))
{
mInitialized = true;
- mMediaImpl->loadURI();
+ impl->loadURI();
+ disconnectOwner();
}
}
}
+
+ void cancelRequest()
+ {
+ disconnectOwner();
+ }
+
+private:
+ void disconnectOwner()
+ {
+ if(mMediaImpl)
+ {
+ if(mMediaImpl->mMimeTypeProbe != this)
+ {
+ llerrs << "internal error: mMediaImpl->mMimeTypeProbe != this" << llendl;
+ }
- public:
- viewer_media_t mMediaImpl;
+ mMediaImpl->mMimeTypeProbe = NULL;
+ }
+ mMediaImpl = NULL;
+ }
+
+
+public:
+ LLViewerMediaImpl *mMediaImpl;
bool mInitialized;
};
static LLViewerMedia::impl_list sViewerMediaImplList;
@@ -708,6 +749,7 @@ LLViewerMediaImpl::LLViewerMediaImpl( const LLUUID& texture_id,
mIsDisabled(false),
mIsParcelMedia(false),
mProximity(-1),
+ mMimeTypeProbe(NULL),
mIsUpdated(false)
{
@@ -811,7 +853,9 @@ void LLViewerMediaImpl::destroyMediaSource()
{
oldImage->setPlaying(FALSE) ;
}
-
+
+ cancelMimeTypeProbe();
+
if(mMediaSource)
{
delete mMediaSource;
@@ -1316,6 +1360,8 @@ void LLViewerMediaImpl::unload()
//////////////////////////////////////////////////////////////////////////////////////////
void LLViewerMediaImpl::navigateTo(const std::string& url, const std::string& mime_type, bool rediscover_type, bool server_request)
{
+ cancelMimeTypeProbe();
+
if(mMediaURL != url)
{
// Don't carry media play state across distinct URLs.
@@ -1358,6 +1404,12 @@ void LLViewerMediaImpl::navigateInternal()
// Helpful to have media urls in log file. Shouldn't be spammy.
llinfos << "media id= " << mTextureId << " url=" << mMediaURL << " mime_type=" << mMimeType << llendl;
+ if(mMimeTypeProbe != NULL)
+ {
+ llwarns << "MIME type probe already in progress -- bailing out." << llendl;
+ return;
+ }
+
if(mNavigateServerRequest)
{
setNavState(MEDIANAVSTATE_SERVER_SENT);
@@ -1390,7 +1442,7 @@ void LLViewerMediaImpl::navigateInternal()
if(scheme.empty() || "http" == scheme || "https" == scheme)
{
- LLHTTPClient::getHeaderOnly( mMediaURL, new LLMimeDiscoveryResponder(this));
+ LLHTTPClient::getHeaderOnly( mMediaURL, new LLMimeDiscoveryResponder(this), 10.0f);
}
else if("data" == scheme || "file" == scheme || "about" == scheme)
{
@@ -1521,7 +1573,15 @@ void LLViewerMediaImpl::update()
{
if(mMediaSource == NULL)
{
- if(mPriority != LLPluginClassMedia::PRIORITY_UNLOADED)
+ if(mPriority == LLPluginClassMedia::PRIORITY_UNLOADED)
+ {
+ // This media source should not be loaded.
+ }
+ else if(mMimeTypeProbe != NULL)
+ {
+ // this media source is doing a MIME type probe -- don't try loading it again.
+ }
+ else
{
// This media may need to be loaded.
if(sMediaCreateTimer.hasExpired())
@@ -2120,6 +2180,21 @@ void LLViewerMediaImpl::setNavState(EMediaNavState state)
}
}
+void LLViewerMediaImpl::cancelMimeTypeProbe()
+{
+ if(mMimeTypeProbe != NULL)
+ {
+ // There doesn't seem to be a way to actually cancel an outstanding request.
+ // Simulate it by telling the LLMimeDiscoveryResponder not to write back any results.
+ mMimeTypeProbe->cancelRequest();
+
+ // The above should already have set mMimeTypeProbe to NULL.
+ if(mMimeTypeProbe != NULL)
+ {
+ llerrs << "internal error: mMimeTypeProbe is not NULL after cancelling request." << llendl;
+ }
+ }
+}
void LLViewerMediaImpl::addObject(LLVOVolume* obj)
{
diff --git a/indra/newview/llviewermedia.h b/indra/newview/llviewermedia.h
index 3f5f3ca746..719deb28bf 100644
--- a/indra/newview/llviewermedia.h
+++ b/indra/newview/llviewermedia.h
@@ -48,6 +48,7 @@ class LLUUID;
class LLViewerMediaTexture;
class LLMediaEntry;
class LLVOVolume ;
+class LLMimeDiscoveryResponder;
typedef LLPointer<LLViewerMediaImpl> viewer_media_t;
///////////////////////////////////////////////////////////////////////////////
@@ -294,6 +295,7 @@ public:
EMediaNavState getNavState() { return mMediaNavState; }
void setNavState(EMediaNavState state);
+ void cancelMimeTypeProbe();
public:
// a single media url with some data and an impl.
LLPluginClassMedia* mMediaSource;
@@ -331,7 +333,8 @@ public:
bool mIsDisabled;
bool mIsParcelMedia;
S32 mProximity;
-
+ LLMimeDiscoveryResponder *mMimeTypeProbe;
+
private:
BOOL mIsUpdated ;
std::list< LLVOVolume* > mObjectList ;
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index 4088eafe16..1890e0bf1d 100644
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -43,7 +43,7 @@
#include "llfloaterbump.h"
#include "llassetstorage.h"
#include "llcachename.h"
-#include "llchat.h"
+
#include "lldbstrings.h"
#include "lleconomy.h"
#include "llfilepicker.h"
@@ -115,6 +115,7 @@
#include "llui.h" // for make_ui_sound
#include "lluploaddialog.h"
#include "llviewercamera.h"
+#include "llviewerchat.h"
#include "llviewergenericmessage.h"
#include "llviewerinventory.h"
#include "llviewermenu.h"
@@ -2248,7 +2249,7 @@ void process_decline_callingcard(LLMessageSystem* msg, void**)
void process_chat_from_simulator(LLMessageSystem *msg, void **user_data)
{
- LLChat chat;
+ LLChat chat;
std::string mesg;
std::string from_name;
U8 source_temp;
@@ -2848,7 +2849,7 @@ void process_agent_movement_complete(LLMessageSystem* msg, void**)
// Chat the "back" SLURL. (DEV-4907)
LLChat chat("Teleport completed from " + gAgent.getTeleportSourceSLURL());
chat.mSourceType = CHAT_SOURCE_SYSTEM;
- LLFloaterChat::addChatHistory(chat);
+ LLFloaterChat::addChatHistory(chat);
// Set the new position
avatarp->setPositionAgent(agent_pos);
@@ -4620,7 +4621,7 @@ void notify_cautioned_script_question(const LLSD& notification, const LLSD& resp
if (caution)
{
LLChat chat(notice.getString());
- LLFloaterChat::addChat(chat, FALSE, FALSE);
+ // LLFloaterChat::addChat(chat, FALSE, FALSE);
}
}
}
diff --git a/indra/newview/llviewertexture.cpp b/indra/newview/llviewertexture.cpp
index 9923c9ac74..85bc26c9c0 100644
--- a/indra/newview/llviewertexture.cpp
+++ b/indra/newview/llviewertexture.cpp
@@ -206,33 +206,31 @@ LLPointer<LLViewerTexture> LLViewerTextureManager::getLocalTexture(const U32 wid
LLViewerFetchedTexture* LLViewerTextureManager::getFetchedTexture(
const LLUUID &image_id,
BOOL usemipmaps,
- S32 boost_priority,
+ LLViewerTexture::EBoostLevel boost_priority,
S8 texture_type,
LLGLint internal_format,
LLGLenum primary_format,
LLHost request_from_host)
{
- llassert_always(boost_priority >= LLViewerTexture::BOOST_NONE) ;
return gTextureList.getImage(image_id, usemipmaps, boost_priority, texture_type, internal_format, primary_format, request_from_host) ;
}
LLViewerFetchedTexture* LLViewerTextureManager::getFetchedTextureFromFile(
const std::string& filename,
BOOL usemipmaps,
- S32 boost_priority,
+ LLViewerTexture::EBoostLevel boost_priority,
S8 texture_type,
LLGLint internal_format,
LLGLenum primary_format,
const LLUUID& force_id)
{
- llassert_always(boost_priority >= LLViewerTexture::BOOST_NONE) ;
return gTextureList.getImageFromFile(filename, usemipmaps, boost_priority, texture_type, internal_format, primary_format, force_id) ;
}
//static
LLViewerFetchedTexture* LLViewerTextureManager::getFetchedTextureFromUrl(const std::string& url,
BOOL usemipmaps,
- S32 boost_priority,
+ LLViewerTexture::EBoostLevel boost_priority,
S8 texture_type,
LLGLint internal_format,
LLGLenum primary_format,
@@ -1485,9 +1483,8 @@ F32 LLViewerFetchedTexture::calcDecodePriority()
if ( mBoostLevel > BOOST_HIGH)
{
priority += 10000000.f;
- }
-
- if(mAdditionalDecodePriority > 0.0f)
+ }
+ else if(mAdditionalDecodePriority > 0.0f)
{
// 1-9
S32 additional_priority = (S32)(1.0f + mAdditionalDecodePriority*8.0f + .5f); // round
@@ -3147,8 +3144,7 @@ F32 LLViewerMediaTexture::getMaxVirtualSize()
if(mNeedsResetMaxVirtualSize)
{
- mMaxVirtualSize = 0.f ;//reset
- mNeedsResetMaxVirtualSize = FALSE ;
+ addTextureStats(0.f, FALSE) ;//reset
}
if(mIsPlaying) //media is playing
diff --git a/indra/newview/llviewertexture.h b/indra/newview/llviewertexture.h
index bde87d1dd5..141979052d 100644
--- a/indra/newview/llviewertexture.h
+++ b/indra/newview/llviewertexture.h
@@ -107,12 +107,11 @@ public:
enum EBoostLevel
{
- //skip 0 and 1 to avoid mistakenly mixing boost level with boolean numbers.
- BOOST_NONE = 2,
- BOOST_AVATAR_BAKED = 3,
- BOOST_AVATAR = 4,
- BOOST_CLOUDS = 5,
- BOOST_SCULPTED = 6,
+ BOOST_NONE = 0,
+ BOOST_AVATAR_BAKED = 1,
+ BOOST_AVATAR = 2,
+ BOOST_CLOUDS = 3,
+ BOOST_SCULPTED = 4,
BOOST_HIGH = 10,
BOOST_TERRAIN = 11, // has to be high priority for minimap / low detail
@@ -668,7 +667,7 @@ public:
static LLViewerFetchedTexture* getFetchedTexture(const LLUUID &image_id,
BOOL usemipmap = TRUE,
- S32 boost_priority = LLViewerTexture::BOOST_NONE, // Get the requested level immediately upon creation.
+ LLViewerTexture::EBoostLevel boost_priority = LLViewerTexture::BOOST_NONE, // Get the requested level immediately upon creation.
S8 texture_type = LLViewerTexture::FETCHED_TEXTURE,
LLGLint internal_format = 0,
LLGLenum primary_format = 0,
@@ -677,7 +676,7 @@ public:
static LLViewerFetchedTexture* getFetchedTextureFromFile(const std::string& filename,
BOOL usemipmap = TRUE,
- S32 boost_priority = LLViewerTexture::BOOST_NONE,
+ LLViewerTexture::EBoostLevel boost_priority = LLViewerTexture::BOOST_NONE,
S8 texture_type = LLViewerTexture::FETCHED_TEXTURE,
LLGLint internal_format = 0,
LLGLenum primary_format = 0,
@@ -686,7 +685,7 @@ public:
static LLViewerFetchedTexture* getFetchedTextureFromUrl(const std::string& url,
BOOL usemipmap = TRUE,
- S32 boost_priority = LLViewerTexture::BOOST_NONE,
+ LLViewerTexture::EBoostLevel boost_priority = LLViewerTexture::BOOST_NONE,
S8 texture_type = LLViewerTexture::FETCHED_TEXTURE,
LLGLint internal_format = 0,
LLGLenum primary_format = 0,
diff --git a/indra/newview/llviewertexturelist.cpp b/indra/newview/llviewertexturelist.cpp
index 081b7cc483..703a13976c 100644
--- a/indra/newview/llviewertexturelist.cpp
+++ b/indra/newview/llviewertexturelist.cpp
@@ -325,7 +325,7 @@ void LLViewerTextureList::restoreGL()
LLViewerFetchedTexture* LLViewerTextureList::getImageFromFile(const std::string& filename,
BOOL usemipmaps,
- S32 boost_priority,
+ LLViewerTexture::EBoostLevel boost_priority,
S8 texture_type,
LLGLint internal_format,
LLGLenum primary_format,
@@ -345,7 +345,7 @@ LLViewerFetchedTexture* LLViewerTextureList::getImageFromFile(const std::string&
LLViewerFetchedTexture* LLViewerTextureList::getImageFromUrl(const std::string& url,
BOOL usemipmaps,
- S32 boost_priority,
+ LLViewerTexture::EBoostLevel boost_priority,
S8 texture_type,
LLGLint internal_format,
LLGLenum primary_format,
@@ -411,7 +411,7 @@ LLViewerFetchedTexture* LLViewerTextureList::getImageFromUrl(const std::string&
LLViewerFetchedTexture* LLViewerTextureList::getImage(const LLUUID &image_id,
BOOL usemipmaps,
- S32 boost_priority,
+ LLViewerTexture::EBoostLevel boost_priority,
S8 texture_type,
LLGLint internal_format,
LLGLenum primary_format,
@@ -441,7 +441,7 @@ LLViewerFetchedTexture* LLViewerTextureList::getImage(const LLUUID &image_id,
//when this function is called, there is no such texture in the gTextureList with image_id.
LLViewerFetchedTexture* LLViewerTextureList::createImage(const LLUUID &image_id,
BOOL usemipmaps,
- S32 boost_priority,
+ LLViewerTexture::EBoostLevel boost_priority,
S8 texture_type,
LLGLint internal_format,
LLGLenum primary_format,
@@ -1346,7 +1346,7 @@ LLUIImagePtr LLUIImageList::getUIImageByID(const LLUUID& image_id, S32 priority)
const BOOL use_mips = FALSE;
const LLRect scale_rect = LLRect::null;
- return loadUIImageByID(image_id, use_mips, scale_rect, priority);
+ return loadUIImageByID(image_id, use_mips, scale_rect, (LLViewerTexture::EBoostLevel)priority);
}
LLUIImagePtr LLUIImageList::getUIImage(const std::string& image_name, S32 priority)
@@ -1360,21 +1360,27 @@ LLUIImagePtr LLUIImageList::getUIImage(const std::string& image_name, S32 priori
const BOOL use_mips = FALSE;
const LLRect scale_rect = LLRect::null;
- return loadUIImageByName(image_name, image_name, use_mips, scale_rect, priority);
+ return loadUIImageByName(image_name, image_name, use_mips, scale_rect, (LLViewerTexture::EBoostLevel)priority);
}
LLUIImagePtr LLUIImageList::loadUIImageByName(const std::string& name, const std::string& filename,
- BOOL use_mips, const LLRect& scale_rect, S32 boost_priority )
+ BOOL use_mips, const LLRect& scale_rect, LLViewerTexture::EBoostLevel boost_priority )
{
- if (boost_priority == 0) boost_priority = LLViewerFetchedTexture::BOOST_UI;
+ if (boost_priority == LLViewerTexture::BOOST_NONE)
+ {
+ boost_priority = LLViewerTexture::BOOST_UI;
+ }
LLViewerFetchedTexture* imagep = LLViewerTextureManager::getFetchedTextureFromFile(filename, MIPMAP_NO, boost_priority);
return loadUIImage(imagep, name, use_mips, scale_rect);
}
LLUIImagePtr LLUIImageList::loadUIImageByID(const LLUUID& id,
- BOOL use_mips, const LLRect& scale_rect, S32 boost_priority)
+ BOOL use_mips, const LLRect& scale_rect, LLViewerTexture::EBoostLevel boost_priority)
{
- if (boost_priority == 0) boost_priority = LLViewerFetchedTexture::BOOST_UI;
+ if (boost_priority == LLViewerTexture::BOOST_NONE)
+ {
+ boost_priority = LLViewerTexture::BOOST_UI;
+ }
LLViewerFetchedTexture* imagep = LLViewerTextureManager::getFetchedTexture(id, MIPMAP_NO, boost_priority);
return loadUIImage(imagep, id.asString(), use_mips, scale_rect);
}
diff --git a/indra/newview/llviewertexturelist.h b/indra/newview/llviewertexturelist.h
index 3c9c81a689..028f8441ab 100644
--- a/indra/newview/llviewertexturelist.h
+++ b/indra/newview/llviewertexturelist.h
@@ -130,7 +130,7 @@ private:
LLViewerFetchedTexture * getImage(const LLUUID &image_id,
BOOL usemipmap = TRUE,
- S32 boost_priority = LLViewerTexture::BOOST_NONE, // Get the requested level immediately upon creation.
+ LLViewerTexture::EBoostLevel boost_priority = LLViewerTexture::BOOST_NONE, // Get the requested level immediately upon creation.
S8 texture_type = LLViewerTexture::FETCHED_TEXTURE,
LLGLint internal_format = 0,
LLGLenum primary_format = 0,
@@ -139,7 +139,7 @@ private:
LLViewerFetchedTexture * getImageFromFile(const std::string& filename,
BOOL usemipmap = TRUE,
- S32 boost_priority = LLViewerTexture::BOOST_NONE, // Get the requested level immediately upon creation.
+ LLViewerTexture::EBoostLevel boost_priority = LLViewerTexture::BOOST_NONE, // Get the requested level immediately upon creation.
S8 texture_type = LLViewerTexture::FETCHED_TEXTURE,
LLGLint internal_format = 0,
LLGLenum primary_format = 0,
@@ -148,7 +148,7 @@ private:
LLViewerFetchedTexture* getImageFromUrl(const std::string& url,
BOOL usemipmap = TRUE,
- BOOL level_immediate = FALSE, // Get the requested level immediately upon creation.
+ LLViewerTexture::EBoostLevel boost_priority = LLViewerTexture::BOOST_NONE, // Get the requested level immediately upon creation.
S8 texture_type = LLViewerTexture::FETCHED_TEXTURE,
LLGLint internal_format = 0,
LLGLenum primary_format = 0,
@@ -157,7 +157,7 @@ private:
LLViewerFetchedTexture* createImage(const LLUUID &image_id,
BOOL usemipmap = TRUE,
- S32 boost_priority = LLViewerTexture::BOOST_NONE, // Get the requested level immediately upon creation.
+ LLViewerTexture::EBoostLevel boost_priority = LLViewerTexture::BOOST_NONE, // Get the requested level immediately upon creation.
S8 texture_type = LLViewerTexture::FETCHED_TEXTURE,
LLGLint internal_format = 0,
LLGLenum primary_format = 0,
@@ -228,9 +228,11 @@ public:
static void onUIImageLoaded( BOOL success, LLViewerFetchedTexture *src_vi, LLImageRaw* src, LLImageRaw* src_aux, S32 discard_level, BOOL final, void* userdata );
private:
LLUIImagePtr loadUIImageByName(const std::string& name, const std::string& filename,
- BOOL use_mips = FALSE, const LLRect& scale_rect = LLRect::null, S32 boost_priority = 0);
+ BOOL use_mips = FALSE, const LLRect& scale_rect = LLRect::null,
+ LLViewerTexture::EBoostLevel boost_priority = LLViewerTexture::BOOST_UI);
LLUIImagePtr loadUIImageByID(const LLUUID& id,
- BOOL use_mips = FALSE, const LLRect& scale_rect = LLRect::null, S32 boost_priority = 0);
+ BOOL use_mips = FALSE, const LLRect& scale_rect = LLRect::null,
+ LLViewerTexture::EBoostLevel boost_priority = LLViewerTexture::BOOST_UI);
LLUIImagePtr loadUIImage(LLViewerFetchedTexture* imagep, const std::string& name, BOOL use_mips = FALSE, const LLRect& scale_rect = LLRect::null);
diff --git a/indra/newview/llworldmipmap.cpp b/indra/newview/llworldmipmap.cpp
index 8d3165b98c..9897f40c4e 100644
--- a/indra/newview/llworldmipmap.cpp
+++ b/indra/newview/llworldmipmap.cpp
@@ -196,7 +196,7 @@ LLPointer<LLViewerFetchedTexture> LLWorldMipmap::loadObjectsTile(U32 grid_x, U32
// END DEBUG
//LL_INFOS("World Map") << "LLWorldMipmap::loadObjectsTile(), URL = " << imageurl << LL_ENDL;
- LLPointer<LLViewerFetchedTexture> img = LLViewerTextureManager::getFetchedTextureFromUrl(imageurl, TRUE, FALSE, LLViewerTexture::LOD_TEXTURE);
+ LLPointer<LLViewerFetchedTexture> img = LLViewerTextureManager::getFetchedTextureFromUrl(imageurl, TRUE, LLViewerTexture::BOOST_NONE, LLViewerTexture::LOD_TEXTURE);
img->setBoostLevel(LLViewerTexture::BOOST_MAP);
// Return the smart pointer
diff --git a/indra/newview/skins/default/xui/en/floater_camera.xml b/indra/newview/skins/default/xui/en/floater_camera.xml
index 5c09bc3a02..2af451400e 100644
--- a/indra/newview/skins/default/xui/en/floater_camera.xml
+++ b/indra/newview/skins/default/xui/en/floater_camera.xml
@@ -49,22 +49,57 @@
top="22"
visible="false"
width="78" />
- <!--TODO: replace with slider, + - images -->
- <joystick_zoom
- follows="top|left"
- height="78"
- image_unselected="ScrollThumb_Vert"
- layout="topleft"
- left="7"
- minus_image="ScrollThumb_Vert"
- name="zoom"
- plus_image="ScrollThumb_Vert"
- quadrant="left"
- scale_image="false"
- sound_flags="3"
- tool_tip="Zoom camera toward focus"
- top="22"
- width="20" />
+ <!--TODO: replace + - images -->
+ <panel
+ border="false"
+ class="camera_zoom_panel"
+ height="94"
+ layout="topleft"
+ left="7"
+ mouse_opaque="false"
+ name="zoom"
+ top="22"
+ width="18">
+ <button
+ follows="top|left"
+ height="18"
+ image_disabled="AddItem_Disabled"
+ image_selected="AddItem_Press"
+ image_unselected="AddItem_Off"
+ layout="topleft"
+ name="zoom_plus_btn"
+ width="18">
+ <commit_callback
+ function="Zoom.plus" />
+ <mouse_held_callback
+ function="Zoom.plus" />
+ </button>
+ <slider_bar
+ height="48"
+ layout="topleft"
+ name="zoom_slider"
+ orientation="vertical"
+ tool_tip="Zoom camera toward focus"
+ top_pad="0"
+ width="18">
+ <commit_callback function="Slider.value_changed"/>
+ </slider_bar>
+ <button
+ follows="top|left"
+ height="18"
+ image_disabled="AddItem_Disabled"
+ image_selected="AddItem_Press"
+ image_unselected="AddItem_Off"
+ layout="topleft"
+ name="zoom_minus_btn"
+ top_pad="0"
+ width="18">
+ <commit_callback
+ function="Zoom.minus" />
+ <mouse_held_callback
+ function="Zoom.minus" />
+ </button>
+ </panel>
<joystick_rotate
follows="top|left"
height="78"
@@ -80,7 +115,7 @@
tool_tip="Orbit camera around focus"
top="22"
width="78" />
- <panel
+ <panel
height="78"
layout="topleft"
left="36"
diff --git a/indra/newview/skins/default/xui/en/floater_test_slider.xml b/indra/newview/skins/default/xui/en/floater_test_slider.xml
index 57d8e686ce..86ff82e01f 100644
--- a/indra/newview/skins/default/xui/en/floater_test_slider.xml
+++ b/indra/newview/skins/default/xui/en/floater_test_slider.xml
@@ -57,6 +57,13 @@
width="200" />
<slider_bar
bottom="320"
+ height="100"
+ left="20"
+ name="slider_bar_vertical"
+ orientation="vertical"
+ width="20" />
+ <slider_bar
+ bottom="300"
height="20"
increment="1"
initial_value="2.0"
@@ -64,6 +71,7 @@
layout="topleft"
max_val="5"
min_val="1"
+ left_pad="20"
name="slider_bar"
width="300" />
<slider
diff --git a/indra/newview/skins/default/xui/en/floater_tools.xml b/indra/newview/skins/default/xui/en/floater_tools.xml
index c33d7cf31d..b2f46bc433 100644
--- a/indra/newview/skins/default/xui/en/floater_tools.xml
+++ b/indra/newview/skins/default/xui/en/floater_tools.xml
@@ -262,6 +262,18 @@
<check_box.commit_callback
function="BuildTool.selectComponent"/>
</check_box>
+
+ <text
+ text_color="LtGray_50"
+ follows="top|left"
+ halign="left"
+ left="13"
+ name="RenderingCost"
+ top_pad="9"
+ type="string"
+ width="100">
+ รพ: [COUNT]
+ </text>
<check_box
control_name="ScaleUniform"
height="19"
@@ -325,7 +337,7 @@
<button.commit_callback
function="BuildTool.gridOptions"/>
</button>
- <button
+ <button
follows="left|top"
height="20"
image_disabled="Object_Cube"
@@ -701,6 +713,7 @@
function="BuildTool.applyToSelection"/>
</button>
<text
+ text_color="LtGray_50"
type="string"
length="1"
height="12"
@@ -714,6 +727,7 @@
Objects: [COUNT]
</text>
<text
+ text_color="LtGray_50"
type="string"
length="1"
follows="left|top"
@@ -730,7 +744,7 @@
halign="center"
left="0"
name="Object Info Tabs"
- tab_max_width="55"
+ tab_max_width="54"
tab_min_width="40"
tab_position="top"
tab_height="25"
diff --git a/indra/newview/skins/default/xui/en/floater_tos.xml b/indra/newview/skins/default/xui/en/floater_tos.xml
index 4e2cce1428..1adb824e2a 100644
--- a/indra/newview/skins/default/xui/en/floater_tos.xml
+++ b/indra/newview/skins/default/xui/en/floater_tos.xml
@@ -53,22 +53,6 @@
Please read the following Terms of Service carefully. To continue logging in to [SECOND_LIFE],
you must accept the agreement.
</text>
- <text_editor
- type="string"
- length="1"
- follows="left|top"
- font="SansSerif"
- height="283"
- layout="topleft"
- left_delta="0"
- max_length="65536"
- name="tos_text"
- top_pad="43"
- width="568"
- handle_edit_keys_directly="true"
- word_wrap="true">
- TOS_TEXT
- </text_editor>
<web_browser
follows="left|top"
height="340"
@@ -76,6 +60,6 @@ you must accept the agreement.
left_delta="0"
name="tos_html"
start_url="data:text/html,%3Chtml%3E%3Chead%3E%3C/head%3E%3Cbody text=%22000000%22%3E%3Ch2%3E Loading %3Ca%20target%3D%22_external%22%20href%3D%22http%3A//secondlife.com/app/tos/%22%3ETerms%20of%20Service%3C/a%3E...%3C/h2%3E %3C/body%3E %3C/html%3E"
- top_delta="-27"
+ top_delta="0"
width="568" />
</floater>
diff --git a/indra/newview/skins/default/xui/en/panel_activeim_row.xml b/indra/newview/skins/default/xui/en/panel_activeim_row.xml
index 8b815b0f71..5562ec8406 100644
--- a/indra/newview/skins/default/xui/en/panel_activeim_row.xml
+++ b/indra/newview/skins/default/xui/en/panel_activeim_row.xml
@@ -15,7 +15,16 @@
top="3"
left="5"
height="25"
- width="25">
+ width="25"
+ visible="false"
+ speaker.name="speaker_p2p"
+ speaker.width="20"
+ speaker.height="25"
+ speaker.left="25"
+ speaker.top="25"
+ speaker.auto_update="true"
+ speaker.draw_border="false"
+ speaker.visible="false">
</chiclet_im_p2p>
<chiclet_im_group
name="group_chiclet"
@@ -24,14 +33,41 @@
top="3"
left="5"
height="25"
- width="25">
+ width="25"
+ visible="false"
+ speaker.name="speaker_grp"
+ speaker.width="20"
+ speaker.height="25"
+ speaker.left="25"
+ speaker.top="25"
+ speaker.auto_update="true"
+ speaker.draw_border="false"
+ speaker.visible="false">
</chiclet_im_group>
+ <chiclet_im_adhoc
+ name="adhoc_chiclet"
+ layout="topleft"
+ follows="left"
+ top="3"
+ left="5"
+ height="25"
+ width="25"
+ visible="false"
+ speaker.name="speaker_hoc"
+ speaker.width="20"
+ speaker.height="25"
+ speaker.left="25"
+ speaker.top="25"
+ speaker.auto_update="true"
+ speaker.draw_border="false"
+ speaker.visible="false">
+ </chiclet_im_adhoc>
<text
type="string"
name="contact_name"
layout="topleft"
top="10"
- left_pad="0"
+ left_pad="20"
height="14"
width="245"
length="1"
diff --git a/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml b/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml
index 1ef845b769..a77094e942 100644
--- a/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml
+++ b/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml
@@ -27,7 +27,7 @@
name="chat_box"
tool_tip="Press Enter to say, Ctrl+Enter to shout"
top="0"
- width="250" />
+ width="279" />
<output_monitor
auto_update="true"
follows="right"
diff --git a/indra/newview/skins/default/xui/en/panel_sidetray_home_tab.xml b/indra/newview/skins/default/xui/en/panel_sidetray_home_tab.xml
index 9636e32187..566fc95230 100644
--- a/indra/newview/skins/default/xui/en/panel_sidetray_home_tab.xml
+++ b/indra/newview/skins/default/xui/en/panel_sidetray_home_tab.xml
@@ -227,7 +227,7 @@
right="-10"
top="10"
width="20"
- image_name="TabIcon_Inventory_Selected"/>
+ image_name="TabIcon_Things_Selected"/>
<text
follows="all"
height="90"
diff --git a/indra/newview/skins/default/xui/en/panel_toast.xml b/indra/newview/skins/default/xui/en/panel_toast.xml
index 7f7777586c..f16329f8d7 100644
--- a/indra/newview/skins/default/xui/en/panel_toast.xml
+++ b/indra/newview/skins/default/xui/en/panel_toast.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<!-- All our XML is utf-8 encoded. -->
-<!-- All this does is establish the position of the "close" button on the toast. -->
+<!-- Don't remove floater's height! It is needed for Overflow and Start-Up toasts!-->
<floater
legacy_header_height="18"
@@ -9,6 +9,7 @@
title=""
visible="false"
layout="topleft"
+ height="40"
width="305"
left="0"
top="0"
@@ -26,36 +27,21 @@
drop_shadow_visible = "false"
border = "false"
>
-
- <!--
+ <!-- Don't remove this wiget! It is needed for Overflow and Start-Up toasts!-->
<text
visible="false"
follows="left|top|right|bottom"
font="SansSerifBold"
- height="40"
+ height="20"
layout="topleft"
- left="60"
+ left="20"
name="toast_text"
word_wrap="true"
text_color="white"
- top="20"
- width="290">
+ top="5"
+ width="260">
Toast text;
</text>
- <icon
- top="20"
- left="10"
- width="32"
- height="32"
- follows="top|left"
- layout="topleft"
- visible="false"
- color="1 1 1 1"
- enabled="true"
- image_name="notify_tip_icon.tga"
- mouse_opaque="true"
- name="icon"
- />-->
<button
layout="topleft"
top="-6"
diff --git a/indra/newview/skins/default/xui/en/widgets/slider_bar.xml b/indra/newview/skins/default/xui/en/widgets/slider_bar.xml
index bc1ca339a2..706c89f5ed 100644
--- a/indra/newview/skins/default/xui/en/widgets/slider_bar.xml
+++ b/indra/newview/skins/default/xui/en/widgets/slider_bar.xml
@@ -4,6 +4,8 @@
thumb_center_color="SliderThumbCenterColor"
thumb_image="SliderThumb_Off"
thumb_image_pressed="SliderThumb_Press"
- thumb_image_disabled="SliderThumb_Disabled"
- track_image="SliderTrack_Horiz"
- track_highlight_image="SliderTrack_Horiz" />
+ thumb_image_disabled="SliderThumb_Disabled"
+ track_image_horizontal="SliderTrack_Horiz"
+ track_image_vertical="SliderTrack_Vert"
+ track_highlight_horizontal_image="SliderTrack_Horiz"
+ track_highlight_vertical_image="SliderTrack_Vert" />
diff --git a/indra/viewer_components/login/tests/lllogin_test.cpp b/indra/viewer_components/login/tests/lllogin_test.cpp
index 56c21016bd..99ea796ad0 100644
--- a/indra/viewer_components/login/tests/lllogin_test.cpp
+++ b/indra/viewer_components/login/tests/lllogin_test.cpp
@@ -416,6 +416,7 @@ namespace tut
ensure_equals("Failed to offline", listener.lastEvent()["state"].asString(), "offline");
}
+/*
template<> template<>
void llviewerlogin_object::test<5>()
{
@@ -451,4 +452,5 @@ namespace tut
ensure_equals("SRV Failure", listener.lastEvent()["change"].asString(), "fail.login");
}
+*/
}