diff options
| author | Yang Ni <yangni@google.com> | 2015-02-14 18:00:59 -0800 |
|---|---|---|
| committer | Yang Ni <yangni@google.com> | 2015-02-15 20:10:40 +0000 |
| commit | b8353c5943f4038fd7f08db3d958390ce9418798 (patch) | |
| tree | 2cfac49d1f790e077f40dfc7ba42904ee5658f50 /rsContext.cpp | |
| parent | 1ce0dfd82311d4922dbffdde302599410fc25c5d (diff) | |
| download | android_frameworks_rs-b8353c5943f4038fd7f08db3d958390ce9418798.tar.gz android_frameworks_rs-b8353c5943f4038fd7f08db3d958390ce9418798.tar.bz2 android_frameworks_rs-b8353c5943f4038fd7f08db3d958390ce9418798.zip | |
Revert "Replaced android::Vector with std::vector."
b/19148482
This reverts commit 93d6bc872b7d9fba63abfa7513d56b38d9c3d371.
I also made some changes to Make it work with HEAD.
Change-Id: I5e516976ec1d85ffe1cf388c01795348a9441982
Diffstat (limited to 'rsContext.cpp')
| -rw-r--r-- | rsContext.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/rsContext.cpp b/rsContext.cpp index 72431187..5818b661 100644 --- a/rsContext.cpp +++ b/rsContext.cpp @@ -762,15 +762,13 @@ void Context::finish() { void Context::assignName(ObjectBase *obj, const char *name, uint32_t len) { rsAssert(!obj->getName()); obj->setName(name, len); - mNames.push_back(obj); + mNames.add(obj); } void Context::removeName(ObjectBase *obj) { - for (auto nameIter = mNames.begin(), endIter = mNames.end(); - nameIter != endIter; nameIter++) { - - if (obj == *nameIter) { - mNames.erase(nameIter); + for (size_t ct=0; ct < mNames.size(); ct++) { + if (obj == mNames[ct]) { + mNames.removeAt(ct); return; } } @@ -1012,3 +1010,4 @@ void rsaGetName(RsContext con, void * obj, const char **name) { ObjectBase *ob = static_cast<ObjectBase *>(obj); (*name) = ob->getName(); } + |
