summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/contributions.txt4
-rw-r--r--indra/llrender/llfontgl.cpp31
-rw-r--r--indra/llrender/llfontgl.h3
-rw-r--r--indra/llui/llbutton.cpp2
-rw-r--r--indra/llui/lldraghandle.cpp1
-rw-r--r--indra/llui/llfloater.cpp10
-rw-r--r--indra/llui/llmenugl.cpp4
-rw-r--r--indra/llui/lltextbox.cpp16
-rw-r--r--indra/llui/lltextbox.h4
-rw-r--r--indra/llwindow/llwindowwin32.cpp4
-rw-r--r--indra/newview/llfloatertos.cpp1
-rw-r--r--indra/newview/llnetmap.cpp2
-rw-r--r--indra/newview/llpanelcontents.cpp6
-rw-r--r--indra/newview/llpreviewscript.cpp2
-rw-r--r--indra/newview/llviewermessage.cpp17
-rw-r--r--indra/newview/llviewerwindow.cpp2
-rw-r--r--indra/newview/llworldmapview.cpp1
-rw-r--r--indra/test/llhttpclient_tut.cpp7
-rw-r--r--indra/test/lltut.cpp12
19 files changed, 87 insertions, 42 deletions
diff --git a/doc/contributions.txt b/doc/contributions.txt
index ed9b2fe146..9bdc25b1ee 100644
--- a/doc/contributions.txt
+++ b/doc/contributions.txt
@@ -4,7 +4,7 @@ along with the issue identifier corresponding to the patches we've
received from them. To see more about these contributions, visit
http://jira.secondlife.com/ and enter the issue identifier.
-Alissa Sabre - VWR-81, VWR-83, VWR-414
+Alissa Sabre - VWR-81, VWR-83, VWR-414, VWR-415
blino Nakamura - VWR-17
bushing Spatula - VWR-424
Drewan Keats - VWR-28
@@ -22,7 +22,7 @@ Kunnis Basiat - VWR-82
Paul Churchill - VWR-20
Paula Innis - VWR-30
Peekay Semyorka - VWR-7, VWR-19, VWR-49
-SignpostMarv Martin - VWR-155
+SignpostMarv Martin - VWR-154, VWR-155
SpacedOut Frye - VWR-57, VWR-94, VWR-121, VWR-123
Strife Onizuka - SVC-9, VWR-74, VWR-85, VWR-148
Zipherius Turas - VWR-76, VWR-77
diff --git a/indra/llrender/llfontgl.cpp b/indra/llrender/llfontgl.cpp
index 73459facc9..f9b7345048 100644
--- a/indra/llrender/llfontgl.cpp
+++ b/indra/llrender/llfontgl.cpp
@@ -50,7 +50,7 @@ const F32 PIXEL_BORDER_THRESHOLD = 0.0001f;
const F32 PIXEL_CORRECTION_DISTANCE = 0.01f;
const F32 PAD_AMT = 0.5f;
-const F32 DROP_SHADOW_STRENGTH = 0.3f;
+const F32 DROP_SHADOW_SOFT_STRENGTH = 0.3f;
F32 llfont_round_x(F32 x)
{
@@ -86,6 +86,14 @@ U8 LLFontGL::getStyleFromString(const LLString &style)
{
ret |= UNDERLINE;
}
+ if (style.find("SHADOW") != style.npos)
+ {
+ ret |= DROP_SHADOW;
+ }
+ if (style.find("SOFT_SHADOW") != style.npos)
+ {
+ ret |= DROP_SHADOW_SOFT;
+ }
return ret;
}
@@ -551,14 +559,14 @@ S32 LLFontGL::render(const LLWString &wstr,
}
F32 drop_shadow_strength = 0.f;
- if (style & DROP_SHADOW)
+ if (style & (DROP_SHADOW | DROP_SHADOW_SOFT))
{
F32 luminance;
color.calcHSL(NULL, NULL, &luminance);
- drop_shadow_strength = clamp_rescale(luminance, 0.35f, 0.6f, 0.f, DROP_SHADOW_STRENGTH);
+ drop_shadow_strength = clamp_rescale(luminance, 0.35f, 0.6f, 0.f, 1.f);
if (luminance < 0.35f)
{
- style = style & ~DROP_SHADOW;
+ style = style & ~(DROP_SHADOW | DROP_SHADOW_SOFT);
}
}
@@ -1315,10 +1323,10 @@ void LLFontGL::drawGlyph(const LLRectf& screen_rect, const LLRectf& uv_rect, con
renderQuad(screen_rect_offset, uv_rect, slant_offset);
}
}
- else if (style & DROP_SHADOW)
+ else if (style & DROP_SHADOW_SOFT)
{
LLColor4 shadow_color = LLFontGL::sShadowColor;
- shadow_color.mV[VALPHA] = color.mV[VALPHA] * drop_shadow_strength;
+ shadow_color.mV[VALPHA] = color.mV[VALPHA] * drop_shadow_strength * DROP_SHADOW_SOFT_STRENGTH;
glColor4fv(shadow_color.mV);
for (S32 pass = 0; pass < 5; pass++)
{
@@ -1348,6 +1356,17 @@ void LLFontGL::drawGlyph(const LLRectf& screen_rect, const LLRectf& uv_rect, con
glColor4fv(color.mV);
renderQuad(screen_rect, uv_rect, slant_offset);
}
+ else if (style & DROP_SHADOW)
+ {
+ LLColor4 shadow_color = LLFontGL::sShadowColor;
+ shadow_color.mV[VALPHA] = color.mV[VALPHA] * drop_shadow_strength;
+ glColor4fv(shadow_color.mV);
+ LLRectf screen_rect_shadow = screen_rect;
+ screen_rect_shadow.translate(1.f, -1.f);
+ renderQuad(screen_rect_shadow, uv_rect, slant_offset);
+ glColor4fv(color.mV);
+ renderQuad(screen_rect, uv_rect, slant_offset);
+ }
else // normal rendering
{
glColor4fv(color.mV);
diff --git a/indra/llrender/llfontgl.h b/indra/llrender/llfontgl.h
index 75e12f0475..28ff5f6681 100644
--- a/indra/llrender/llfontgl.h
+++ b/indra/llrender/llfontgl.h
@@ -45,7 +45,8 @@ public:
BOLD = 1,
ITALIC = 2,
UNDERLINE = 4,
- DROP_SHADOW = 8
+ DROP_SHADOW = 8,
+ DROP_SHADOW_SOFT = 16
};
// Takes a string with potentially several flags, i.e. "NORMAL|BOLD|ITALIC"
diff --git a/indra/llui/llbutton.cpp b/indra/llui/llbutton.cpp
index 9f66daf890..ddd81e77b3 100644
--- a/indra/llui/llbutton.cpp
+++ b/indra/llui/llbutton.cpp
@@ -628,7 +628,7 @@ void LLButton::draw()
mGLFont->render(label, 0, (F32)x, (F32)(LLBUTTON_V_PAD + y_offset),
label_color,
mHAlign, LLFontGL::BOTTOM,
- mDropShadowedText ? LLFontGL::DROP_SHADOW : LLFontGL::NORMAL,
+ mDropShadowedText ? LLFontGL::DROP_SHADOW_SOFT : LLFontGL::NORMAL,
U32_MAX, drawable_width,
NULL, FALSE, FALSE);
}
diff --git a/indra/llui/lldraghandle.cpp b/indra/llui/lldraghandle.cpp
index 599a85021b..25b41e44e1 100644
--- a/indra/llui/lldraghandle.cpp
+++ b/indra/llui/lldraghandle.cpp
@@ -102,6 +102,7 @@ void LLDragHandleTop::setTitle(const LLString& title)
const LLFontGL* font = gResMgr->getRes( LLFONT_SANSSERIF );
mTitleBox = new LLTextBox( "Drag Handle Title", mRect, trimmed_title, font );
mTitleBox->setFollows(FOLLOWS_TOP | FOLLOWS_LEFT | FOLLOWS_RIGHT);
+ mTitleBox->setFontStyle(LLFontGL::DROP_SHADOW_SOFT);
reshapeTitleBox();
// allow empty titles, as default behavior replaces them with title box name
diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp
index 40c11c69cc..3da53275c7 100644
--- a/indra/llui/llfloater.cpp
+++ b/indra/llui/llfloater.cpp
@@ -1919,7 +1919,11 @@ void LLFloaterView::bringToFront(LLFloater* child, BOOL give_focus)
LLFloater* floaterp = (LLFloater*)(*view_it);
sendChildToFront(floaterp);
- floaterp->setMinimized(FALSE);
+ // always unminimize dependee, but allow dependents to stay minimized
+ if (!floaterp->isDependent())
+ {
+ floaterp->setMinimized(FALSE);
+ }
}
floaters_to_move.clear();
@@ -1931,7 +1935,9 @@ void LLFloaterView::bringToFront(LLFloater* child, BOOL give_focus)
if (dependent)
{
sendChildToFront(dependent);
- dependent->setMinimized(FALSE);
+ //don't un-minimize dependent windows automatically
+ // respect user's wishes
+ //dependent->setMinimized(FALSE);
}
++dependent_it;
}
diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp
index f5dcae5787..2cae50bd04 100644
--- a/indra/llui/llmenugl.cpp
+++ b/indra/llui/llmenugl.cpp
@@ -497,7 +497,7 @@ void LLMenuItemGL::draw( void )
U8 font_style = mStyle;
if (LLMenuItemGL::sDropShadowText && getEnabled() && !mDrawTextDisabled )
{
- font_style |= LLFontGL::DROP_SHADOW;
+ font_style |= LLFontGL::DROP_SHADOW_SOFT;
}
if ( getEnabled() && getHighlight() )
@@ -1728,7 +1728,7 @@ void LLMenuItemBranchDownGL::draw( void )
U8 font_style = mStyle;
if (LLMenuItemGL::sDropShadowText && getEnabled() && !mDrawTextDisabled )
{
- font_style |= LLFontGL::DROP_SHADOW;
+ font_style |= LLFontGL::DROP_SHADOW_SOFT;
}
LLColor4 color;
diff --git a/indra/llui/lltextbox.cpp b/indra/llui/lltextbox.cpp
index 2afa32eccd..48ff6afbd5 100644
--- a/indra/llui/lltextbox.cpp
+++ b/indra/llui/lltextbox.cpp
@@ -28,7 +28,7 @@ LLTextBox::LLTextBox(const LLString& name, const LLRect& rect, const LLString& t
mBorderColor( LLUI::sColorsGroup->getColor( "DefaultHighlightLight" ) ),
mBackgroundVisible( FALSE ),
mBorderVisible( FALSE ),
- mDropshadowVisible( TRUE ),
+ mFontStyle(LLFontGL::DROP_SHADOW_SOFT),
mBorderDropShadowVisible( FALSE ),
mHPad(0),
mVPad(0),
@@ -53,7 +53,7 @@ LLTextBox::LLTextBox(const LLString& name, const LLString& text, F32 max_width,
mBorderColor(LLUI::sColorsGroup->getColor("DefaultHighlightLight")),
mBackgroundVisible(FALSE),
mBorderVisible(FALSE),
- mDropshadowVisible(TRUE),
+ mFontStyle(LLFontGL::DROP_SHADOW_SOFT),
mBorderDropShadowVisible(FALSE),
mHPad(0),
mVPad(0),
@@ -343,7 +343,7 @@ void LLTextBox::drawText( S32 x, S32 y, const LLColor4& color )
S32 line_length = *iter;
mFontGL->render(mText.getWString(), cur_pos, (F32)x, (F32)y, color,
mHAlign, mVAlign,
- mDropshadowVisible ? LLFontGL::DROP_SHADOW : LLFontGL::NORMAL,
+ mFontStyle,
line_length, mRect.getWidth(), NULL, TRUE );
cur_pos += line_length + 1;
y -= llfloor(mFontGL->getLineHeight());
@@ -353,7 +353,7 @@ void LLTextBox::drawText( S32 x, S32 y, const LLColor4& color )
{
mFontGL->render(mText.getWString(), 0, (F32)x, (F32)y, color,
mHAlign, mVAlign,
- mDropshadowVisible ? LLFontGL::DROP_SHADOW : LLFontGL::NORMAL,
+ mFontStyle,
S32_MAX, mRect.getWidth(), NULL, TRUE);
}
}
@@ -386,8 +386,6 @@ LLXMLNodePtr LLTextBox::getXML(bool save_children) const
node->createChild("border_visible", TRUE)->setBoolValue(mBorderVisible);
- node->createChild("drop_shadow_visible", TRUE)->setBoolValue(mDropshadowVisible);
-
node->createChild("border_drop_shadow_visible", TRUE)->setBoolValue(mBorderDropShadowVisible);
node->createChild("h_pad", TRUE)->setIntValue(mHPad);
@@ -427,6 +425,12 @@ LLView* LLTextBox::fromXML(LLXMLNodePtr node, LLView *parent, LLUICtrlFactory *f
text_box->initFromXML(node, parent);
+ LLString font_style;
+ if (node->getAttributeString("font-style", font_style))
+ {
+ text_box->mFontStyle = LLFontGL::getStyleFromString(font_style);
+ }
+
if(node->hasAttribute("text_color"))
{
LLColor4 color;
diff --git a/indra/llui/lltextbox.h b/indra/llui/lltextbox.h
index 56c00eb8b3..8972450c30 100644
--- a/indra/llui/lltextbox.h
+++ b/indra/llui/lltextbox.h
@@ -54,7 +54,7 @@ public:
void setBackgroundVisible(BOOL visible) { mBackgroundVisible = visible; }
void setBorderVisible(BOOL visible) { mBorderVisible = visible; }
- void setDropshadowVisible(BOOL visible) { mDropshadowVisible = visible; }
+ void setFontStyle(U8 style) { mFontStyle = style; }
void setBorderDropshadowVisible(BOOL visible){ mBorderDropShadowVisible = visible; }
void setHPad(S32 pixels) { mHPad = pixels; }
void setVPad(S32 pixels) { mVPad = pixels; }
@@ -92,7 +92,7 @@ protected:
BOOL mBackgroundVisible;
BOOL mBorderVisible;
- BOOL mDropshadowVisible; // Draws black dropshadow below and to the right of the text.
+ U8 mFontStyle; // style bit flags for font
BOOL mBorderDropShadowVisible;
S32 mHPad;
diff --git a/indra/llwindow/llwindowwin32.cpp b/indra/llwindow/llwindowwin32.cpp
index a589bf29f9..e6bce27ce2 100644
--- a/indra/llwindow/llwindowwin32.cpp
+++ b/indra/llwindow/llwindowwin32.cpp
@@ -34,8 +34,12 @@
#include "indra_constants.h"
// culled from winuser.h
+#ifndef WM_MOUSEWHEEL /* Added to be compatible with later SDK's */
const S32 WM_MOUSEWHEEL = 0x020A;
+#endif
+#ifndef WHEEL_DELTA /* Added to be compatible with later SDK's */
const S32 WHEEL_DELTA = 120; /* Value for rolling one detent */
+#endif
const S32 MAX_MESSAGE_PER_UPDATE = 20;
const S32 BITS_PER_PIXEL = 32;
const S32 MAX_NUM_RESOLUTIONS = 32;
diff --git a/indra/newview/llfloatertos.cpp b/indra/newview/llfloatertos.cpp
index b71772bd93..f7bf4de34f 100644
--- a/indra/newview/llfloatertos.cpp
+++ b/indra/newview/llfloatertos.cpp
@@ -162,7 +162,6 @@ BOOL LLFloaterTOS::postBuild()
childSetValue("tos_text", LLSD(mMessage));
#endif
-
return TRUE;
}
diff --git a/indra/newview/llnetmap.cpp b/indra/newview/llnetmap.cpp
index 5c32f8d90a..4fde8988f5 100644
--- a/indra/newview/llnetmap.cpp
+++ b/indra/newview/llnetmap.cpp
@@ -83,7 +83,7 @@ LLNetMap::LLNetMap(
LLRect major_dir_rect( 0, DIR_HEIGHT, DIR_WIDTH, 0 );
mTextBoxNorth = new LLTextBox( "N", major_dir_rect );
- mTextBoxNorth->setDropshadowVisible( TRUE );
+ mTextBoxNorth->setFontStyle(LLFontGL::DROP_SHADOW_SOFT);
addChild( mTextBoxNorth );
LLColor4 minor_color( 1.f, 1.f, 1.f, .7f );
diff --git a/indra/newview/llpanelcontents.cpp b/indra/newview/llpanelcontents.cpp
index 30adea7d73..724ef8a847 100644
--- a/indra/newview/llpanelcontents.cpp
+++ b/indra/newview/llpanelcontents.cpp
@@ -87,9 +87,13 @@ void LLPanelContents::getState(LLViewerObject *objectp )
return;
}
+ LLUUID group_id; // used for SL-23488
+ gSelectMgr->selectGetGroup(group_id); // sets group_id as a side effect SL-23488
+
// BUG? Check for all objects being editable?
BOOL editable = gAgent.isGodlike()
- || (objectp->permModify() && objectp->permYouOwner());
+ || (objectp->permModify()
+ && ( objectp->permYouOwner() || ( !group_id.isNull() && gAgent.isInGroup(group_id) ))); // solves SL-23488
BOOL all_volume = gSelectMgr->selectionAllPCode( LL_PCODE_VOLUME );
// Edit script button - ok if object is editable and there's an
diff --git a/indra/newview/llpreviewscript.cpp b/indra/newview/llpreviewscript.cpp
index 4cf103508d..51ead9c532 100644
--- a/indra/newview/llpreviewscript.cpp
+++ b/indra/newview/llpreviewscript.cpp
@@ -503,7 +503,7 @@ void LLScriptEdCore::updateDynamicHelp(BOOL immediate)
mLiveHelpTimer.stop();
}
}
- else
+ else if (immediate)
{
setHelpPage("");
}
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index cb4077b21b..23e1ab6664 100644
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -1124,16 +1124,8 @@ void inventory_offer_handler(LLOfferInfo* info, BOOL from_task)
if (from_task)
{
args["[OBJECTFROMNAME]"] = info->mFromName;
- if (name_found)
- {
- LLNotifyBox::showXml("ObjectGiveItem", args,
- &inventory_offer_callback, (void*)info);
- }
- else
- {
- LLNotifyBox::showXml("ObjectGiveItemUnknownUser", args,
- &inventory_offer_callback, (void*)info);
- }
+ LLNotifyBox::showXml(name_found ? "ObjectGiveItem" : "ObjectGiveItemUnknownUser",
+ args, &inventory_offer_callback, (void*)info);
}
else
{
@@ -1633,10 +1625,7 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
}
else
{
- if (dialog == IM_TASK_INVENTORY_OFFERED)
- inventory_offer_handler(info, TRUE);
- else
- inventory_offer_handler(info, FALSE);
+ inventory_offer_handler(info, dialog == IM_TASK_INVENTORY_OFFERED);
}
}
break;
diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp
index f276999380..a9ed98e9db 100644
--- a/indra/newview/llviewerwindow.cpp
+++ b/indra/newview/llviewerwindow.cpp
@@ -1708,7 +1708,7 @@ void LLViewerWindow::initBase()
mToolTip->setBorderVisible( FALSE );
mToolTip->setBackgroundColor( gColors.getColor( "ToolTipBgColor" ) );
mToolTip->setBackgroundVisible( TRUE );
- mToolTip->setDropshadowVisible( FALSE );
+ mToolTip->setFontStyle(LLFontGL::NORMAL);
mToolTip->setBorderDropshadowVisible( TRUE );
mToolTip->setVisible( FALSE );
diff --git a/indra/newview/llworldmapview.cpp b/indra/newview/llworldmapview.cpp
index 9d2fb122e5..6c99d99732 100644
--- a/indra/newview/llworldmapview.cpp
+++ b/indra/newview/llworldmapview.cpp
@@ -158,7 +158,6 @@ LLWorldMapView::LLWorldMapView(const std::string& name, const LLRect& rect )
LLRect major_dir_rect( 0, DIR_HEIGHT, DIR_WIDTH, 0 );
mTextBoxNorth = new LLTextBox( "N", major_dir_rect );
- mTextBoxNorth->setDropshadowVisible( TRUE );
addChild( mTextBoxNorth );
LLColor4 minor_color( 1.f, 1.f, 1.f, .7f );
diff --git a/indra/test/llhttpclient_tut.cpp b/indra/test/llhttpclient_tut.cpp
index 17bad4bc14..25626719ac 100644
--- a/indra/test/llhttpclient_tut.cpp
+++ b/indra/test/llhttpclient_tut.cpp
@@ -14,6 +14,10 @@
#include <tut/tut.h>
#include "linden_common.h"
+
+// These are too slow on Windows to actually include in the build. JC
+#if !LL_WINDOWS
+
#include "lltut.h"
#include "llhttpclient.h"
#include "llformat.h"
@@ -313,4 +317,7 @@ namespace tut
LLSD body = result["body"];
ensure_equals("echoed result matches", body.size(), expected.size());
}
+
}
+
+#endif // !LL_WINDOWS
diff --git a/indra/test/lltut.cpp b/indra/test/lltut.cpp
index 5a6ccabec2..0e9a886bb8 100644
--- a/indra/test/lltut.cpp
+++ b/indra/test/lltut.cpp
@@ -20,6 +20,8 @@ namespace tut
void ensure_equals(const char* msg, const LLDate& actual,
const LLDate& expected)
{
+ std::cout << "ensure_equals " << msg << std::endl;
+
ensure_equals(msg,
actual.secondsSinceEpoch(), expected.secondsSinceEpoch());
}
@@ -28,6 +30,8 @@ namespace tut
void ensure_equals(const char* msg, const LLURI& actual,
const LLURI& expected)
{
+ std::cout << "ensure_equals " << msg << std::endl;
+
ensure_equals(msg,
actual.asString(), expected.asString());
}
@@ -36,6 +40,8 @@ namespace tut
void ensure_equals(const char* msg,
const std::vector<U8>& actual, const std::vector<U8>& expected)
{
+ std::cout << "ensure_equals " << msg << std::endl;
+
std::string s(msg);
ensure_equals(s + " size", actual.size(), expected.size());
@@ -54,6 +60,8 @@ namespace tut
void ensure_equals(const char* m, const LLSD& actual,
const LLSD& expected)
{
+ std::cout << "ensure_equals " << m << std::endl;
+
const std::string& msg = m;
ensure_equals(msg + " type", actual.type(), expected.type());
@@ -129,6 +137,7 @@ namespace tut
void ensure_starts_with(const std::string& msg,
const std::string& actual, const std::string& expectedStart)
{
+ std::cout << "ensure_starts_with " << msg << std::endl;
if( actual.find(expectedStart, 0) != 0 )
{
std::stringstream ss;
@@ -141,6 +150,7 @@ namespace tut
void ensure_ends_with(const std::string& msg,
const std::string& actual, const std::string& expectedEnd)
{
+ std::cout << "ensure_ends_with " << msg << std::endl;
if( actual.size() < expectedEnd.size()
|| actual.rfind(expectedEnd)
!= (actual.size() - expectedEnd.size()) )
@@ -155,6 +165,7 @@ namespace tut
void ensure_contains(const std::string& msg,
const std::string& actual, const std::string& expectedSubString)
{
+ std::cout << "ensure_contains " << msg << std::endl;
if( actual.find(expectedSubString, 0) == std::string::npos )
{
std::stringstream ss;
@@ -167,6 +178,7 @@ namespace tut
void ensure_does_not_contain(const std::string& msg,
const std::string& actual, const std::string& expectedSubString)
{
+ std::cout << "ensure_does_not_contain " << msg << std::endl;
if( actual.find(expectedSubString, 0) != std::string::npos )
{
std::stringstream ss;