svn merge -r64837:65485 svn+ssh://svn.lindenlab.com/svn/linden/branches/maintenance --> release

(only inside indra)

(josh) Original log message was:
   svn merge -r64837:65485 svn+ssh://svn.lindenlab.com/svn/linden/branches/maintenance
bos updated it to be:
   svn merge -r64837:65269 svn+ssh://svn.lindenlab.com/svn/linden/branches/maintenance
However, it appears it actually was:
   svn merge -r64837:65485 svn+ssh://svn.lindenlab.com/svn/linden/branches/maintenance
... missing some file additions.
master
Bryan O'Sullivan 2007-07-18 21:22:40 +00:00
parent e1ab7d8a30
commit ce7682c2a4
67 changed files with 574 additions and 416 deletions

View File

@ -1,7 +1,5 @@
"""\
@file __init__.py
@brief Initialization file for the indra module.
Copyright (c) 2006-2007, Linden Research, Inc.
$License$
"""
# @file __init__.py
# @brief Initialization file for the indra module.
#
# Copyright (c) 2006-$CurrentYear$, Linden Research, Inc.
# $License$

View File

@ -465,39 +465,6 @@ void LLJoint::setSkinOffset( const LLVector3& offset )
mSkinOffset = offset;
}
//-----------------------------------------------------------------------------
// setConstraintSilhouette()
//-----------------------------------------------------------------------------
void LLJoint::setConstraintSilhouette(LLDynamicArray<LLVector3>& silhouette)
{
S32 i;
mConstraintSilhouette.reset();
for (i = 0; i < silhouette.count(); i++)
{
if (i % 2 == 1)
{
// skip normals
continue;
}
mConstraintSilhouette[i / 2] = silhouette[i];
}
LLQuaternion inv_parent_rotation = LLQuaternion::DEFAULT;
if (getParent())
{
inv_parent_rotation = ~getParent()->getWorldRotation();
}
for (i = 0; i < mConstraintSilhouette.count(); i++)
{
LLVector3 vert = mConstraintSilhouette[i];
vert -= getWorldPosition();
vert.normVec();
vert = vert * inv_parent_rotation;
}
}
//-----------------------------------------------------------------------------
// clampRotation()

View File

@ -65,7 +65,6 @@ protected:
public:
U32 mDirtyFlags;
BOOL mWorldRotationDirty;
BOOL mUpdateXform;
// describes the skin binding pose
@ -73,8 +72,6 @@ public:
S32 mJointNum;
LLDynamicArray<LLVector3> mConstraintSilhouette;
// child joints
typedef std::list<LLJoint*> child_list_t;
child_list_t mChildren;
@ -151,8 +148,6 @@ public:
LLXformMatrix *getXform() { return &mXform; }
void setConstraintSilhouette(LLDynamicArray<LLVector3>& silhouette);
void clampRotation(LLQuaternion old_rot, LLQuaternion new_rot);
virtual BOOL isAnimatable() { return TRUE; }

View File

@ -110,10 +110,12 @@ const char CLOUD_LAYER_CODE = '8';
// keys
// Bit masks for various keyboard modifier keys.
const MASK MASK_NONE = 0x0000;
const MASK MASK_CONTROL = 0x0001;
const MASK MASK_ALT = 0x0002;
const MASK MASK_SHIFT = 0x0004;
const MASK MASK_NONE = 0x0000;
const MASK MASK_CONTROL = 0x0001; // Mapped to cmd on Macs
const MASK MASK_ALT = 0x0002;
const MASK MASK_SHIFT = 0x0004;
const MASK MASK_NORMALKEYS = 0x0007; // A real mask - only get the bits for normal modifier keys
const MASK MASK_MAC_CONTROL = 0x0008; // Un-mapped Ctrl key on Macs, not used on Windows
// Special keys go into >128
const KEY KEY_SPECIAL = 0x80; // special keys start here

View File

@ -49,6 +49,7 @@ S32 LLMemType::sCurType = LLMemType::MTYPE_INIT;
S32 LLMemType::sType[LLMemType::MTYPE_MAX_DEPTH];
S32 LLMemType::sMemCount[LLMemType::MTYPE_NUM_TYPES] = { 0 };
S32 LLMemType::sMaxMemCount[LLMemType::MTYPE_NUM_TYPES] = { 0 };
S32 LLMemType::sNewCount[LLMemType::MTYPE_NUM_TYPES] = { 0 };
S32 LLMemType::sOverheadMem = 0;
const char* LLMemType::sTypeDesc[LLMemType::MTYPE_NUM_TYPES] =
@ -113,7 +114,7 @@ void LLMemType::printMem()
{
if (sMemCount[i])
{
llinfos << llformat("MEM: % 20s %03d MB (%03d MB)",sTypeDesc[i],sMemCount[i]>>20,sMaxMemCount[i]>>20) << llendl;
llinfos << llformat("MEM: % 20s %03d MB (%03d MB) in %06d News",sTypeDesc[i],sMemCount[i]>>20,sMaxMemCount[i]>>20, sNewCount[i]) << llendl;
}
misc_mem -= sMemCount[i];
}
@ -160,6 +161,7 @@ void* ll_allocate (size_t size)
{
LLMemType::sMaxMemCount[LLMemType::sCurType] = LLMemType::sMemCount[LLMemType::sCurType];
}
LLMemType::sNewCount[LLMemType::sCurType]++;
#endif
return (void*)p;
}
@ -185,6 +187,7 @@ void ll_release (void *pin)
#if MEM_TRACK_TYPE
LLMemType::sMemCount[type] -= size;
LLMemType::sOverheadMem -= 4;
LLMemType::sNewCount[type]--;
#endif
LLMemType::sTotalMem -= size;
free(p);

View File

@ -21,6 +21,7 @@ extern void ll_release (void *p);
#define MEM_TRACK_TYPE (1 && MEM_TRACK_MEM)
#if MEM_TRACK_TYPE
#define MEM_DUMP_DATA 1
#define MEM_TYPE_NEW(T) \
static void* operator new(size_t s) { LLMemType mt(T); return ll_allocate(s); } \
static void operator delete(void* p) { ll_release(p); }
@ -123,6 +124,7 @@ public:
static S32 sType[MTYPE_MAX_DEPTH];
static S32 sMemCount[MTYPE_NUM_TYPES];
static S32 sMaxMemCount[MTYPE_NUM_TYPES];
static S32 sNewCount[MTYPE_NUM_TYPES];
static S32 sOverheadMem;
static const char* sTypeDesc[MTYPE_NUM_TYPES];
#endif

View File

@ -280,7 +280,7 @@ bool CProcessor::AnalyzeIntelProcessor()
strcpy(CPUInfo.strFamily, "Intel Pentium"); /* Flawfinder: ignore */
break;
case 6: // Family = 6: Pentium Pro (80686) processor family
strcpy(CPUInfo.strFamily, "Intel Pentium Pro"); /* Flawfinder: ignore */
strcpy(CPUInfo.strFamily, "Intel Pentium Pro/2/3, Core"); /* Flawfinder: ignore */
break;
case 15: // Family = 15: Extended family specific
// Masking the extended family
@ -476,9 +476,17 @@ bool CProcessor::AnalyzeIntelProcessor()
break;
}
break;
case 0xE: // Model = 0xE: Intel Core Duo processor, Intel Core Solo processor, model E
strcpy(CPUInfo.strModel, "Intel Core Duo/Solo Processor"); /*Flawfinder: ignore*/
strncat(strCPUName, "Intel Core Duo/Solo Processor", sizeof(strCPUName)-(strlen(strCPUName)-1)); /*Flawfinder: ignore*/
break;
case 0xF: // Model = 0xF: Intel Core 2 Duo processor, model F
strcpy(CPUInfo.strModel, "Intel Core2 Duo Processor"); /*Flawfinder: ignore*/
strncat(strCPUName, "Intel Core2 Duo Processor", sizeof(strCPUName)-(strlen(strCPUName)-1)); /*Flawfinder: ignore*/
break;
default: // *more bored*
strcpy(CPUInfo.strModel, "Unknown Intel Pentium Pro"); /*Flawfinder: ignore*/
strncat(strCPUName, "Intel Pentium Pro (Unknown model)", sizeof(strCPUName)-(strlen(strCPUName)-1)); /*Flawfinder: ignore*/
strcpy(CPUInfo.strModel, "Unknown Intel Pentium Pro/2/3, Core"); /*Flawfinder: ignore*/
strncat(strCPUName, "Intel Pentium Pro/2/3, Core (Unknown model)", sizeof(strCPUName)-(strlen(strCPUName)-1)); /*Flawfinder: ignore*/
break;
}
break;

View File

@ -16,7 +16,11 @@
extern "C"
{
#include "expat/expat.h"
#ifdef LL_STANDALONE
# include <expat.h>
#else
# include "expat/expat.h"
#endif
}
/**

View File

@ -11,7 +11,11 @@
#include "llsys.h"
#include <iostream>
#include <zlib/zlib.h>
#ifdef LL_STANDALONE
# include <zlib.h>
#else
# include "zlib/zlib.h"
#endif
#include "processor.h"

View File

@ -14,8 +14,13 @@
#include "llimage.h"
extern "C" {
#include "jpeglib/jpeglib.h"
#include "jpeglib/jerror.h"
#ifdef LL_STANDALONE
# include <jpeglib.h>
# include <jerror.h>
#else
# include "jpeglib/jpeglib.h"
# include "jpeglib/jerror.h"
#endif
}
class LLImageJPEG : public LLImageFormatted

View File

@ -75,34 +75,34 @@ public:
}
}
virtual ~LLOctreeNode() { BaseType::destroyListeners(); delete this->mState; }
~LLOctreeNode() { BaseType::destroyListeners(); delete this->mState; }
virtual const BaseType* getParent() const { return mParent; }
virtual void setParent(BaseType* parent) { mParent = (oct_node*) parent; }
virtual const LLVector3d& getCenter() const { return mCenter; }
virtual const LLVector3d& getSize() const { return mSize; }
virtual void setCenter(LLVector3d center) { mCenter = center; }
virtual void setSize(LLVector3d size) { mSize = size; }
virtual bool balance() { return getOctState()->balance(); }
virtual void validate() { getOctState()->validate(); }
virtual U32 getChildCount() const { return getOctState()->getChildCount(); }
virtual oct_node* getChild(U32 index) { return getOctState()->getChild(index); }
virtual const oct_node* getChild(U32 index) const { return getOctState()->getChild(index); }
virtual U32 getElementCount() const { return getOctState()->getElementCount(); }
virtual void removeByAddress(T* data) { getOctState()->removeByAddress(data); }
virtual bool hasLeafState() const { return getOctState()->isLeaf(); }
virtual void destroy() { getOctState()->destroy(); }
virtual oct_node* getNodeAt(T* data) { return getNodeAt(data->getPositionGroup(), data->getBinRadius()); }
virtual oct_node* getNodeAt(const LLVector3d& pos, const F64& rad) { return getOctState()->getNodeAt(pos, rad); }
virtual U8 getOctant() const { return mOctant; }
virtual void setOctant(U8 octant) { mOctant = octant; }
virtual const oct_state* getOctState() const { return (const oct_state*) BaseType::mState; }
virtual oct_state* getOctState() { return (oct_state*) BaseType::mState; }
virtual const oct_node* getOctParent() const { return (const oct_node*) getParent(); }
virtual oct_node* getOctParent() { return (oct_node*) getParent(); }
virtual void deleteChild(oct_node* child) { getOctState()->deleteChild(child); }
inline const BaseType* getParent() const { return mParent; }
inline void setParent(BaseType* parent) { mParent = (oct_node*) parent; }
inline const LLVector3d& getCenter() const { return mCenter; }
inline const LLVector3d& getSize() const { return mSize; }
inline void setCenter(LLVector3d center) { mCenter = center; }
inline void setSize(LLVector3d size) { mSize = size; }
inline bool balance() { return getOctState()->balance(); }
inline void validate() { getOctState()->validate(); }
inline U32 getChildCount() const { return getOctState()->getChildCount(); }
inline oct_node* getChild(U32 index) { return getOctState()->getChild(index); }
inline const oct_node* getChild(U32 index) const { return getOctState()->getChild(index); }
inline U32 getElementCount() const { return getOctState()->getElementCount(); }
inline void removeByAddress(T* data) { getOctState()->removeByAddress(data); }
inline bool hasLeafState() const { return getOctState()->isLeaf(); }
inline void destroy() { getOctState()->destroy(); }
inline oct_node* getNodeAt(T* data) { return getNodeAt(data->getPositionGroup(), data->getBinRadius()); }
inline oct_node* getNodeAt(const LLVector3d& pos, const F64& rad) { return getOctState()->getNodeAt(pos, rad); }
inline U8 getOctant() const { return mOctant; }
inline void setOctant(U8 octant) { mOctant = octant; }
inline const oct_state* getOctState() const { return (const oct_state*) BaseType::mState; }
inline oct_state* getOctState() { return (oct_state*) BaseType::mState; }
inline const oct_node* getOctParent() const { return (const oct_node*) getParent(); }
inline oct_node* getOctParent() { return (oct_node*) getParent(); }
inline void deleteChild(oct_node* child) { getOctState()->deleteChild(child); }
virtual U8 getOctant(const F64 pos[]) const //get the octant pos is in
U8 getOctant(const F64 pos[]) const //get the octant pos is in
{
U8 ret = 0;
@ -122,17 +122,17 @@ public:
return ret;
}
virtual bool isInside(const LLVector3d& pos, const F64& rad) const
inline bool isInside(const LLVector3d& pos, const F64& rad) const
{
return rad <= mSize.mdV[0]*2.0 && isInside(pos);
}
virtual bool isInside(T* data) const
inline bool isInside(T* data) const
{
return isInside(data->getPositionGroup(), data->getBinRadius());
}
virtual bool isInside(const LLVector3d& pos) const
bool isInside(const LLVector3d& pos) const
{
const F64& x = pos.mdV[0];
const F64& y = pos.mdV[1];
@ -148,7 +148,7 @@ public:
return true;
}
virtual void updateMinMax()
void updateMinMax()
{
for (U32 i = 0; i < 3; i++)
{
@ -158,12 +158,12 @@ public:
}
}
virtual oct_listener* getOctListener(U32 index)
inline oct_listener* getOctListener(U32 index)
{
return (oct_listener*) BaseType::getListener(index);
}
bool contains(T* xform)
inline bool contains(T* xform)
{
return contains(xform->getBinRadius());
}

View File

@ -49,17 +49,17 @@ class LLTreeNode
public:
LLTreeNode(LLTreeState<T>* state) { setState(state); }
virtual ~LLTreeNode();
virtual LLTreeState<T>* getState() { return mState; }
virtual const LLTreeState<T>* getState() const { return mState; }
LLTreeState<T>* getState() { return mState; }
const LLTreeState<T>* getState() const { return mState; }
virtual void setState(LLTreeState<T>* state);
virtual void insert(T* data);
virtual bool remove(T* data);
virtual void notifyRemoval(T* data);
virtual U32 getListenerCount() { return mListeners.size(); }
virtual LLTreeListener<T>* getListener(U32 index) const { return mListeners[index]; }
virtual void addListener(LLTreeListener<T>* listener) { mListeners.push_back(listener); }
virtual void removeListener(U32 index) { mListeners.erase(mListeners.begin()+index); }
void setState(LLTreeState<T>* state);
void insert(T* data);
bool remove(T* data);
void notifyRemoval(T* data);
inline U32 getListenerCount() { return mListeners.size(); }
inline LLTreeListener<T>* getListener(U32 index) const { return mListeners[index]; }
inline void addListener(LLTreeListener<T>* listener) { mListeners.push_back(listener); }
inline void removeListener(U32 index) { mListeners.erase(mListeners.begin()+index); }
protected:
void destroyListeners()

View File

@ -763,7 +763,7 @@ public:
FLAT_MASK = 0x0100,
TOP_MASK = 0x0200,
BOTTOM_MASK = 0x0400
} TypeMask;
};
public:
S32 mID;

View File

@ -76,7 +76,7 @@ namespace boost
void intrusive_ptr_release(LLCurl::Responder* p)
{
if(0 == --p->mReferenceCount)
if(p && 0 == --p->mReferenceCount)
{
delete p;
}

View File

@ -18,7 +18,11 @@
#include "llvfile.h"
#include "llvfs.h"
#include "zlib/zlib.h"
#ifdef LL_STANDALONE
# include <zlib.h>
#else
# include "zlib/zlib.h"
#endif
const U32 MAX_RUNNING_REQUESTS = 1;
const F32 MAX_PROCESSING_TIME = 0.005f;

View File

@ -102,6 +102,9 @@ void LLNameValue::baseInit()
mSendto = NVS_NULL;
mStringSendto = NameValueSendtoStrings[NVS_NULL];
mNameValueCB = NULL;
mUserData = NULL;
}
void LLNameValue::init(const char *name, const char *data, const char *type, const char *nvclass, const char *nvsendto, TNameValueCallback nvcb, void **user_data)

View File

@ -22,7 +22,8 @@ LLUserOperationMgr* gUserOperationMgr = NULL;
LLUserOperation::LLUserOperation(const LLUUID& agent_id)
: mAgentID(agent_id),
mTimer()
mTimer(),
mNoExpire(FALSE)
{
mTransactionID.generate();
}
@ -31,14 +32,16 @@ LLUserOperation::LLUserOperation(const LLUUID& agent_id,
const LLUUID& transaction_id) :
mAgentID(agent_id),
mTransactionID(transaction_id),
mTimer()
mTimer(),
mNoExpire(FALSE)
{
}
// protected constructor which is used by base classes that determine
// transaction, agent, et. after construction.
LLUserOperation::LLUserOperation() :
mTimer()
mTimer(),
mNoExpire(FALSE)
{
}
@ -46,11 +49,19 @@ LLUserOperation::~LLUserOperation()
{
}
void LLUserOperation::SetNoExpireFlag(const BOOL flag)
{
mNoExpire = flag;
}
BOOL LLUserOperation::isExpired()
{
const F32 EXPIRE_TIME_SECS = 10.f;
return mTimer.getElapsedTimeF32() > EXPIRE_TIME_SECS;
if (!mNoExpire)
{
const F32 EXPIRE_TIME_SECS = 10.f;
return mTimer.getElapsedTimeF32() > EXPIRE_TIME_SECS;
}
return FALSE;
}
void LLUserOperation::expire()

View File

@ -28,6 +28,9 @@ public:
// Operation never got necessary data, so expired
virtual BOOL isExpired();
// ability to mark this operation as never expiring.
void SetNoExpireFlag(const BOOL flag);
// Send request to the dataserver
virtual void sendRequest() = 0;
@ -47,6 +50,7 @@ protected:
LLUUID mAgentID;
LLUUID mTransactionID;
LLFrameTimer mTimer;
BOOL mNoExpire; // this is used for operations that expect an answer and will wait till it gets one.
};

View File

@ -116,7 +116,6 @@ public:
// Various GL/Rendering options
S32 mTextureMemory;
mutable F32 mLastBindTime; // last time this was bound, by discard level
mutable F32 mLastBindAttempt; // last time bindTexture was called on this texture
private:
LLPointer<LLImageRaw> mSaveData; // used for destroyGL/restoreGL

View File

@ -347,18 +347,6 @@ void LLFloater::init(const LLString& title,
LLResizeHandle::LEFT_TOP );
addChild(mResizeHandle[3]);
}
else
{
mResizeBar[0] = NULL;
mResizeBar[1] = NULL;
mResizeBar[2] = NULL;
mResizeBar[3] = NULL;
mResizeHandle[0] = NULL;
mResizeHandle[1] = NULL;
mResizeHandle[2] = NULL;
mResizeHandle[3] = NULL;
}
// Close button.
if (close_btn)
@ -372,6 +360,13 @@ void LLFloater::init(const LLString& title,
mButtonsEnabled[BUTTON_MINIMIZE] = TRUE;
}
// Keep track of whether this window has ever been dragged while it
// was minimized. If it has, we'll remember its position for the
// next time it's minimized.
mHasBeenDraggedWhileMinimized = FALSE;
mPreviousMinimizedLeft = 0;
mPreviousMinimizedBottom = 0;
buildButtons();
// JC - Don't do this here, because many floaters first construct themselves,
@ -737,6 +732,16 @@ void LLFloater::userSetShape(const LLRect& new_rect)
}
}
}
else
{
// If minimized, and origin has changed, set
// mHasBeenDraggedWhileMinimized to TRUE
if ((new_rect.mLeft != old_rect.mLeft) ||
(new_rect.mBottom != old_rect.mBottom))
{
mHasBeenDraggedWhileMinimized = TRUE;
}
}
}
void LLFloater::setMinimized(BOOL minimize)
@ -749,9 +754,19 @@ void LLFloater::setMinimized(BOOL minimize)
reshape( MINIMIZED_WIDTH, LLFLOATER_HEADER_SIZE, TRUE);
S32 left, bottom;
gFloaterView->getMinimizePosition(&left, &bottom);
setOrigin( left, bottom );
// If the floater has been dragged while minimized in the
// past, then locate it at its previous minimized location.
// Otherwise, ask the view for a minimize position.
if (mHasBeenDraggedWhileMinimized)
{
setOrigin(mPreviousMinimizedLeft, mPreviousMinimizedBottom);
}
else
{
S32 left, bottom;
gFloaterView->getMinimizePosition(&left, &bottom);
setOrigin( left, bottom );
}
if (mButtonsEnabled[BUTTON_MINIMIZE])
{
@ -804,6 +819,15 @@ void LLFloater::setMinimized(BOOL minimize)
}
else
{
// If this window has been dragged while minimized (at any time),
// remember its position for the next time it's minimized.
if (mHasBeenDraggedWhileMinimized)
{
const LLRect& currentRect = getRect();
mPreviousMinimizedLeft = currentRect.mLeft;
mPreviousMinimizedBottom = currentRect.mBottom;
}
reshape( mPreviousRect.getWidth(), mPreviousRect.getHeight(), TRUE );
setOrigin( mPreviousRect.mLeft, mPreviousRect.mBottom );
@ -1020,7 +1044,6 @@ BOOL LLFloater::handleMouseDown(S32 x, S32 y, MASK mask)
if( mMinimized )
{
// Offer the click to the close button.
// Any other click = restore
if( mButtonsEnabled[BUTTON_CLOSE] )
{
S32 local_x = x - mButtons[BUTTON_CLOSE]->getRect().mLeft;
@ -1034,9 +1057,22 @@ BOOL LLFloater::handleMouseDown(S32 x, S32 y, MASK mask)
}
}
// restore
bringToFront( x, y );
return TRUE;
// Offer the click to the restore button.
if( mButtonsEnabled[BUTTON_RESTORE] )
{
S32 local_x = x - mButtons[BUTTON_RESTORE]->getRect().mLeft;
S32 local_y = y - mButtons[BUTTON_RESTORE]->getRect().mBottom;
if (mButtons[BUTTON_RESTORE]->pointInView(local_x, local_y)
&& mButtons[BUTTON_RESTORE]->handleMouseDown(local_x, local_y, mask))
{
// restore button handled it, return
return TRUE;
}
}
// Otherwise pass to drag handle for movement
return mDragHandle->handleMouseDown(x, y, mask);
}
else
{
@ -1448,30 +1484,14 @@ void LLFloater::setCanResize(BOOL can_resize)
{
if (mResizable && !can_resize)
{
removeChild(mResizeBar[0]);
removeChild(mResizeBar[1]);
removeChild(mResizeBar[2]);
removeChild(mResizeBar[3]);
removeChild(mResizeHandle[0]);
removeChild(mResizeHandle[1]);
removeChild(mResizeHandle[2]);
removeChild(mResizeHandle[3]);
delete mResizeBar[0];
delete mResizeBar[1];
delete mResizeBar[2];
delete mResizeBar[3];
delete mResizeHandle[0];
delete mResizeHandle[1];
delete mResizeHandle[2];
mResizeHandle[3] = NULL;
mResizeBar[0] = NULL;
mResizeBar[1] = NULL;
mResizeBar[2] = NULL;
mResizeBar[3] = NULL;
mResizeHandle[0] = NULL;
mResizeHandle[1] = NULL;
mResizeHandle[2] = NULL;
mResizeHandle[3] = NULL;
for (S32 i = 0; i < 4; i++)
{
removeChild(mResizeBar[i], TRUE);
mResizeBar[i] = NULL;
removeChild(mResizeHandle[i], TRUE);
mResizeHandle[i] = NULL;
}
}
else if (!mResizable && can_resize)
{

View File

@ -261,6 +261,10 @@ protected:
static handle_map_t sFloaterMap;
std::vector<LLView*> mMinimizedHiddenChildren;
BOOL mHasBeenDraggedWhileMinimized;
S32 mPreviousMinimizedBottom;
S32 mPreviousMinimizedLeft;
};
/////////////////////////////////////////////////////////////

View File

@ -152,6 +152,14 @@ LLXMLNodePtr LLMenuItemGL::getXML(bool save_children) const
out << LLKeyboard::stringFromKey(mAcceleratorKey);
node->createChild("shortcut", TRUE)->setStringValue(out.str());
#ifdef LL_DARWIN
// Write in special tag if this key is really a ctrl combination on the Mac
if (mAcceleratorMask & MASK_MAC_CONTROL)
{
node->createChild("useMacCtrl", TRUE)->setBoolValue( TRUE );
}
#endif // LL_DARWIN
}
return node;
@ -184,7 +192,7 @@ BOOL LLMenuItemGL::handleKey(KEY key, MASK mask, BOOL called_from_parent)
BOOL LLMenuItemGL::handleAcceleratorKey(KEY key, MASK mask)
{
if( mEnabled && (!gKeyboard->getKeyRepeated(key) || mAllowKeyRepeat) && (key == mAcceleratorKey) && (mask == mAcceleratorMask) )
if( mEnabled && (!gKeyboard->getKeyRepeated(key) || mAllowKeyRepeat) && (key == mAcceleratorKey) && (mask == (mAcceleratorMask & MASK_NORMALKEYS)) )
{
doIt();
return TRUE;
@ -216,7 +224,7 @@ BOOL LLMenuItemGL::addToAcceleratorList(std::list <LLKeyBinding*> *listp)
for (list_it = listp->begin(); list_it != listp->end(); ++list_it)
{
accelerator = *list_it;
if ((accelerator->mKey == mAcceleratorKey) && (accelerator->mMask == mAcceleratorMask))
if ((accelerator->mKey == mAcceleratorKey) && (accelerator->mMask == (mAcceleratorMask & MASK_NORMALKEYS)))
{
// *NOTE: get calling code to throw up warning or route
@ -240,7 +248,7 @@ BOOL LLMenuItemGL::addToAcceleratorList(std::list <LLKeyBinding*> *listp)
if (accelerator)
{
accelerator->mKey = mAcceleratorKey;
accelerator->mMask = mAcceleratorMask;
accelerator->mMask = (mAcceleratorMask & MASK_NORMALKEYS);
// accelerator->mName = mLabel;
}
listp->push_back(accelerator);//addData(accelerator);
@ -264,7 +272,16 @@ void LLMenuItemGL::appendAcceleratorString( LLString& st )
// Standard Mac names for modifier keys in menu equivalents
// We could use the symbol characters, but they only exist in certain fonts.
if( mAcceleratorMask & MASK_CONTROL )
st.append( "Cmd-" ); // Symbol would be "\xE2\x8C\x98"
{
if ( mAcceleratorMask & MASK_MAC_CONTROL )
{
st.append( "Ctrl-" );
}
else
{
st.append( "Cmd-" ); // Symbol would be "\xE2\x8C\x98"
}
}
if( mAcceleratorMask & MASK_ALT )
st.append( "Opt-" ); // Symbol would be "\xE2\x8C\xA5"
if( mAcceleratorMask & MASK_SHIFT )
@ -279,7 +296,7 @@ void LLMenuItemGL::appendAcceleratorString( LLString& st )
#endif
LLString keystr = LLKeyboard::stringFromKey( mAcceleratorKey );
if ((mAcceleratorMask & (MASK_CONTROL|MASK_ALT|MASK_SHIFT)) &&
if ((mAcceleratorMask & MASK_NORMALKEYS) &&
(keystr[0] == '-' || keystr[0] == '='))
{
st.append( " " );
@ -978,7 +995,7 @@ void LLMenuItemCallGL::buildDrawLabel( void )
BOOL LLMenuItemCallGL::handleAcceleratorKey( KEY key, MASK mask )
{
if( (!gKeyboard->getKeyRepeated(key) || mAllowKeyRepeat) && (key == mAcceleratorKey) && (mask == mAcceleratorMask) )
if( (!gKeyboard->getKeyRepeated(key) || mAllowKeyRepeat) && (key == mAcceleratorKey) && (mask == (mAcceleratorMask & MASK_NORMALKEYS)) )
{
LLPointer<LLEvent> fired_event = new LLEvent(this);
fireEvent(fired_event, "on_build");
@ -1945,10 +1962,23 @@ void LLMenuGL::parseChildXML(LLXMLNodePtr child, LLView *parent, LLUICtrlFactory
child->hasName(LL_MENU_ITEM_CHECK_GL_TAG))
{
MASK mask = 0;
#ifdef LL_DARWIN
// See if this Mac accelerator should really use the ctrl key and not get mapped to cmd
BOOL useMacCtrl = FALSE;
child->getAttributeBOOL("useMacCtrl", useMacCtrl);
#endif // LL_DARWIN
LLString shortcut;
child->getAttributeString("shortcut", shortcut);
if (shortcut.find("control") != shortcut.npos)
{
#ifdef LL_DARWIN
if ( useMacCtrl )
{
mask |= MASK_MAC_CONTROL;
}
#endif // LL_DARWIN
mask |= MASK_CONTROL;
}
if (shortcut.find("alt") != shortcut.npos)

View File

@ -83,9 +83,9 @@ BOOL LLTextCmd::hasExtCharValue( llwchar value )
}
// Utility funcs
S32 LLTextCmd::insert(LLTextEditor* editor, S32 pos, const LLWString &utf8str)
S32 LLTextCmd::insert(LLTextEditor* editor, S32 pos, const LLWString &wstr)
{
return editor->insertStringNoUndo( pos, utf8str );
return editor->insertStringNoUndo( pos, wstr );
}
S32 LLTextCmd::remove(LLTextEditor* editor, S32 pos, S32 length)
{
@ -102,29 +102,29 @@ class LLTextCmdInsert : public LLTextCmd
{
public:
LLTextCmdInsert(S32 pos, BOOL group_with_next, const LLWString &ws)
: LLTextCmd(pos, group_with_next), mString(ws)
: LLTextCmd(pos, group_with_next), mWString(ws)
{
}
virtual BOOL execute( LLTextEditor* editor, S32* delta )
{
*delta = insert(editor, mPos, mString );
LLWString::truncate(mString, *delta);
//mString = wstring_truncate(mString, *delta);
*delta = insert(editor, mPos, mWString );
LLWString::truncate(mWString, *delta);
//mWString = wstring_truncate(mWString, *delta);
return (*delta != 0);
}
virtual S32 undo( LLTextEditor* editor )
{
remove(editor, mPos, mString.length() );
remove(editor, mPos, mWString.length() );
return mPos;
}
virtual S32 redo( LLTextEditor* editor )
{
insert(editor, mPos, mString );
return mPos + mString.length();
insert(editor, mPos, mWString );
return mPos + mWString.length();
}
private:
LLWString mString;
LLWString mWString;
};
///////////////////////////////////////////////////////////////////
@ -133,7 +133,7 @@ class LLTextCmdAddChar : public LLTextCmd
{
public:
LLTextCmdAddChar( S32 pos, BOOL group_with_next, llwchar wc)
: LLTextCmd(pos, group_with_next), mString(1, wc), mBlockExtensions(FALSE)
: LLTextCmd(pos, group_with_next), mWString(1, wc), mBlockExtensions(FALSE)
{
}
virtual void blockExtensions()
@ -142,13 +142,13 @@ public:
}
virtual BOOL canExtend(S32 pos)
{
return !mBlockExtensions && (pos == mPos + (S32)mString.length());
return !mBlockExtensions && (pos == mPos + (S32)mWString.length());
}
virtual BOOL execute( LLTextEditor* editor, S32* delta )
{
*delta = insert(editor, mPos, mString);
LLWString::truncate(mString, *delta);
//mString = wstring_truncate(mString, *delta);
*delta = insert(editor, mPos, mWString);
LLWString::truncate(mWString, *delta);
//mWString = wstring_truncate(mWString, *delta);
return (*delta != 0);
}
virtual BOOL extendAndExecute( LLTextEditor* editor, S32 pos, llwchar wc, S32* delta )
@ -159,23 +159,23 @@ public:
*delta = insert(editor, pos, ws);
if( *delta > 0 )
{
mString += wc;
mWString += wc;
}
return (*delta != 0);
}
virtual S32 undo( LLTextEditor* editor )
{
remove(editor, mPos, mString.length() );
remove(editor, mPos, mWString.length() );
return mPos;
}
virtual S32 redo( LLTextEditor* editor )
{
insert(editor, mPos, mString );
return mPos + mString.length();
insert(editor, mPos, mWString );
return mPos + mWString.length();
}
private:
LLWString mString;
LLWString mWString;
BOOL mBlockExtensions;
};
@ -222,14 +222,14 @@ public:
}
virtual BOOL execute( LLTextEditor* editor, S32* delta )
{
mString = editor->getWSubString(mPos, mLen);
mWString = editor->getWSubString(mPos, mLen);
*delta = remove(editor, mPos, mLen );
return (*delta != 0);
}
virtual S32 undo( LLTextEditor* editor )
{
insert(editor, mPos, mString );
return mPos + mString.length();
insert(editor, mPos, mWString );
return mPos + mWString.length();
}
virtual S32 redo( LLTextEditor* editor )
{
@ -237,7 +237,7 @@ public:
return mPos;
}
private:
LLWString mString;
LLWString mWString;
S32 mLen;
};

View File

@ -309,7 +309,7 @@ protected:
S32 append(const LLWString &wstr, const BOOL group_with_next_op);
// direct operations
S32 insertStringNoUndo(S32 pos, const LLWString &utf8str); // returns num of chars actually inserted
S32 insertStringNoUndo(S32 pos, const LLWString &wstr); // returns num of chars actually inserted
S32 removeStringNoUndo(S32 pos, S32 length);
S32 overwriteCharNoUndo(S32 pos, llwchar wc);
@ -475,7 +475,7 @@ public:
virtual BOOL hasExtCharValue( llwchar value );
// Define these here so they can access LLTextEditor through the friend relationship
S32 insert(LLTextEditor* editor, S32 pos, const LLWString &utf8str);
S32 insert(LLTextEditor* editor, S32 pos, const LLWString &wstr);
S32 remove(LLTextEditor* editor, S32 pos, S32 length);
S32 overwrite(LLTextEditor* editor, S32 pos, llwchar wc);

View File

@ -1565,6 +1565,11 @@ void LLWindowWin32::moveWindow( const LLCoordScreen& position, const LLCoordScre
}
}
// if the window was already maximized, MoveWindow seems to still set the maximized flag even if
// the window is smaller than maximized.
// So we're going to do a restore first (which is a ShowWindow call) (SL-44655).
ShowWindow(mWindowHandle, SW_RESTORE);
// NOW we can call MoveWindow
MoveWindow(mWindowHandle, position.mX, position.mY, size.mX, size.mY, TRUE);
}
@ -2269,6 +2274,13 @@ LRESULT CALLBACK LLWindowWin32::mainWindowProc(HWND h_wnd, UINT u_msg, WPARAM w_
<< llendl;
}
// There's an odd behavior with WM_SIZE that I would call a bug. If
// the window is maximized, and you call MoveWindow() with a size smaller
// than a maximized window, it ends up sending WM_SIZE with w_param set
// to SIZE_MAXIMIZED -- which isn't true. So the logic below doesn't work.
// (SL-44655). Fixed it by calling ShowWindow(SW_RESTORE) first (see
// LLWindowWin32::moveWindow in this file).
// If we are now restored, but we weren't before, this
// means that the window was un-minimized.
if (w_param == SIZE_RESTORED && window_imp->mLastSizeWParam != SIZE_RESTORED)

View File

@ -10,7 +10,11 @@
#define LL_LLXMLNODE_H
#define XML_STATIC
#ifdef LL_STANDALONE
#include <expat.h>
#else
#include "expat/expat.h"
#endif
#include <map>
#include "indra_constants.h"

View File

@ -10,7 +10,11 @@
#define LL_LLXMLPARSER_H
#define XML_STATIC
#ifdef LL_STANDALONE
#include <expat.h>
#else
#include "expat/expat.h"
#endif
class LLXmlParser
{

View File

@ -15,6 +15,10 @@
#define getenv getenv_workaround
#endif
#ifdef LL_WINDOWS
#pragma warning( disable : 4065 ) // warning: switch statement contains 'default' but no 'case' labels
#endif
#ifdef __cplusplus
}
#endif

View File

@ -48,6 +48,23 @@ export SDL_VIDEO_X11_DGAMOUSE=0
RUN_PATH=`dirname "$0" || echo .`
cd "${RUN_PATH}"
if [ -n "$LL_TCMALLOC" ]; then
tcmalloc_libs='/usr/lib/libtcmalloc.so.0 /usr/lib/libstacktrace.so.0 /lib/libpthread.so.0'
all=1
for f in $tcmalloc_libs; do
if [ ! -f $f ]; then
all=0
fi
done
if [ $all != 1 ]; then
echo 'Cannot use tcmalloc libraries: components missing' 1>&2
else
export LD_PRELOAD=$(echo $tcmalloc_libs | tr ' ' :)
if [ -z "$HEAPCHECK" -a -z "$HEAPPROFILE" ]; then
export HEAPCHECK=${HEAPCHECK:-normal}
fi
fi
fi
LD_LIBRARY_PATH="`pwd`"/lib:"`pwd`"/app_settings/mozilla-runtime-linux-i686:"${LD_LIBRARY_PATH}" $LL_WRAPPER bin/do-not-directly-run-secondlife-bin `cat gridargs.dat` $@ | cat
echo

View File

@ -21,7 +21,6 @@
#include "lldarrayptr.h"
#include "llvertexbuffer.h"
#include "llviewerimage.h"
#include "llpagemem.h"
#include "llstat.h"
#include "lldrawable.h"

View File

@ -71,6 +71,7 @@ LLFloaterFriends::LLFloaterFriends() :
gSavedSettings.setBOOL("ShowFriends", TRUE);
// Builds and adds to gFloaterView
gUICtrlFactory->buildFloater(this, "floater_friends.xml");
refreshUI();
}
LLFloaterFriends::~LLFloaterFriends()
@ -196,7 +197,6 @@ BOOL LLFloaterFriends::postBuild()
childSetAction("remove_btn", onClickRemove, this);
childSetAction("close_btn", onClickClose, this);
refreshUI();
return TRUE;
}

View File

@ -54,18 +54,21 @@ BOOL LLFloaterInspect::isVisible()
void LLFloaterInspect::show(void* ignored)
{
if(sInstance)
// setForceSelection ensures that the pie menu does not deselect things when it
// looses the focus (this can happen with "select own objects only" enabled
// VWR-1471
BOOL forcesel = gSelectMgr->setForceSelection(TRUE);
if (!sInstance) // first use
{
sInstance->open();
}
else
{
LLFloaterInspect* self = new LLFloaterInspect;
self->open();
sInstance = new LLFloaterInspect;
}
sInstance->mObjectSelection = gSelectMgr->getSelection();
sInstance->open();
select_tool(gToolInspect);
gSelectMgr->setForceSelection(forcesel); // restore previouis value
sInstance->mObjectSelection = gSelectMgr->getSelection();
sInstance->refresh();
}

View File

@ -31,10 +31,12 @@ LLFloaterScriptDebug* LLFloaterScriptDebug::sInstance = NULL;
//
// Member Functions
//
LLFloaterScriptDebug::LLFloaterScriptDebug()
: LLMultiFloater()
LLFloaterScriptDebug::LLFloaterScriptDebug() :
LLMultiFloater()
{
// avoid resizing of the window to match
// the initial size of the tabbed-childs, whenever a tab is opened or closed
mAutoResize = FALSE;
}
LLFloaterScriptDebug::~LLFloaterScriptDebug()
@ -90,6 +92,9 @@ LLFloater* LLFloaterScriptDebug::addOutputWindow(const LLUUID &object_id)
}
LLFloater::setFloaterHost(NULL);
// Tabs sometimes overlap resize handle
sInstance->moveResizeHandleToFront();
return floaterp;
}

View File

@ -105,7 +105,7 @@ public:
void updateSnapshot(BOOL new_snapshot);
LLFloaterPostcard* savePostcard();
void saveTexture();
void saveLocal();
BOOL saveLocal();
static void onIdle( void* snapshot_preview );
@ -678,9 +678,9 @@ void LLSnapshotLivePreview::saveTexture()
gViewerStats->incStat(LLViewerStats::ST_SNAPSHOT_COUNT );
}
void LLSnapshotLivePreview::saveLocal()
BOOL LLSnapshotLivePreview::saveLocal()
{
gViewerWindow->saveImageNumbered(mRawImage);
return gViewerWindow->saveImageNumbered(mRawImage);
}
///----------------------------------------------------------------------------
@ -939,6 +939,8 @@ void LLFloaterSnapshot::Impl::onClickKeep(void* data)
if (previewp)
{
BOOL succeeded = TRUE; // Only used for saveLocal for now
if (previewp->getSnapshotType() == LLSnapshotLivePreview::SNAPSHOT_POSTCARD)
{
LLFloaterPostcard* floater = previewp->savePostcard();
@ -957,21 +959,24 @@ void LLFloaterSnapshot::Impl::onClickKeep(void* data)
}
else
{
previewp->saveLocal();
succeeded = previewp->saveLocal();
}
if (gSavedSettings.getBOOL("CloseSnapshotOnKeep"))
{
view->close();
// only plays sound and anim when keeping a snapshot, and closing the snapshot UI
gViewerWindow->playSnapshotAnimAndSound();
// only plays sound and anim when keeping a snapshot, and closing the snapshot UI,
// and only if the save succeeded (i.e. was not canceled)
if (succeeded)
{
gViewerWindow->playSnapshotAnimAndSound();
}
}
else
{
checkAutoSnapshot(previewp);
}
}
}
// static

View File

@ -422,12 +422,25 @@ void LLHUDEffectLookAt::update()
}
}
/**
* Initializes the mTargetPos member from the current mSourceObjec and mTargetObject
* (and possibly mTargetOffsetGlobal).
* When mTargetObject is another avatar, it sets mTargetPos to be their eyes.
*
* Has the side-effect of also calling setAnimationData("LookAtPoint") with the new
* mTargetPos on the source object which is assumed to be an avatar.
*/
void LLHUDEffectLookAt::calcTargetPosition()
{
LLViewerObject *targetObject = (LLViewerObject *)mTargetObject;
if (gNoRender)
{
return;
}
LLViewerObject *target_obj = (LLViewerObject *)mTargetObject;
LLVector3 local_offset;
if (targetObject)
if (target_obj)
{
local_offset.setVec(mTargetOffsetGlobal);
}
@ -436,20 +449,16 @@ void LLHUDEffectLookAt::calcTargetPosition()
local_offset = gAgent.getPosAgentFromGlobal(mTargetOffsetGlobal);
}
if (gNoRender)
{
return;
}
LLVector3 head_position = ((LLVOAvatar*)(LLViewerObject*)mSourceObject)->mHeadp->getWorldPosition();
LLVOAvatar* source_avatar = (LLVOAvatar*)(LLViewerObject*)mSourceObject;
if (targetObject && targetObject->mDrawable.notNull())
if (target_obj && target_obj->mDrawable.notNull())
{
LLQuaternion objRot;
if (targetObject->isAvatar())
LLQuaternion target_rot;
if (target_obj->isAvatar())
{
LLVOAvatar *avatarp = (LLVOAvatar *)targetObject;
LLVOAvatar *target_av = (LLVOAvatar *)target_obj;
BOOL looking_at_self = ((LLVOAvatar*)(LLViewerObject*)mSourceObject)->isSelf() && avatarp->isSelf();
BOOL looking_at_self = source_avatar->isSelf() && target_av->isSelf();
// if selecting self, stare forward
if (looking_at_self && mTargetOffsetGlobal.magVecSquared() < MIN_TARGET_OFFSET_SQUARED)
@ -459,46 +468,46 @@ void LLHUDEffectLookAt::calcTargetPosition()
local_offset.setVec(mTargetOffsetGlobal);
}
mTargetPos = avatarp->mHeadp->getWorldPosition();
// look the other avatar in the eye. note: what happens if target is self? -MG
mTargetPos = target_av->mHeadp->getWorldPosition();
if (mTargetType == LOOKAT_TARGET_MOUSELOOK || mTargetType == LOOKAT_TARGET_FREELOOK)
{
// mouselook and freelook target offsets are absolute
objRot = LLQuaternion::DEFAULT;
target_rot = LLQuaternion::DEFAULT;
}
else if (looking_at_self && gAgent.cameraCustomizeAvatar())
{
// *NOTE: We have to do this because animation
// overrides do not set lookat behavior.
// *TODO: animation overrides for lookat behavior.
objRot = avatarp->mPelvisp->getWorldRotation();
target_rot = target_av->mPelvisp->getWorldRotation();
}
else
{
objRot = avatarp->mRoot.getWorldRotation();
target_rot = target_av->mRoot.getWorldRotation();
}
}
else
else // target obj is not an avatar
{
if (targetObject->mDrawable->getGeneration() == -1)
if (target_obj->mDrawable->getGeneration() == -1)
{
mTargetPos = targetObject->getPositionAgent();
objRot = targetObject->getWorldRotation();
mTargetPos = target_obj->getPositionAgent();
target_rot = target_obj->getWorldRotation();
}
else
{
mTargetPos = targetObject->getRenderPosition();
objRot = targetObject->getRenderRotation();
mTargetPos = target_obj->getRenderPosition();
target_rot = target_obj->getRenderRotation();
}
}
mTargetPos += (local_offset * objRot);
mTargetPos += (local_offset * target_rot);
}
else
else // no target obj or it's not drawable
{
mTargetPos = local_offset;
}
mTargetPos -= head_position;
((LLVOAvatar*)(LLViewerObject*)mSourceObject)->setAnimationData("LookAtPoint", (void *)&mTargetPos);
mTargetPos -= source_avatar->mHeadp->getWorldPosition();
source_avatar->setAnimationData("LookAtPoint", (void *)&mTargetPos);
}

View File

@ -236,11 +236,10 @@ void LLFloaterIMPanel::init(const LLString& session_label)
mSessionStartMsgPos =
mHistoryEditor->getText().length();
bool log_to_file = false;
addHistoryLine(
session_start,
LLColor4::grey,
log_to_file);
false);
}
}
}
@ -748,7 +747,17 @@ void LLFloaterIMPanel::sendMsg()
history_echo += ": ";
}
history_echo += utf8_text;
BOOL other_was_typing = mOtherTyping;
addHistoryLine(history_echo);
if (other_was_typing)
{
addTypingIndicator(mOtherTypingName);
}
}
}
else
@ -850,7 +859,7 @@ void LLFloaterIMPanel::processIMTyping(const LLIMInfo* im_info, BOOL typing)
if (typing)
{
// other user started typing
addTypingIndicator(im_info);
addTypingIndicator(im_info->mName);
}
else
{
@ -860,15 +869,18 @@ void LLFloaterIMPanel::processIMTyping(const LLIMInfo* im_info, BOOL typing)
}
void LLFloaterIMPanel::addTypingIndicator(const LLIMInfo* im_info)
void LLFloaterIMPanel::addTypingIndicator(const std::string &name)
{
mTypingLineStartIndex = mHistoryEditor->getText().length();
LLUIString typing_start = sTypingStartString;
typing_start.setArg("[NAME]", im_info->mName);
bool log_to_file = false;
addHistoryLine(typing_start, LLColor4::grey, log_to_file);
mOtherTyping = TRUE;
// we may have lost a "stop-typing" packet, don't add it twice
if (!mOtherTyping)
{
mTypingLineStartIndex = mHistoryEditor->getText().length();
LLUIString typing_start = sTypingStartString;
typing_start.setArg("[NAME]", name);
addHistoryLine(typing_start, LLColor4::grey, false);
mOtherTypingName = name;
mOtherTyping = TRUE;
}
}

View File

@ -105,7 +105,7 @@ private:
void setTyping(BOOL typing);
// Add the "User is typing..." indicator.
void addTypingIndicator(const LLIMInfo* im_info);
void addTypingIndicator(const std::string &name);
// Remove the "User is typing..." indicator.
void removeTypingIndicator();
@ -145,6 +145,9 @@ private:
// Is other user currently typing?
BOOL mOtherTyping;
// name of other user who is currently typing
std::string mOtherTypingName;
// Where does the "User is typing..." line start?
S32 mTypingLineStartIndex;
//Where does the "Starting session..." line start?

View File

@ -111,6 +111,11 @@ static LLUUID compute_session_id(EInstantMessage dialog,
LLFloaterIM::LLFloaterIM()
{
// autoresize=false is necessary to avoid resizing of the IM window whenever
// a session is opened or closed (it would otherwise resize the window to match
// the size of the im-sesssion when they were created. This happens in
// LLMultiFloater::resizeToContents() when called through LLMultiFloater::addFloater())
this->mAutoResize = FALSE;
gUICtrlFactory->buildFloater(this, "floater_im.xml");
}
@ -186,12 +191,16 @@ void LLFloaterIM::onClose(bool app_quitting)
//virtual
void LLFloaterIM::addFloater(LLFloater* floaterp, BOOL select_added_floater, LLTabContainer::eInsertionPoint insertion_point)
{
/*
Code removed via patch from VWR-1626
// this code is needed to fix the bug where new IMs received will resize the IM floater.
// SL-29075, SL-24556, and others
LLRect parent_rect = getRect();
S32 dheight = LLFLOATER_HEADER_SIZE + TABCNTR_HEADER_HEIGHT;
LLRect rect(0, parent_rect.getHeight()-dheight, parent_rect.getWidth(), 0);
floaterp->reshape(rect.getWidth(), rect.getHeight(), TRUE);
*/
LLMultiFloater::addFloater(floaterp, select_added_floater, insertion_point);
}

View File

@ -25,10 +25,20 @@
#include "llfasttimer.h"
LLMemoryView::LLMemoryView(const std::string& name, const LLRect& rect)
: LLView(name, rect, TRUE)
: LLView(name, rect, TRUE),
mDelay(120)
{
setVisible(FALSE);
mDumpTimer.reset();
#ifdef MEM_DUMP_DATA
// clear out file.
FILE *dump = fopen("memusagedump.txt", "w");
fclose(dump);
#endif
}
LLMemoryView::~LLMemoryView()
@ -176,7 +186,7 @@ void LLMemoryView::draw()
peak += maxbytes;
S32 mbytes = bytes >> 20;
tdesc = llformat("%s [%4d MB]",mtv_display_table[i].desc,mbytes);
tdesc = llformat("%s [%4d MB] in %06d NEWS",mtv_display_table[i].desc,mbytes, LLMemType::sNewCount[tidx]);
LLFontGL::sMonospace->renderUTF8(tdesc, 0, x, y, LLColor4::white, LLFontGL::LEFT, LLFontGL::TOP);
y -= (texth + 2);
@ -219,7 +229,46 @@ void LLMemoryView::draw()
y -= (texth + 2);
}
dumpData();
#endif
LLView::draw();
}
void LLMemoryView::setDataDumpInterval(float delay)
{
mDelay = delay;
}
void LLMemoryView::dumpData()
{
#if MEM_TRACK_TYPE && MEM_DUMP_DATA
if (mDelay && (mDumpTimer.getElapsedTimeF32() > mDelay ))
{
// reset timer
mDumpTimer.reset();
// append dump info to text file
FILE *dump = fopen("memusagedump.txt", "a");
if (dump)
{
// write out total memory usage
fprintf (dump, "Total memory in use = %09d (%03d MB)\n", LLMemType::sTotalMem, LLMemType::sTotalMem>>20);
fprintf (dump, "High Water Mark = %09d (%03d MB)\n\n", LLMemType::sMaxTotalMem, LLMemType::sMaxTotalMem>>20);
// dump out usage of 'new' for each memory type
for (S32 i=0; i<LLMemType::MTYPE_NUM_TYPES; i++)
{
if (LLMemType::sMemCount[i])
{
std::string outData = llformat("MEM: % 20s %09d %03d MB (%09d %03d MB) in %06d News", LLMemType::sTypeDesc[i], LLMemType::sMemCount[i], LLMemType::sMemCount[i]>>20, LLMemType::sMaxMemCount[i], LLMemType::sMaxMemCount[i]>>20, LLMemType::sNewCount[i]);
fprintf (dump, "%s\n", outData.c_str());
}
}
fprintf (dump, "\n\n");
fclose(dump);
}
}
#endif
}

View File

@ -25,6 +25,13 @@ public:
virtual BOOL handleHover(S32 x, S32 y, MASK mask);
virtual void draw();
private:
void setDataDumpInterval(float delay);
void dumpData();
float mDelay;
LLFrameTimer mDumpTimer;
private:
};

View File

@ -101,7 +101,11 @@ LLOverlayBar::LLOverlayBar(const std::string& name, const LLRect& rect)
if ( gAudiop )
{
mMusicRemote->setVolume ( gSavedSettings.getF32 ( "AudioLevelMusic" ) );
//HACK / NOT HACK
//maintenance patch - bhear obsoletes this, do not merge (poppy)
F32 audioLevelMusic = gSavedSettings.getF32 ( "AudioLevelMusic" );
mMusicRemote->setVolume ( audioLevelMusic );
gAudiop->setInternetStreamGain ( audioLevelMusic );
mMusicRemote->setTransportState ( LLMediaRemoteCtrl::Stop, FALSE );
};

View File

@ -15,6 +15,7 @@
#include "llmemory.h"
#include "llviewerimage.h"
#include "llstring.h"
#include "llmd5.h"
class LLTextBox;
class LLLineEditor;

View File

@ -2029,6 +2029,13 @@ void LLLiveLSLEditor::saveIfNeeded()
return;
}
LLString utf8text = mScriptEd->mEditor->getText();
// Special case for a completely empty script - stuff in one space so it can store properly. See SL-46889
if ( utf8text.size() == 0 )
{
utf8text = " ";
}
fputs(utf8text.c_str(), fp);
fclose(fp);
fp = NULL;

View File

@ -527,7 +527,7 @@ BOOL LLSelectMgr::removeObjectFromSelections(const LLUUID &id)
return object_found;
}
void LLSelectMgr::deselectObjectAndFamily(LLViewerObject* object, BOOL send_to_sim)
void LLSelectMgr::deselectObjectAndFamily(LLViewerObject* object, BOOL send_to_sim, BOOL include_entire_object)
{
// bail if nothing selected or if object wasn't selected in the first place
if(!object) return;
@ -535,7 +535,30 @@ void LLSelectMgr::deselectObjectAndFamily(LLViewerObject* object, BOOL send_to_s
// Collect all of the objects, and remove them
LLDynamicArray<LLViewerObject*> objects;
object = (LLViewerObject*)object->getRoot();
if (include_entire_object)
{
// Since we're selecting a family, start at the root, but
// don't include an avatar.
LLViewerObject* root = object;
while(!root->isAvatar() && root->getParent() && !root->isJointChild())
{
LLViewerObject* parent = (LLViewerObject*)root->getParent();
if (parent->isAvatar())
{
break;
}
root = parent;
}
object = root;
}
else
{
object = (LLViewerObject*)object->getRoot();
}
object->addThisAndAllChildren(objects);
remove(objects);
@ -5734,6 +5757,12 @@ BOOL LLSelectMgr::canSelectObject(LLViewerObject* object)
return TRUE;
}
BOOL LLSelectMgr::setForceSelection(BOOL force)
{
std::swap(mForceSelection,force);
return force;
}
LLObjectSelection::LLObjectSelection() :
std::list<LLSelectNode*>(),
LLRefCount(),

View File

@ -219,7 +219,8 @@ public:
void updateEffects(); // Update HUD effects
void overrideObjectUpdates();
void setForceSelection(BOOL force) { mForceSelection = force; }
// Returns the previous value of mForceSelection
BOOL setForceSelection(BOOL force);
////////////////////////////////////////////////////////////////
// Selection methods
@ -253,7 +254,7 @@ public:
////////////////////////////////////////////////////////////////
void deselectObjectOnly(LLViewerObject* object, BOOL send_to_sim = TRUE);
void deselectObjectAndFamily(LLViewerObject* object, BOOL send_to_sim = TRUE);
void deselectObjectAndFamily(LLViewerObject* object, BOOL send_to_sim = TRUE, BOOL include_entire_object = FALSE);
// Send deselect messages to simulator, then clear the list
void deselectAll();

View File

@ -763,12 +763,7 @@ BOOL idle_startup()
LLFile::mkdir(gDirUtilp->getChatLogsDir().c_str());
LLFile::mkdir(gDirUtilp->getPerAccountChatLogsDir().c_str());
#if LL_WINDOWS
if (gSavedSettings.getBOOL("UseDebugLogin") && show_connect_box)
#else
if (show_connect_box)
#endif
{
LLString server_label;
S32 domain_name_index;
@ -779,10 +774,7 @@ BOOL idle_startup()
{
snprintf(gUserServerName, MAX_STRING, "%s", server_label.c_str()); /* Flawfinder: ignore */
}
}
if (show_connect_box)
{
LLString location;
LLPanelLogin::getLocation( location );
LLURLSimString::setString( location );
@ -1139,8 +1131,10 @@ BOOL idle_startup()
case LLUserAuth::E_COULDNT_RESOLVE_HOST:
case LLUserAuth::E_SSL_PEER_CERTIFICATE:
case LLUserAuth::E_UNHANDLED_ERROR:
case LLUserAuth::E_SSL_CACERT:
case LLUserAuth::E_SSL_CONNECT_ERROR:
default:
if (auth_uri_num >= (int) auth_uris.size())
if (auth_uri_num >= (int) auth_uris.size() - 1)
{
emsg << "Unable to connect to " << gSecondLife << ".\n";
emsg << gUserAuthp->errorMessage();
@ -1150,20 +1144,6 @@ BOOL idle_startup()
auth_desc = s.str();
gStartupState = STATE_LOGIN_AUTHENTICATE;
auth_uri_num++;
return do_normal_idle;
}
break;
case LLUserAuth::E_SSL_CACERT:
case LLUserAuth::E_SSL_CONNECT_ERROR:
if (auth_uri_num >= (int) auth_uris.size())
{
emsg << "Unable to establish a secure connection to the login server.\n";
emsg << gUserAuthp->errorMessage();
} else {
std::ostringstream s;
s << "Logging in (attempt " << (auth_uri_num + 1) << "). ";
auth_desc = s.str();
gStartupState = STATE_LOGIN_AUTHENTICATE;
auth_uri_num++;
return do_normal_idle;
}
@ -2342,9 +2322,15 @@ BOOL idle_startup()
void login_show()
{
llinfos << "Initializing Login Screen" << llendl;
#ifdef LL_RELEASE_FOR_DOWNLOAD
BOOL bUseDebugLogin = gSavedSettings.getBOOL("UseDebugLogin");
#else
BOOL bUseDebugLogin = TRUE;
#endif
LLPanelLogin::show( gViewerWindow->getVirtualWindowRect(),
gSavedSettings.getBOOL("UseDebugLogin"),
bUseDebugLogin,
login_callback, NULL );
llinfos << "Decoding Images" << llendl;

View File

@ -107,7 +107,7 @@ protected:
static std::vector<std::string> sDays;
static std::vector<std::string> sMonths;
static const U32 LLStatusBar::MAX_DATE_STRING_LENGTH;
static const U32 MAX_DATE_STRING_LENGTH;
};
// *HACK: Status bar owns your cached money balance. JC

View File

@ -115,7 +115,7 @@ LLHandle<LLObjectSelection> LLToolSelect::handleObjectSelection(LLViewerObject *
}
else
{
gSelectMgr->deselectObjectAndFamily(object);
gSelectMgr->deselectObjectAndFamily(object, TRUE, TRUE);
}
}
else

View File

@ -30,16 +30,17 @@ extern LLPipeline gPipeline;
//-----------------------------------------------------------------------------
// LLViewerJointAttachment()
//-----------------------------------------------------------------------------
LLViewerJointAttachment::LLViewerJointAttachment()
LLViewerJointAttachment::LLViewerJointAttachment() :
mJoint(NULL),
mAttachedObject(NULL),
mAttachmentDirty(FALSE),
mVisibleInFirst(FALSE),
mGroup(0),
mIsHUDAttachment(FALSE),
mPieSlice(-1)
{
mJoint = NULL;
mAttachedObject = NULL;
mAttachmentDirty = FALSE;
mGroup = 0;
mUpdateXform = FALSE;
mIsHUDAttachment = FALSE;
mValid = FALSE;
mPieSlice = -1;
mUpdateXform = FALSE;
}
//-----------------------------------------------------------------------------

View File

@ -715,7 +715,7 @@ void init_client_menu(LLMenuGL* menu)
// neither of these works particularly well at the moment
/*menu->append(new LLMenuItemCallGL( "Reload UI XML", &reload_ui,
NULL, NULL, 'R', MASK_ALT | MASK_CONTROL ) );*/
NULL, NULL) );*/
/*menu->append(new LLMenuItemCallGL("Reload settings/colors",
&handle_reload_settings, NULL, NULL));*/
menu->append(new LLMenuItemCallGL("Reload personal setting overrides",
@ -873,7 +873,7 @@ void init_client_menu(LLMenuGL* menu)
(void*)"LimitSelectDistance"));
menu->append(new LLMenuItemToggleGL("Disable Camera Constraints",
&LLViewerCamera::sDisableCameraConstraints));
&LLViewerCamera::sDisableCameraConstraints, 'C', MASK_ALT | MASK_CONTROL ));
menu->append(new LLMenuItemCheckGL("Joystick Flycam",
&handle_toggle_flycam,NULL,&check_flycam,NULL));
@ -1075,39 +1075,39 @@ void init_debug_rendering_menu(LLMenuGL* menu)
sub_menu->append(new LLMenuItemCheckGL("UI",
&LLPipeline::toggleRenderDebugFeature, NULL,
&LLPipeline::toggleRenderDebugFeatureControl,
(void*)LLPipeline::RENDER_DEBUG_FEATURE_UI, '1', MASK_ALT|MASK_CONTROL));
(void*)LLPipeline::RENDER_DEBUG_FEATURE_UI, KEY_F1, MASK_ALT|MASK_CONTROL));
sub_menu->append(new LLMenuItemCheckGL("Selected",
&LLPipeline::toggleRenderDebugFeature, NULL,
&LLPipeline::toggleRenderDebugFeatureControl,
(void*)LLPipeline::RENDER_DEBUG_FEATURE_SELECTED, '2', MASK_ALT|MASK_CONTROL));
(void*)LLPipeline::RENDER_DEBUG_FEATURE_SELECTED, KEY_F2, MASK_ALT|MASK_CONTROL));
sub_menu->append(new LLMenuItemCheckGL("Highlighted",
&LLPipeline::toggleRenderDebugFeature, NULL,
&LLPipeline::toggleRenderDebugFeatureControl,
(void*)LLPipeline::RENDER_DEBUG_FEATURE_HIGHLIGHTED, '3', MASK_ALT|MASK_CONTROL));
(void*)LLPipeline::RENDER_DEBUG_FEATURE_HIGHLIGHTED, KEY_F3, MASK_ALT|MASK_CONTROL));
sub_menu->append(new LLMenuItemCheckGL("Dynamic Textures",
&LLPipeline::toggleRenderDebugFeature, NULL,
&LLPipeline::toggleRenderDebugFeatureControl,
(void*)LLPipeline::RENDER_DEBUG_FEATURE_DYNAMIC_TEXTURES, '4', MASK_ALT|MASK_CONTROL));
(void*)LLPipeline::RENDER_DEBUG_FEATURE_DYNAMIC_TEXTURES, KEY_F4, MASK_ALT|MASK_CONTROL));
sub_menu->append(new LLMenuItemCheckGL( "Foot Shadows",
&LLPipeline::toggleRenderDebugFeature, NULL,
&LLPipeline::toggleRenderDebugFeatureControl,
(void*)LLPipeline::RENDER_DEBUG_FEATURE_FOOT_SHADOWS, '5', MASK_ALT|MASK_CONTROL));
(void*)LLPipeline::RENDER_DEBUG_FEATURE_FOOT_SHADOWS, KEY_F5, MASK_ALT|MASK_CONTROL));
sub_menu->append(new LLMenuItemCheckGL("Fog",
&LLPipeline::toggleRenderDebugFeature, NULL,
&LLPipeline::toggleRenderDebugFeatureControl,
(void*)LLPipeline::RENDER_DEBUG_FEATURE_FOG, '6', MASK_ALT|MASK_CONTROL));
(void*)LLPipeline::RENDER_DEBUG_FEATURE_FOG, KEY_F6, MASK_ALT|MASK_CONTROL));
sub_menu->append(new LLMenuItemCheckGL("Palletized Textures",
&LLPipeline::toggleRenderDebugFeature, NULL,
&LLPipeline::toggleRenderDebugFeatureControl,
(void*)LLPipeline::RENDER_DEBUG_FEATURE_PALETTE, '7', MASK_ALT|MASK_CONTROL));
(void*)LLPipeline::RENDER_DEBUG_FEATURE_PALETTE, KEY_F7, MASK_ALT|MASK_CONTROL));
sub_menu->append(new LLMenuItemCheckGL("Test FRInfo",
&LLPipeline::toggleRenderDebugFeature, NULL,
&LLPipeline::toggleRenderDebugFeatureControl,
(void*)LLPipeline::RENDER_DEBUG_FEATURE_FR_INFO, '8', MASK_ALT|MASK_CONTROL));
(void*)LLPipeline::RENDER_DEBUG_FEATURE_FR_INFO, KEY_F8, MASK_ALT|MASK_CONTROL));
sub_menu->append(new LLMenuItemCheckGL( "Flexible Objects",
&LLPipeline::toggleRenderDebugFeature, NULL,
&LLPipeline::toggleRenderDebugFeatureControl,
(void*)LLPipeline::RENDER_DEBUG_FEATURE_FLEXIBLE, '9', MASK_ALT|MASK_CONTROL));
(void*)LLPipeline::RENDER_DEBUG_FEATURE_FLEXIBLE, KEY_F9, MASK_ALT|MASK_CONTROL));
sub_menu->createJumpKeys();
/////////////////////////////
@ -1279,7 +1279,7 @@ void init_debug_avatar_menu(LLMenuGL* menu)
menu->append(new LLMenuItemToggleGL( "Display Agent Target", &LLAgent::sDebugDisplayTarget));
menu->append(new LLMenuItemToggleGL( "Debug Rotation", &gDebugAvatarRotation));
menu->append(new LLMenuItemCallGL("Dump Attachments", handle_dump_attachments));
menu->append(new LLMenuItemCallGL("Rebake Textures", handle_rebake_textures));
menu->append(new LLMenuItemCallGL("Rebake Textures", handle_rebake_textures, NULL, NULL, 'R', MASK_ALT | MASK_CONTROL ));
#ifndef LL_RELEASE_FOR_DOWNLOAD
menu->append(new LLMenuItemCallGL("Debug Avatar Textures", handle_debug_avatar_textures, NULL, NULL, 'A', MASK_SHIFT|MASK_CONTROL|MASK_ALT));
menu->append(new LLMenuItemCallGL("Dump Local Textures", handle_dump_avatar_local_textures, NULL, NULL, 'M', MASK_SHIFT|MASK_ALT ));
@ -2322,10 +2322,11 @@ void handle_buy_object(LLSaleInfo sale_info)
return;
}
if(sale_info.getSalePrice() > gStatusBar->getBalance())
S32 price = sale_info.getSalePrice();
if (price > 0 && price > gStatusBar->getBalance())
{
LLFloaterBuyCurrency::buyCurrency(
"This object costs", sale_info.getSalePrice());
LLFloaterBuyCurrency::buyCurrency("This object costs", price);
return;
}

View File

@ -43,6 +43,7 @@
#include "message.h"
#include "sound_ids.h"
#include "lltimer.h"
#include "llmd5.h"
#include "llagent.h"
#include "llcallingcard.h"

View File

@ -41,7 +41,11 @@
#include "u64.h"
#include "llviewerimagelist.h"
#include "lldatapacker.h"
#include <zlib/zlib.h>
#ifdef LL_STANDALONE
#include <zlib.h>
#else
#include "zlib/zlib.h"
#endif
#include "object_flags.h"
extern BOOL gVelocityInterpolate;

View File

@ -160,8 +160,7 @@ LLViewerParcelMgr::~LLViewerParcelMgr()
delete[] mCollisionSegments;
mCollisionSegments = NULL;
// weird, this crashes if I use an array delete on it!
delete sPackedOverlay;
delete[] sPackedOverlay;
sPackedOverlay = NULL;
delete[] mAgentParcelOverlay;

View File

@ -21,7 +21,7 @@
#include "llworld.h"
#include "pipeline.h"
const S32 MAX_PART_COUNT = 4096;
const S32 MAX_PART_COUNT = 8192; // VWR-1105
const F32 PART_SIM_BOX_SIDE = 16.f;
const F32 PART_SIM_BOX_OFFSET = 0.5f*PART_SIM_BOX_SIDE;

View File

@ -285,6 +285,12 @@ void LLViewerPartSourceScript::update(const F32 dt)
//llwarns << "Unknown source pattern " << (S32)mPartSysData.mPattern << llendl;
}
if (part->mFlags & LLPartData::LL_PART_FOLLOW_SRC_MASK || // SVC-193, VWR-717
part->mFlags & LLPartData::LL_PART_TARGET_LINEAR_MASK)
{
mPartSysData.mBurstRadius = 0;
}
gWorldPointer->mPartSim.addPart(part);
}

View File

@ -72,7 +72,6 @@
#include "llmap.h"
#include "llmemory.h"
#include "llnametable.h"
#include "llpagemem.h"
#include "llpriqueuemap.h"
#include "llprocessor.h"
#include "llptrskiplist.h"
@ -125,7 +124,6 @@
#include "llcoordframe.h"
#include "llcrc.h"
#include "llinterp.h"
#include "llmd5.h"
#include "llperlin.h"
#include "llplane.h"
#include "llquantize.h"

View File

@ -301,89 +301,15 @@ void LLViewerRegion::sendReliableMessage()
gMessageSystem->sendReliable(mHost);
}
void LLViewerRegion::setAllowDamage(BOOL b)
void LLViewerRegion::setFlags(BOOL b, U32 flags)
{
if (b)
{
mRegionFlags |= REGION_FLAGS_ALLOW_DAMAGE;
mRegionFlags |= flags;
}
else
{
mRegionFlags &= ~REGION_FLAGS_ALLOW_DAMAGE;
}
}
void LLViewerRegion::setAllowLandmark(BOOL b)
{
if (b)
{
mRegionFlags |= REGION_FLAGS_ALLOW_LANDMARK;
}
else
{
mRegionFlags &= ~REGION_FLAGS_ALLOW_LANDMARK;
}
}
void LLViewerRegion::setAllowSetHome(BOOL b)
{
if (b)
{
mRegionFlags |= REGION_FLAGS_ALLOW_SET_HOME;
}
else
{
mRegionFlags &= ~REGION_FLAGS_ALLOW_SET_HOME;
}
}
void LLViewerRegion::setResetHomeOnTeleport(BOOL b)
{
if (b)
{
mRegionFlags |= REGION_FLAGS_RESET_HOME_ON_TELEPORT;
}
else
{
mRegionFlags &= ~REGION_FLAGS_RESET_HOME_ON_TELEPORT;
}
}
void LLViewerRegion::setSunFixed(BOOL b)
{
if (b)
{
mRegionFlags |= REGION_FLAGS_SUN_FIXED;
}
else
{
mRegionFlags &= ~REGION_FLAGS_SUN_FIXED;
}
}
void LLViewerRegion::setBlockFly(BOOL b)
{
if (b)
{
mRegionFlags |= REGION_FLAGS_BLOCK_FLY;
}
else
{
mRegionFlags &= ~REGION_FLAGS_BLOCK_FLY;
}
}
void LLViewerRegion::setAllowDirectTeleport(BOOL b)
{
if (b)
{
mRegionFlags |= REGION_FLAGS_ALLOW_DIRECT_TELEPORT;
}
else
{
mRegionFlags &= ~REGION_FLAGS_ALLOW_DIRECT_TELEPORT;
mRegionFlags &= ~flags;
}
}

View File

@ -63,13 +63,14 @@ public:
void setOriginGlobal(const LLVector3d &origin);
void setAgentOffset(const LLVector3d &offset);
void setAllowDamage(BOOL b);
void setAllowLandmark(BOOL b);
void setAllowSetHome(BOOL b);
void setResetHomeOnTeleport(BOOL b);
void setSunFixed(BOOL b);
void setBlockFly(BOOL b);
void setAllowDirectTeleport(BOOL b);
void setAllowDamage(BOOL b) { setFlags(b, REGION_FLAGS_ALLOW_DAMAGE); }
void setAllowLandmark(BOOL b) { setFlags(b, REGION_FLAGS_ALLOW_LANDMARK); }
void setAllowSetHome(BOOL b) { setFlags(b, REGION_FLAGS_ALLOW_SET_HOME); }
void setResetHomeOnTeleport(BOOL b) { setFlags(b, REGION_FLAGS_RESET_HOME_ON_TELEPORT); }
void setSunFixed(BOOL b) { setFlags(b, REGION_FLAGS_SUN_FIXED); }
void setBlockFly(BOOL b) { setFlags(b, REGION_FLAGS_BLOCK_FLY); }
void setAllowDirectTeleport(BOOL b) { setFlags(b, REGION_FLAGS_ALLOW_DIRECT_TELEPORT); }
inline BOOL getAllowDamage() const;
inline BOOL getAllowLandmark() const;
@ -228,6 +229,7 @@ public:
protected:
void disconnectAllNeighbors();
void initStats();
void setFlags(BOOL b, U32 flags);
public:
LLWind mWind;

View File

@ -1279,7 +1279,9 @@ BOOL LLViewerWindow::handleActivate(LLWindow *window, BOOL activated)
else
{
mActive = FALSE;
gAgent.setAFK();
if (gAllowIdleAFK) {
gAgent.setAFK();
}
send_agent_pause();
if (mWindow->getFullscreen() && !mIgnoreActivate)
{

View File

@ -4183,7 +4183,7 @@ void LLVOAvatar::updateTextures(LLAgent &agent)
if( render_avatar )
{
mShadowImagep->addTextureStats(mPixelArea, 1.f);
mShadowImagep->addTextureStats(mPixelArea);
}
}
@ -5790,7 +5790,7 @@ BOOL LLVOAvatar::attachObject(LLViewerObject *viewer_object)
{
LLViewerJointAttachment* attachment = getTargetAttachmentPoint(viewer_object);
if (!attachment->addObject(viewer_object))
if (!attachment || !attachment->addObject(viewer_object))
{
return FALSE;
}

View File

@ -316,16 +316,13 @@ void LLVOGrass::setPixelAreaAndAngle(LLAgent &agent)
// BUG could speed this up by caching the relative_position and range calculations
void LLVOGrass::updateTextures(LLAgent &agent)
{
F32 texel_area_ratio = 1.f;
F32 cos_angle = 1.f;
if (getTEImage(0))
{
if (gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_TEXTURE_AREA))
{
setDebugText(llformat("%4.0f", fsqrtf(mPixelArea)));
}
getTEImage(0)->addTextureStats(mPixelArea, texel_area_ratio, cos_angle);
getTEImage(0)->addTextureStats(mPixelArea);
}
}

View File

@ -415,7 +415,7 @@ void LLParticlePartition::addGeometryCount(LLSpatialGroup* group, U32& vertex_co
drawablep->updateFaceSize(j);
LLFace* facep = drawablep->getFace(j);
if (!facep->hasGeometry())
if ( !facep || !facep->hasGeometry())
{
continue;
}

View File

@ -386,15 +386,13 @@ void LLVOTree::setPixelAreaAndAngle(LLAgent &agent)
void LLVOTree::updateTextures(LLAgent &agent)
{
F32 texel_area_ratio = 1.f;
F32 cos_angle = 1.f;
if (mTreeImagep)
{
if (gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_TEXTURE_AREA))
{
setDebugText(llformat("%4.0f", fsqrtf(mPixelArea)));
}
mTreeImagep->addTextureStats(mPixelArea, texel_area_ratio, cos_angle);
mTreeImagep->addTextureStats(mPixelArea);
}
}

View File

@ -413,7 +413,7 @@ class Linux_i686Manifest(LinuxManifest):
self.path("libstdc++.so.6")
self.path("libuuid.so", "libuuid.so.1")
self.path("libSDL-1.2.so.0")
#self.path("libresolv.so") - don't bundle
self.path("libELFIO.so")
#self.path("libtcmalloc.so.0") - bugged
#self.path("libstacktrace.so.0") - probably bugged
self.path("libllkdu.so", "../bin/libllkdu.so") # llkdu goes in bin for some reason

View File

@ -11,8 +11,10 @@
#include <tut/tut.h>
#include "lltut.h"
#include "llbuffer.h"
#include "llerror.h"
#include "llmemtype.h"
namespace tut
{
struct buffer

View File

@ -1,11 +1,3 @@
/**
* @file resource.h
* @brief Resources for windows crash logger
*
* Copyright (c) 2003-$CurrentYear$, Linden Research, Inc.
* $License$
*/
//{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
// Used by win_crash_logger.rc

View File

@ -81,14 +81,10 @@ BEGIN
BS_AUTOCHECKBOX | WS_TABSTOP,4,106,89,13
LTEXT "Sending crash reports is the best way to help us improve the quality of %s.",
IDC_STATIC_MOTIVATION,4,38,288,8
LTEXT "If you continue to experience this problem, please try one of the following:",
LTEXT "If you continue to experience this problem, please try:",
IDC_STATIC,4,57,251,8
LTEXT "- Contact support by email at support@lindenlab.com",
IDC_STATIC,4,67,179,8
LTEXT "- If you can log-in, please contact Live Help by using menu Help > Live Help.",
IDC_STATIC,4,87,249,8
LTEXT "- Search the Second Life Knowledge Base at http://secondlife.com/knowledgebase/",
IDC_STATIC,4,77,281,8,SS_NOTIFY
LTEXT "- Contacting support by visiting http://www.secondlife.com/support",
IDC_STATIC,4,67,231,8
END
IDD_PREVREPORTBOX DIALOG 100, 100, 232, 213