PageRenderTime 32ms CodeModel.GetById 17ms RepoModel.GetById 0ms app.codeStats 0ms

/indra/newview/llinventoryicon.h

https://bitbucket.org/lindenlab/viewer-beta/
C++ Header | 102 lines | 62 code | 14 blank | 26 comment | 0 complexity | 996a2fcf4e4cb3351c5b4378a21edd9a MD5 | raw file
Possible License(s): LGPL-2.1
  1. /**
  2. * @file llinventoryfunctions.h
  3. * @brief Miscellaneous inventory-related functions and classes
  4. * class definition
  5. *
  6. * $LicenseInfo:firstyear=2001&license=viewerlgpl$
  7. * Second Life Viewer Source Code
  8. * Copyright (C) 2010, Linden Research, Inc.
  9. *
  10. * This library is free software; you can redistribute it and/or
  11. * modify it under the terms of the GNU Lesser General Public
  12. * License as published by the Free Software Foundation;
  13. * version 2.1 of the License only.
  14. *
  15. * This library is distributed in the hope that it will be useful,
  16. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  17. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  18. * Lesser General Public License for more details.
  19. *
  20. * You should have received a copy of the GNU Lesser General Public
  21. * License along with this library; if not, write to the Free Software
  22. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  23. *
  24. * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
  25. * $/LicenseInfo$
  26. */
  27. #ifndef LL_LLINVENTORYICON_H
  28. #define LL_LLINVENTORYICON_H
  29. #include "llassettype.h"
  30. #include "llinventorytype.h"
  31. #include "lluiimage.h"
  32. class LLInventoryIcon
  33. {
  34. public:
  35. enum EIconName
  36. {
  37. ICONNAME_TEXTURE,
  38. ICONNAME_SOUND,
  39. ICONNAME_CALLINGCARD_ONLINE,
  40. ICONNAME_CALLINGCARD_OFFLINE,
  41. ICONNAME_LANDMARK,
  42. ICONNAME_LANDMARK_VISITED,
  43. ICONNAME_SCRIPT,
  44. ICONNAME_CLOTHING,
  45. ICONNAME_OBJECT,
  46. ICONNAME_OBJECT_MULTI,
  47. ICONNAME_NOTECARD,
  48. ICONNAME_BODYPART,
  49. ICONNAME_SNAPSHOT,
  50. ICONNAME_BODYPART_SHAPE,
  51. ICONNAME_BODYPART_SKIN,
  52. ICONNAME_BODYPART_HAIR,
  53. ICONNAME_BODYPART_EYES,
  54. ICONNAME_CLOTHING_SHIRT,
  55. ICONNAME_CLOTHING_PANTS,
  56. ICONNAME_CLOTHING_SHOES,
  57. ICONNAME_CLOTHING_SOCKS,
  58. ICONNAME_CLOTHING_JACKET,
  59. ICONNAME_CLOTHING_GLOVES,
  60. ICONNAME_CLOTHING_UNDERSHIRT,
  61. ICONNAME_CLOTHING_UNDERPANTS,
  62. ICONNAME_CLOTHING_SKIRT,
  63. ICONNAME_CLOTHING_ALPHA,
  64. ICONNAME_CLOTHING_TATTOO,
  65. ICONNAME_ANIMATION,
  66. ICONNAME_GESTURE,
  67. ICONNAME_CLOTHING_PHYSICS,
  68. ICONNAME_LINKITEM,
  69. ICONNAME_LINKFOLDER,
  70. ICONNAME_MESH,
  71. ICONNAME_INVALID,
  72. ICONNAME_COUNT,
  73. ICONNAME_NONE = -1
  74. };
  75. static const std::string& getIconName(LLAssetType::EType asset_type,
  76. LLInventoryType::EType inventory_type = LLInventoryType::IT_NONE,
  77. U32 misc_flag = 0, // different meanings depending on item type
  78. BOOL item_is_multi = FALSE);
  79. static const std::string& getIconName(EIconName idx);
  80. static LLUIImagePtr getIcon(LLAssetType::EType asset_type,
  81. LLInventoryType::EType inventory_type = LLInventoryType::IT_NONE,
  82. U32 misc_flag = 0, // different meanings depending on item type
  83. BOOL item_is_multi = FALSE);
  84. static LLUIImagePtr getIcon(EIconName idx);
  85. protected:
  86. static EIconName assignWearableIcon(U32 misc_flag);
  87. };
  88. #endif // LL_LLINVENTORYICON_H