mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-08 16:24:53 +08:00
[cpp] Added Skin::removeAttachment.
This commit is contained in:
parent
08c7c566f3
commit
a578557934
@ -124,6 +124,9 @@ public:
|
||||
/// Returns the attachment for the specified slot index and name, or NULL.
|
||||
Attachment *getAttachment(size_t slotIndex, const String &name);
|
||||
|
||||
// Removes the attachment from the skin.
|
||||
void removeAttachment(size_t slotIndex, const String& name);
|
||||
|
||||
/// Finds the skin keys for a given slot. The results are added to the passed array of names.
|
||||
/// @param slotIndex The target slotIndex. To find the slot index, use Skeleton::findSlotIndex or SkeletonData::findSlotIndex
|
||||
/// @param names Found skin key names will be added to this array.
|
||||
|
||||
@ -112,6 +112,10 @@ Attachment *Skin::getAttachment(size_t slotIndex, const String &name) {
|
||||
return _attachments.get(slotIndex, name);
|
||||
}
|
||||
|
||||
void Skin::removeAttachment(size_t slotIndex, const String& name) {
|
||||
_attachments.remove(slotIndex, name);
|
||||
}
|
||||
|
||||
void Skin::findNamesForSlot(size_t slotIndex, Vector<String> &names) {
|
||||
Skin::AttachmentMap::Entries entries = _attachments.getEntries();
|
||||
while (entries.hasNext()) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user