зеркало из https://github.com/mozilla/gecko-dev.git
bug 1261144 - use filters::GetEmbeddedObject() directly in EmbeddedObjCollector r=lsocks
This commit is contained in:
Родитель
9d406fe177
Коммит
a6e634768b
|
@ -31,7 +31,7 @@ EmbeddedObjCollector::EnsureNGetObject(uint32_t aIndex)
|
|||
uint32_t childCount = mRoot->ChildCount();
|
||||
while (mRootChildIdx < childCount) {
|
||||
Accessible* child = mRoot->GetChildAt(mRootChildIdx++);
|
||||
if (!(mFilterFunc(child) & filters::eMatch))
|
||||
if (!(filters::GetEmbeddedObject(child) & filters::eMatch))
|
||||
continue;
|
||||
|
||||
AppendObject(child);
|
||||
|
@ -48,7 +48,7 @@ EmbeddedObjCollector::EnsureNGetIndex(Accessible* aAccessible)
|
|||
uint32_t childCount = mRoot->ChildCount();
|
||||
while (mRootChildIdx < childCount) {
|
||||
Accessible* child = mRoot->GetChildAt(mRootChildIdx++);
|
||||
if (!(mFilterFunc(child) & filters::eMatch))
|
||||
if (!(filters::GetEmbeddedObject(child) & filters::eMatch))
|
||||
continue;
|
||||
|
||||
AppendObject(child);
|
||||
|
@ -69,7 +69,7 @@ EmbeddedObjCollector::GetIndexAt(Accessible* aAccessible)
|
|||
if (aAccessible->mInt.mIndexOfEmbeddedChild != -1)
|
||||
return aAccessible->mInt.mIndexOfEmbeddedChild;
|
||||
|
||||
return mFilterFunc(aAccessible) & filters::eMatch ?
|
||||
return filters::GetEmbeddedObject(aAccessible) & filters::eMatch ?
|
||||
EnsureNGetIndex(aAccessible) : -1;
|
||||
}
|
||||
|
||||
|
|
|
@ -52,7 +52,7 @@ protected:
|
|||
|
||||
// Make sure it's used by Accessible class only.
|
||||
explicit EmbeddedObjCollector(Accessible* aRoot) :
|
||||
mFilterFunc(filters::GetEmbeddedObject), mRoot(aRoot), mRootChildIdx(0) {}
|
||||
mRoot(aRoot), mRootChildIdx(0) {}
|
||||
|
||||
/**
|
||||
* Append the object to collection.
|
||||
|
@ -61,7 +61,6 @@ protected:
|
|||
|
||||
friend class Accessible;
|
||||
|
||||
filters::FilterFuncPtr mFilterFunc;
|
||||
Accessible* mRoot;
|
||||
uint32_t mRootChildIdx;
|
||||
nsTArray<Accessible*> mObjects;
|
||||
|
|
Загрузка…
Ссылка в новой задаче