diff options
Diffstat (limited to 'indra/newview/llinventorybridge.h')
-rw-r--r-- | indra/newview/llinventorybridge.h | 66 |
1 files changed, 33 insertions, 33 deletions
diff --git a/indra/newview/llinventorybridge.h b/indra/newview/llinventorybridge.h index 6ddd77284a..a342a2da14 100644 --- a/indra/newview/llinventorybridge.h +++ b/indra/newview/llinventorybridge.h @@ -2,25 +2,31 @@ * @file llinventorybridge.h * @brief Implementation of the Inventory-Folder-View-Bridge classes. * - * $LicenseInfo:firstyear=2001&license=viewerlgpl$ - * Second Life Viewer Source Code - * Copyright (C) 2010, Linden Research, Inc. + * $LicenseInfo:firstyear=2001&license=viewergpl$ + * + * Copyright (c) 2001-2009, Linden Research, Inc. * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; - * version 2.1 of the License only. + * Second Life Viewer Source Code + * The source code in this file ("Source Code") is provided by Linden Lab + * to you under the terms of the GNU General Public License, version 2.0 + * ("GPL"), unless you have obtained a separate licensing agreement + * ("Other License"), formally executed by you and Linden Lab. Terms of + * the GPL can be found in doc/GPL-license.txt in this distribution, or + * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2 * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. + * There are special exceptions to the terms and conditions of the GPL as + * it is applied to this Source Code. View the full text of the exception + * in the file doc/FLOSS-exception.txt in this software distribution, or + * online at + * http://secondlifegrid.net/programs/open_source/licensing/flossexception * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + * By copying, modifying or distributing this software, you acknowledge + * that you have read and understood your obligations described above, + * and agree to abide by those obligations. * - * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA + * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO + * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, + * COMPLETENESS OR PERFORMANCE. * $/LicenseInfo$ */ @@ -68,6 +74,7 @@ public: U32 flags = 0x00); virtual ~LLInvFVBridge() {} + BOOL isInOutfitsSidePanel() const; // allow context menus to be customized for side panel BOOL canShare() const; //-------------------------------------------------------------------- @@ -116,7 +123,6 @@ 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. @@ -224,8 +230,8 @@ public: const LLUUID& uuid) : LLInvFVBridge(inventory, root, uuid), mCallingCards(FALSE), - mWearables(FALSE) - {} + mWearables(FALSE), + mMenu(NULL) {} BOOL dragItemIntoFolder(LLInventoryItem* inv_item, BOOL drop); BOOL dragCategoryIntoFolder(LLInventoryCategory* inv_category, BOOL drop); @@ -239,7 +245,7 @@ public: virtual LLFolderType::EType getPreferredType() const; virtual LLUIImagePtr getIcon() const; virtual LLUIImagePtr getOpenIcon() const; - static LLUIImagePtr getIcon(LLFolderType::EType preferred_type); + static LLUIImagePtr getIcon(LLFolderType::EType preferred_type, BOOL is_link = FALSE); virtual BOOL renameItem(const std::string& new_name); @@ -266,7 +272,6 @@ public: static void createWearable(LLFolderBridge* bridge, LLWearableType::EType type); LLViewerInventoryCategory* getCategory() const; - LLHandle<LLFolderBridge> getHandle() { mHandle.bind(this); return mHandle; } protected: //-------------------------------------------------------------------- @@ -289,6 +294,7 @@ protected: static void createNewEyes(void* user_data); BOOL checkFolderForContentsOfType(LLInventoryModel* model, LLInventoryCollectFunctor& typeToCheck); + BOOL areAnyContentsWorn(LLInventoryModel* model) const; void modifyOutfit(BOOL append); void determineFolderType(); @@ -300,17 +306,16 @@ protected: // Messy hacks for handling folder options //-------------------------------------------------------------------- public: - static LLHandle<LLFolderBridge> sSelf; + static LLFolderBridge* sSelf; static void staticFolderOptionsMenu(); void folderOptionsMenu(); private: - BOOL mCallingCards; - BOOL mWearables; - LLHandle<LLView> mMenu; - menuentry_vec_t mItems; - menuentry_vec_t mDisabledItems; - LLRootHandle<LLFolderBridge> mHandle; + BOOL mCallingCards; + BOOL mWearables; + LLMenuGL* mMenu; + menuentry_vec_t mItems; + menuentry_vec_t mDisabledItems; }; class LLTextureBridge : public LLItemBridge @@ -466,7 +471,6 @@ 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 ); @@ -599,12 +603,8 @@ BOOL move_inv_category_world_to_agent(const LLUUID& object_id, void* user_data = NULL); // Utility function to hide all entries except those in the list -// Can be called multiple times on the same menu (e.g. if multiple items -// are selected). If "append" is false, then only common enabled items -// are set as enabled. void hide_context_entries(LLMenuGL& menu, const menuentry_vec_t &entries_to_show, - const menuentry_vec_t &disabled_entries, - BOOL append = FALSE); + const menuentry_vec_t &disabled_entries); #endif // LL_LLINVENTORYBRIDGE_H |