diff options
| author | Mike Antipov <mantipov@productengine.com> | 2010-06-15 13:26:09 +0300 | 
|---|---|---|
| committer | Mike Antipov <mantipov@productengine.com> | 2010-06-15 13:26:09 +0300 | 
| commit | cfb9a6e3411b52d5916ea809c66d8412d90bfe4d (patch) | |
| tree | 3b6dbed2d7cb917b5cf8d5d79914f9553400d268 | |
| parent | 11903fab735d3eb3464bdec5cf11a1027fd2ac3f (diff) | |
| parent | a43c997d0a7209da7e1b3d42b3e3998498741764 (diff) | |
Merge from default branch
--HG--
branch : product-engine
| -rw-r--r-- | indra/llui/llfloater.cpp | 2 | ||||
| -rw-r--r-- | indra/llui/lltextbase.cpp | 4 | ||||
| -rw-r--r-- | indra/newview/CMakeLists.txt | 27 | ||||
| -rw-r--r-- | indra/newview/llfoldervieweventlistener.h | 2 | ||||
| -rw-r--r-- | indra/newview/llinventorybridge.h | 2 | ||||
| -rw-r--r-- | indra/newview/llinventoryfilter.cpp | 53 | ||||
| -rw-r--r-- | indra/newview/llinventoryfilter.h | 11 | ||||
| -rw-r--r-- | indra/newview/llinventorypanel.cpp | 5 | ||||
| -rw-r--r-- | indra/newview/llinventorypanel.h | 1 | ||||
| -rw-r--r-- | indra/newview/llpanelobjectinventory.cpp | 3 | ||||
| -rw-r--r-- | indra/newview/skins/default/xui/en/notifications.xml | 3 | ||||
| -rwxr-xr-x | indra/newview/viewer_manifest.py | 4 | 
12 files changed, 76 insertions, 41 deletions
| diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index 341debc9a8..9a56372e68 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -347,7 +347,7 @@ void LLFloater::layoutDragHandle()  	{  		rect = getLocalRect();  	} -	mDragHandle->setRect(rect); +	mDragHandle->setShape(rect);  	updateTitleButtons();  } diff --git a/indra/llui/lltextbase.cpp b/indra/llui/lltextbase.cpp index 1a4b804ce4..3c6c7d3e82 100644 --- a/indra/llui/lltextbase.cpp +++ b/indra/llui/lltextbase.cpp @@ -2803,13 +2803,13 @@ S32	 LLImageTextSegment::getNumChars(S32 num_pixels, S32 segment_offset, S32 lin  {  	LLUIImagePtr image = mStyle->getImage();  	S32 image_width = image->getWidth(); -	if(num_pixels>image_width + IMAGE_HPAD) +	if(line_offset == 0 || num_pixels>image_width + IMAGE_HPAD)  	{  		return 1;  	} -  	return 0;  } +  F32	LLImageTextSegment::draw(S32 start, S32 end, S32 selection_start, S32 selection_end, const LLRect& draw_rect)  {  	if ( (start >= 0) && (end <= mEnd - mStart)) diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index 53c6369534..24811db3cb 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -1773,40 +1773,19 @@ if (DARWIN)          COMMAND ${PYTHON_EXECUTABLE}          ARGS            ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py -          --grid=${GRID} -          --buildtype=${CMAKE_BUILD_TYPE} -          --configuration=${CMAKE_CFG_INTDIR} -          --channel=${VIEWER_CHANNEL} -          --login_channel=${VIEWER_LOGIN_CHANNEL} -          --source=${CMAKE_CURRENT_SOURCE_DIR}            --artwork=${ARTWORK_DIR}            --build=${CMAKE_CURRENT_BINARY_DIR} -          --dest=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${product}.app -          --touch=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/.${product}.touched -        DEPENDS -          ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py -      ) - - -      add_custom_command( -        TARGET package POST_BUILD -        COMMAND ${PYTHON_EXECUTABLE} -        ARGS -          ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py -          --grid=${GRID}            --buildtype=${CMAKE_BUILD_TYPE} -          --configuration=${CMAKE_CFG_INTDIR}            --channel=${VIEWER_CHANNEL} +          --configuration=${CMAKE_CFG_INTDIR} +          --dest=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${product}.app +          --grid=${GRID}            --login_channel=${VIEWER_LOGIN_CHANNEL}            --source=${CMAKE_CURRENT_SOURCE_DIR} -          --artwork=${ARTWORK_DIR} -          --build=${CMAKE_CURRENT_BINARY_DIR} -          --dest=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${product}.app            --touch=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/.${product}.touched          DEPENDS            ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py        ) -    endif (PACKAGE)  endif (DARWIN) diff --git a/indra/newview/llfoldervieweventlistener.h b/indra/newview/llfoldervieweventlistener.h index a2ef8c1d12..82f8a10cf3 100644 --- a/indra/newview/llfoldervieweventlistener.h +++ b/indra/newview/llfoldervieweventlistener.h @@ -37,6 +37,7 @@  #include "llinventorytype.h"  #include "llpermissionsflags.h"  #include "llpointer.h" +#include "llwearabletype.h"  class LLFolderViewItem; @@ -89,6 +90,7 @@ public:  	virtual BOOL hasChildren() const = 0;  	virtual LLInventoryType::EType getInventoryType() const = 0;  	virtual void performAction(LLInventoryModel* model, std::string action) = 0; +	virtual LLWearableType::EType getWearableType() const = 0;  	// This method should be called when a drag begins. returns TRUE  	// if the drag can begin, otherwise FALSE. diff --git a/indra/newview/llinventorybridge.h b/indra/newview/llinventorybridge.h index d97dfd535e..757808eb93 100644 --- a/indra/newview/llinventorybridge.h +++ b/indra/newview/llinventorybridge.h @@ -123,6 +123,7 @@ public:  							EDragAndDropType cargo_type,  							void* cargo_data) { return FALSE; }  	virtual LLInventoryType::EType getInventoryType() const { return mInvType; } +	virtual LLWearableType::EType getWearableType() const { return LLWearableType::WT_NONE; }  	//--------------------------------------------------------------------  	// Convenience functions for adding various common menu options. @@ -471,6 +472,7 @@ public:  	virtual void	buildContextMenu(LLMenuGL& menu, U32 flags);  	virtual std::string getLabelSuffix() const;  	virtual BOOL renameItem(const std::string& new_name); +	virtual LLWearableType::EType getWearableType() const { return mWearableType; }  	static void		onWearOnAvatar( void* userdata );	// Access to wearOnAvatar() from menu  	static BOOL		canWearOnAvatar( void* userdata ); diff --git a/indra/newview/llinventoryfilter.cpp b/indra/newview/llinventoryfilter.cpp index c90919e8fd..6e829f2dc2 100644 --- a/indra/newview/llinventoryfilter.cpp +++ b/indra/newview/llinventoryfilter.cpp @@ -49,6 +49,7 @@  LLInventoryFilter::FilterOps::FilterOps() :  	mFilterObjectTypes(0xffffffffffffffffULL),  	mFilterCategoryTypes(0xffffffffffffffffULL), +	mFilterWearableTypes(0xffffffffffffffffULL),  	mMinDate(time_min()),  	mMaxDate(time_max()),  	mHoursAgo(0), @@ -139,8 +140,6 @@ BOOL LLInventoryFilter::checkAgainstFilterType(const LLFolderViewItem* item) con  			return FALSE;  		}  	} -	// -	////////////////////////////////////////////////////////////////////////////////  	//////////////////////////////////////////////////////////////////////////////// @@ -164,8 +163,6 @@ BOOL LLInventoryFilter::checkAgainstFilterType(const LLFolderViewItem* item) con  		if ((1LL << cat->getPreferredType() & mFilterOps.mFilterCategoryTypes) == U64(0))  			return FALSE;  	} -	// -	////////////////////////////////////////////////////////////////////////////////  	//////////////////////////////////////////////////////////////////////////////// @@ -178,8 +175,6 @@ BOOL LLInventoryFilter::checkAgainstFilterType(const LLFolderViewItem* item) con  		if (object->getLinkedUUID() != mFilterOps.mFilterUUID)  			return FALSE;  	} -	// -	////////////////////////////////////////////////////////////////////////////////  	//////////////////////////////////////////////////////////////////////////////// @@ -201,8 +196,18 @@ BOOL LLInventoryFilter::checkAgainstFilterType(const LLFolderViewItem* item) con  			listener->getCreationDate() > mFilterOps.mMaxDate)  			return FALSE;  	} -	// +  	//////////////////////////////////////////////////////////////////////////////// +	// FILTERTYPE_WEARABLE +	// Pass if this item is a wearable of the appropriate type +	if (filterTypes & FILTERTYPE_WEARABLE) +	{ +		LLWearableType::EType type = listener->getWearableType(); +		if ((0x1LL << type & mFilterOps.mFilterWearableTypes) == 0) +		{ +			return FALSE; +		} +	}  	return TRUE;  } @@ -238,6 +243,8 @@ std::string::size_type LLInventoryFilter::getStringMatchOffset() const  BOOL LLInventoryFilter::isNotDefault() const  {  	return mFilterOps.mFilterObjectTypes != mDefaultFilterOps.mFilterObjectTypes  +		|| mFilterOps.mFilterCategoryTypes != mDefaultFilterOps.mFilterCategoryTypes  +		|| mFilterOps.mFilterWearableTypes != mDefaultFilterOps.mFilterWearableTypes   		|| mFilterOps.mFilterTypes != FILTERTYPE_OBJECT  		|| mFilterSubString.size()   		|| mFilterOps.mPermissions != mDefaultFilterOps.mPermissions @@ -249,6 +256,8 @@ BOOL LLInventoryFilter::isNotDefault() const  BOOL LLInventoryFilter::isActive() const  {  	return mFilterOps.mFilterObjectTypes != 0xffffffffffffffffULL +		|| mFilterOps.mFilterCategoryTypes != 0xffffffffffffffffULL +		|| mFilterOps.mFilterWearableTypes != 0xffffffffffffffffULL  		|| mFilterOps.mFilterTypes != FILTERTYPE_OBJECT  		|| mFilterSubString.size()   		|| mFilterOps.mPermissions != PERM_NONE  @@ -322,7 +331,35 @@ void LLInventoryFilter::setFilterCategoryTypes(U64 types)  			setModified(FILTER_MORE_RESTRICTIVE);  		}  	} -	mFilterOps.mFilterTypes |= FILTERTYPE_CATEGORY; +	mFilterOps.mFilterTypes |= FILTERTYPE_OBJECT; +} + +void LLInventoryFilter::setFilterWearableTypes(U64 types) +{ +	if (mFilterOps.mFilterWearableTypes != types) +	{ +		// keep current items only if no type bits getting turned off +		BOOL fewer_bits_set = (mFilterOps.mFilterWearableTypes & ~types); +		BOOL more_bits_set = (~mFilterOps.mFilterWearableTypes & types); + +		mFilterOps.mFilterWearableTypes = types; +		if (more_bits_set && fewer_bits_set) +		{ +			// neither less or more restrive, both simultaneously +			// so we need to filter from scratch +			setModified(FILTER_RESTART); +		} +		else if (more_bits_set) +		{ +			// target is only one of all requested types so more type bits == less restrictive +			setModified(FILTER_LESS_RESTRICTIVE); +		} +		else if (fewer_bits_set) +		{ +			setModified(FILTER_MORE_RESTRICTIVE); +		} +	} +	mFilterOps.mFilterTypes |= FILTERTYPE_WEARABLE;  }  void LLInventoryFilter::setFilterUUID(const LLUUID& object_id) diff --git a/indra/newview/llinventoryfilter.h b/indra/newview/llinventoryfilter.h index 3ef51baefc..f740a6b333 100644 --- a/indra/newview/llinventoryfilter.h +++ b/indra/newview/llinventoryfilter.h @@ -59,10 +59,11 @@ public:  	enum EFilterType  	{  		FILTERTYPE_NONE = 0, -		FILTERTYPE_OBJECT = 1,		// normal default search-by-object-type -		FILTERTYPE_CATEGORY = 2,	// search by folder type -		FILTERTYPE_UUID	= 4,		// find the object with UUID and any links to it -		FILTERTYPE_DATE = 8			// search by date range +		FILTERTYPE_OBJECT = 0x1 << 0,	// normal default search-by-object-type +		FILTERTYPE_CATEGORY = 0x1 << 1,	// search by folder type +		FILTERTYPE_UUID	= 0x1 << 2,		// find the object with UUID and any links to it +		FILTERTYPE_DATE = 0x1 << 3,		// search by date range +		FILTERTYPE_WEARABLE = 0x1 << 4	// search by wearable type  	};  	// REFACTOR: Change this to an enum. @@ -81,6 +82,7 @@ public:  	BOOL 				isFilterObjectTypesWith(LLInventoryType::EType t) const;  	void 				setFilterCategoryTypes(U64 types);  	void 				setFilterUUID(const LLUUID &object_id); +	void				setFilterWearableTypes(U64 types);  	void 				setFilterSubString(const std::string& string);  	const std::string& 	getFilterSubString(BOOL trim = FALSE) const; @@ -168,6 +170,7 @@ private:  		U32 			mFilterTypes;  		U64				mFilterObjectTypes; // For _OBJECT +		U64				mFilterWearableTypes;  		U64				mFilterCategoryTypes; // For _CATEGORY  		LLUUID      	mFilterUUID; // for UUID diff --git a/indra/newview/llinventorypanel.cpp b/indra/newview/llinventorypanel.cpp index 6b0103e0de..83c57d5bb2 100644 --- a/indra/newview/llinventorypanel.cpp +++ b/indra/newview/llinventorypanel.cpp @@ -226,6 +226,11 @@ void LLInventoryPanel::setFilterPermMask(PermissionMask filter_perm_mask)  	getFilter()->setFilterPermissions(filter_perm_mask);  } +void LLInventoryPanel::setFilterWearableTypes(U64 types) +{ +	getFilter()->setFilterWearableTypes(types); +} +  void LLInventoryPanel::setFilterSubString(const std::string& string)  {  	getFilter()->setFilterSubString(string); diff --git a/indra/newview/llinventorypanel.h b/indra/newview/llinventorypanel.h index 67c8904868..52e9ef799e 100644 --- a/indra/newview/llinventorypanel.h +++ b/indra/newview/llinventorypanel.h @@ -138,6 +138,7 @@ public:  	U32 getFilterObjectTypes() const { return mFolderRoot->getFilterObjectTypes(); }  	void setFilterPermMask(PermissionMask filter_perm_mask);  	U32 getFilterPermMask() const { return mFolderRoot->getFilterPermissions(); } +	void setFilterWearableTypes(U64 filter);  	void setFilterSubString(const std::string& string);  	const std::string getFilterSubString() { return mFolderRoot->getFilterSubString(); }  	void setSinceLogoff(BOOL sl); diff --git a/indra/newview/llpanelobjectinventory.cpp b/indra/newview/llpanelobjectinventory.cpp index ad3a5c2380..da809b7baa 100644 --- a/indra/newview/llpanelobjectinventory.cpp +++ b/indra/newview/llpanelobjectinventory.cpp @@ -135,6 +135,8 @@ public:  	virtual BOOL isUpToDate() const { return TRUE; }  	virtual BOOL hasChildren() const { return FALSE; }  	virtual LLInventoryType::EType getInventoryType() const { return LLInventoryType::IT_NONE; } +	virtual LLWearableType::EType getWearableType() const { return LLWearableType::WT_NONE; } +  	// LLDragAndDropBridge functionality  	virtual BOOL startDrag(EDragAndDropType* type, LLUUID* id) const;  	virtual BOOL dragOrDrop(MASK mask, BOOL drop, @@ -184,6 +186,7 @@ void LLTaskInvFVBridge::showProperties()  		floater->setObjectID(mPanel->getTaskUUID());  	}  	*/ +	  }  struct LLBuyInvItemData diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml index aca3b750c8..cf3097cb06 100644 --- a/indra/newview/skins/default/xui/en/notifications.xml +++ b/indra/newview/skins/default/xui/en/notifications.xml @@ -1397,8 +1397,7 @@ Unable to encode file: [FILE]     icon="alertmodal.tga"     name="CorruptedProtectedDataStore"     type="alertmodal"> -  We are unable to read your protected data so it is being reset. -   This may happen when you change network setup. +   We can't fill in your username and password.  This may happen when you change network setup      <usetemplate       name="okbutton" diff --git a/indra/newview/viewer_manifest.py b/indra/newview/viewer_manifest.py index 8d2525dd26..0fd3cf5b3b 100755 --- a/indra/newview/viewer_manifest.py +++ b/indra/newview/viewer_manifest.py @@ -559,6 +559,10 @@ class WindowsManifest(ViewerManifest):  class DarwinManifest(ViewerManifest): +    def is_packaging_viewer(self): +        # darwin requires full app bundle packaging even for debugging. +        return True +      def construct(self):          # copy over the build result (this is a no-op if run within the xcode script)          self.path(self.args['configuration'] + "/Second Life.app", dst="") | 
