diff options
author | Nikias Bassen | 2014-03-19 02:32:57 +0100 |
---|---|---|
committer | Nikias Bassen | 2014-03-19 02:32:57 +0100 |
commit | 6b719ecda2072dafeb98a44a6f4eac247748efc0 (patch) | |
tree | b223294da3c9e4124ddead7c6ece4107b72d8b47 /src/Dictionary.cpp | |
parent | f9299fa80a7530fea4b829ea851972a664edf1fe (diff) | |
download | libplist-6b719ecda2072dafeb98a44a6f4eac247748efc0.tar.gz libplist-6b719ecda2072dafeb98a44a6f4eac247748efc0.tar.bz2 |
deprecated plist_dict_insert_item in favor of plist_dict_set_item
Diffstat (limited to 'src/Dictionary.cpp')
-rw-r--r-- | src/Dictionary.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/Dictionary.cpp b/src/Dictionary.cpp index 6fd45e6..6009ea4 100644 --- a/src/Dictionary.cpp +++ b/src/Dictionary.cpp @@ -140,13 +140,13 @@ Dictionary::iterator Dictionary::Find(const std::string& key) return _map.find(key); } -Dictionary::iterator Dictionary::Insert(const std::string& key, Node* node) +Dictionary::iterator Dictionary::Set(const std::string& key, Node* node) { if (node) { Node* clone = node->Clone(); UpdateNodeParent(clone); - plist_dict_insert_item(_node, key.c_str(), clone->GetPlist()); + plist_dict_set_item(_node, key.c_str(), clone->GetPlist()); delete _map[key]; _map[key] = clone; return _map.find(key); @@ -154,6 +154,11 @@ Dictionary::iterator Dictionary::Insert(const std::string& key, Node* node) return iterator(this->_map.end()); } +Dictionary::iterator Dictionary::Insert(const std::string& key, Node* node) +{ + return this->Set(key, node); +} + void Dictionary::Remove(Node* node) { if (node) |