LLEmbeddedItems Class Reference

Collaboration diagram for LLEmbeddedItems:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 LLEmbeddedItems (const LLViewerTextEditor *editor)
 ~LLEmbeddedItems ()
void clear ()
bool empty ()
void bindEmbeddedChars (const LLFontGL *font)
void unbindEmbeddedChars (const LLFontGL *font)
BOOL insertEmbeddedItem (LLInventoryItem *item, llwchar *value, bool is_new)
BOOL removeEmbeddedItem (llwchar ext_char)
BOOL hasEmbeddedItem (llwchar ext_char)
void getEmbeddedItemList (std::vector< LLPointer< LLInventoryItem > > &items)
void addItems (const std::vector< LLPointer< LLInventoryItem > > &items)
llwchar getEmbeddedCharFromIndex (S32 index)
void removeUnusedChars ()
void copyUsedCharsToIndexed ()
S32 getIndexFromEmbeddedChar (llwchar wch)
void markSaved ()

Static Public Member Functions

static LLInventoryItemgetEmbeddedItem (llwchar ext_char)
static BOOL getEmbeddedItemSaved (llwchar ext_char)

Private Types

typedef std::map< llwchar,
embedded_info_t
item_map_t

Private Attributes

std::set< llwcharmEmbeddedUsedChars
std::vector< llwcharmEmbeddedIndexedChars
const LLViewerTextEditormEditor

Static Private Attributes

static item_map_t sEntries
static std::stack< llwcharsFreeEntries

Classes

struct  embedded_info_t

Detailed Description

Definition at line 137 of file llviewertexteditor.cpp.


Member Typedef Documentation

typedef std::map<llwchar, embedded_info_t > LLEmbeddedItems::item_map_t [private]

Definition at line 175 of file llviewertexteditor.cpp.


Constructor & Destructor Documentation

LLEmbeddedItems::LLEmbeddedItems ( const LLViewerTextEditor editor  ) 

Definition at line 188 of file llviewertexteditor.cpp.

LLEmbeddedItems::~LLEmbeddedItems (  ) 

Definition at line 193 of file llviewertexteditor.cpp.

References clear().


Member Function Documentation

void LLEmbeddedItems::addItems ( const std::vector< LLPointer< LLInventoryItem > > &  items  ) 

Definition at line 450 of file llviewertexteditor.cpp.

References insertEmbeddedItem(), and mEmbeddedIndexedChars.

Referenced by LLViewerTextEditor::importStream().

void LLEmbeddedItems::bindEmbeddedChars ( const LLFontGL font  ) 

Definition at line 367 of file llviewertexteditor.cpp.

References LLAssetType::AT_ANIMATION, LLAssetType::AT_BODYPART, LLAssetType::AT_CLOTHING, LLAssetType::AT_GESTURE, LLAssetType::AT_LANDMARK, LLAssetType::AT_LSL_TEXT, LLAssetType::AT_NOTECARD, LLAssetType::AT_OBJECT, LLAssetType::AT_SOUND, LLAssetType::AT_TEXTURE, LLInventoryItem::getFlags(), LLViewerImageList::getImage(), LLInventoryItem::getInventoryType(), LLInventoryObject::getName(), LLControlGroup::getString(), LLInventoryObject::getType(), gImageList, gViewerArt, LLInventoryItem::II_FLAGS_LANDMARK_VISITED, LLInventoryItem::II_FLAGS_OBJECT_HAS_MULTIPLE_ITEMS, LLInventoryType::IT_SNAPSHOT, llassert, mEmbeddedUsedChars, MIPMAP_FALSE, sEntries, and TRUE.

Referenced by LLViewerTextEditor::bindEmbeddedChars().

void LLEmbeddedItems::clear (  ) 

Definition at line 198 of file llviewertexteditor.cpp.

References mEmbeddedIndexedChars, mEmbeddedUsedChars, and removeEmbeddedItem().

Referenced by LLViewerTextEditor::importStream(), and ~LLEmbeddedItems().

void LLEmbeddedItems::copyUsedCharsToIndexed (  ) 

Definition at line 322 of file llviewertexteditor.cpp.

References mEmbeddedIndexedChars, mEmbeddedUsedChars, and removeUnusedChars().

Referenced by LLViewerTextEditor::getEmbeddedText().

bool LLEmbeddedItems::empty (  ) 

Definition at line 211 of file llviewertexteditor.cpp.

References mEmbeddedUsedChars, and removeUnusedChars().

Referenced by LLViewerTextEditor::hasEmbeddedInventory().

llwchar LLEmbeddedItems::getEmbeddedCharFromIndex ( S32  index  ) 

Definition at line 292 of file llviewertexteditor.cpp.

References LL_UNKNOWN_CHAR, llendl, llwarns, mEmbeddedIndexedChars, and S32.

Referenced by LLViewerTextEditor::setASCIIEmbeddedText(), and LLViewerTextEditor::setEmbeddedText().

LLInventoryItem * LLEmbeddedItems::getEmbeddedItem ( llwchar  ext_char  )  [static]

Definition at line 265 of file llviewertexteditor.cpp.

References FIRST_EMBEDDED_CHAR, LAST_EMBEDDED_CHAR, NULL, and sEntries.

Referenced by getEmbeddedItemList(), LLViewerTextEditor::getEmbeddedItemToolTipAtPos(), LLViewerTextEditor::handleMouseDown(), LLViewerTextEditor::openEmbeddedItemAtPos(), and LLViewerTextEditor::pasteEmbeddedItem().

void LLEmbeddedItems::getEmbeddedItemList ( std::vector< LLPointer< LLInventoryItem > > &  items  ) 

Definition at line 468 of file llviewertexteditor.cpp.

References getEmbeddedItem(), and mEmbeddedUsedChars.

Referenced by LLViewerTextEditor::exportBuffer().

BOOL LLEmbeddedItems::getEmbeddedItemSaved ( llwchar  ext_char  )  [static]

Definition at line 279 of file llviewertexteditor.cpp.

References FALSE, FIRST_EMBEDDED_CHAR, LAST_EMBEDDED_CHAR, and sEntries.

Referenced by LLViewerTextEditor::handleMouseDown(), and LLViewerTextEditor::openEmbeddedItemAtPos().

S32 LLEmbeddedItems::getIndexFromEmbeddedChar ( llwchar  wch  ) 

Definition at line 336 of file llviewertexteditor.cpp.

References llendl, llwarns, mEmbeddedIndexedChars, and S32.

Referenced by LLViewerTextEditor::getEmbeddedText().

BOOL LLEmbeddedItems::hasEmbeddedItem ( llwchar  ext_char  ) 

Definition at line 357 of file llviewertexteditor.cpp.

References FALSE, mEmbeddedUsedChars, and TRUE.

Referenced by LLViewerTextEditor::pasteEmbeddedItem().

BOOL LLEmbeddedItems::insertEmbeddedItem ( LLInventoryItem item,
llwchar value,
bool  is_new 
)

Definition at line 218 of file llviewertexteditor.cpp.

References FALSE, FIRST_EMBEDDED_CHAR, LAST_EMBEDDED_CHAR, mEmbeddedUsedChars, sEntries, sFreeEntries, and TRUE.

Referenced by addItems(), LLTextCmdInsertEmbeddedItem::execute(), and LLViewerTextEditor::pasteEmbeddedItem().

void LLEmbeddedItems::markSaved (  ) 

Definition at line 481 of file llviewertexteditor.cpp.

References mEmbeddedUsedChars, sEntries, and TRUE.

Referenced by LLViewerTextEditor::makePristine().

BOOL LLEmbeddedItems::removeEmbeddedItem ( llwchar  ext_char  ) 

Definition at line 251 of file llviewertexteditor.cpp.

References FALSE, mEmbeddedUsedChars, sEntries, sFreeEntries, and TRUE.

Referenced by clear(), and removeUnusedChars().

void LLEmbeddedItems::removeUnusedChars (  ) 

Definition at line 302 of file llviewertexteditor.cpp.

References FIRST_EMBEDDED_CHAR, LLTextEditor::getWText(), i, LAST_EMBEDDED_CHAR, mEditor, mEmbeddedUsedChars, removeEmbeddedItem(), and S32.

Referenced by copyUsedCharsToIndexed(), empty(), and LLTextCmdInsertEmbeddedItem::execute().

void LLEmbeddedItems::unbindEmbeddedChars ( const LLFontGL font  ) 

Definition at line 437 of file llviewertexteditor.cpp.

References mEmbeddedUsedChars, and sEntries.

Referenced by LLViewerTextEditor::unbindEmbeddedChars().


Member Data Documentation

const LLViewerTextEditor* LLEmbeddedItems::mEditor [private]

Definition at line 181 of file llviewertexteditor.cpp.

Referenced by removeUnusedChars().

std::vector<llwchar> LLEmbeddedItems::mEmbeddedIndexedChars [private]

Definition at line 180 of file llviewertexteditor.cpp.

Referenced by addItems(), clear(), copyUsedCharsToIndexed(), getEmbeddedCharFromIndex(), and getIndexFromEmbeddedChar().

std::set<llwchar> LLEmbeddedItems::mEmbeddedUsedChars [private]

Definition at line 179 of file llviewertexteditor.cpp.

Referenced by bindEmbeddedChars(), clear(), copyUsedCharsToIndexed(), empty(), getEmbeddedItemList(), hasEmbeddedItem(), insertEmbeddedItem(), markSaved(), removeEmbeddedItem(), removeUnusedChars(), and unbindEmbeddedChars().

LLEmbeddedItems::item_map_t LLEmbeddedItems::sEntries [static, private]

Definition at line 176 of file llviewertexteditor.cpp.

Referenced by bindEmbeddedChars(), getEmbeddedItem(), getEmbeddedItemSaved(), insertEmbeddedItem(), markSaved(), removeEmbeddedItem(), and unbindEmbeddedChars().

std::stack< llwchar > LLEmbeddedItems::sFreeEntries [static, private]

Definition at line 177 of file llviewertexteditor.cpp.

Referenced by insertEmbeddedItem(), and removeEmbeddedItem().


The documentation for this class was generated from the following file:
Generated on Thu Jul 1 06:11:15 2010 for Second Life Viewer by  doxygen 1.4.7