Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Public Member Functions | List of all members
ui::AXPlatformNodeDelegateBase::ChildIteratorBase Class Reference

#include <ax_platform_node_delegate_base.h>

Inheritance diagram for ui::AXPlatformNodeDelegateBase::ChildIteratorBase:
ui::AXPlatformNodeDelegate::ChildIterator

Public Member Functions

 ChildIteratorBase (AXPlatformNodeDelegateBase *parent, int index)
 
 ChildIteratorBase (const ChildIteratorBase &it)
 
 ~ChildIteratorBase () override=default
 
bool operator== (const ChildIterator &rhs) const override
 
bool operator!= (const ChildIterator &rhs) const override
 
void operator++ () override
 
void operator++ (int) override
 
void operator-- () override
 
void operator-- (int) override
 
gfx::NativeViewAccessible GetNativeViewAccessible () const override
 
int GetIndexInParent () const override
 
AXPlatformNodeDelegateoperator* () const override
 
AXPlatformNodeDelegateoperator-> () const override
 
- Public Member Functions inherited from ui::AXPlatformNodeDelegate::ChildIterator
virtual ~ChildIterator ()=default
 

Detailed Description

Definition at line 85 of file ax_platform_node_delegate_base.h.

Constructor & Destructor Documentation

◆ ChildIteratorBase() [1/2]

ui::AXPlatformNodeDelegateBase::ChildIteratorBase::ChildIteratorBase ( AXPlatformNodeDelegateBase parent,
int  index 
)

Definition at line 188 of file ax_platform_node_delegate_base.cc.

191 : index_(index), parent_(parent) {
192 BASE_DCHECK(parent);
193 BASE_DCHECK(0 <= index && index <= parent->GetChildCount());
194}
#define BASE_DCHECK(condition)
Definition logging.h:63

◆ ChildIteratorBase() [2/2]

ui::AXPlatformNodeDelegateBase::ChildIteratorBase::ChildIteratorBase ( const ChildIteratorBase it)

Definition at line 196 of file ax_platform_node_delegate_base.cc.

198 : index_(it.index_), parent_(it.parent_) {
199 BASE_DCHECK(parent_);
200}

◆ ~ChildIteratorBase()

ui::AXPlatformNodeDelegateBase::ChildIteratorBase::~ChildIteratorBase ( )
overridedefault

Member Function Documentation

◆ GetIndexInParent()

int ui::AXPlatformNodeDelegateBase::ChildIteratorBase::GetIndexInParent ( ) const
overridevirtual

Implements ui::AXPlatformNodeDelegate::ChildIterator.

Definition at line 238 of file ax_platform_node_delegate_base.cc.

238 {
239 return index_;
240}

◆ GetNativeViewAccessible()

gfx::NativeViewAccessible ui::AXPlatformNodeDelegateBase::ChildIteratorBase::GetNativeViewAccessible ( ) const
overridevirtual

Implements ui::AXPlatformNodeDelegate::ChildIterator.

Definition at line 231 of file ax_platform_node_delegate_base.cc.

231 {
232 if (index_ < parent_->GetChildCount())
233 return parent_->ChildAtIndex(index_);
234
235 return nullptr;
236}
gfx::NativeViewAccessible ChildAtIndex(int index) override

◆ operator!=()

bool ui::AXPlatformNodeDelegateBase::ChildIteratorBase::operator!= ( const ChildIterator rhs) const
overridevirtual

Implements ui::AXPlatformNodeDelegate::ChildIterator.

Definition at line 207 of file ax_platform_node_delegate_base.cc.

208 {
209 return rhs.GetIndexInParent() != index_;
210}

◆ operator*()

AXPlatformNodeDelegate & ui::AXPlatformNodeDelegateBase::ChildIteratorBase::operator* ( ) const
overridevirtual

Implements ui::AXPlatformNodeDelegate::ChildIterator.

Definition at line 243 of file ax_platform_node_delegate_base.cc.

243 {
244 AXPlatformNode* platform_node =
246 BASE_DCHECK(platform_node && platform_node->GetDelegate());
247 return *(platform_node->GetDelegate());
248}
gfx::NativeViewAccessible GetNativeViewAccessible() const override
static AXPlatformNode * FromNativeViewAccessible(gfx::NativeViewAccessible accessible)

◆ operator++() [1/2]

void ui::AXPlatformNodeDelegateBase::ChildIteratorBase::operator++ ( )
overridevirtual

Implements ui::AXPlatformNodeDelegate::ChildIterator.

Definition at line 212 of file ax_platform_node_delegate_base.cc.

212 {
213 index_++;
214}

◆ operator++() [2/2]

void ui::AXPlatformNodeDelegateBase::ChildIteratorBase::operator++ ( int  )
overridevirtual

Implements ui::AXPlatformNodeDelegate::ChildIterator.

Definition at line 216 of file ax_platform_node_delegate_base.cc.

216 {
217 index_++;
218}

◆ operator--() [1/2]

void ui::AXPlatformNodeDelegateBase::ChildIteratorBase::operator-- ( )
overridevirtual

Implements ui::AXPlatformNodeDelegate::ChildIterator.

Definition at line 220 of file ax_platform_node_delegate_base.cc.

220 {
221 BASE_DCHECK(index_ > 0);
222 index_--;
223}

◆ operator--() [2/2]

void ui::AXPlatformNodeDelegateBase::ChildIteratorBase::operator-- ( int  )
overridevirtual

Implements ui::AXPlatformNodeDelegate::ChildIterator.

Definition at line 225 of file ax_platform_node_delegate_base.cc.

225 {
226 BASE_DCHECK(index_ > 0);
227 index_--;
228}

◆ operator->()

AXPlatformNodeDelegate * ui::AXPlatformNodeDelegateBase::ChildIteratorBase::operator-> ( ) const
overridevirtual

Implements ui::AXPlatformNodeDelegate::ChildIterator.

Definition at line 251 of file ax_platform_node_delegate_base.cc.

251 {
252 AXPlatformNode* platform_node =
254 return platform_node ? platform_node->GetDelegate() : nullptr;
255}

◆ operator==()

bool ui::AXPlatformNodeDelegateBase::ChildIteratorBase::operator== ( const ChildIterator rhs) const
overridevirtual

Implements ui::AXPlatformNodeDelegate::ChildIterator.

Definition at line 202 of file ax_platform_node_delegate_base.cc.

203 {
204 return rhs.GetIndexInParent() == index_;
205}

The documentation for this class was generated from the following files: