Flutter Engine
 
Loading...
Searching...
No Matches
flutter::MutatorsStack Class Reference

#include <embedded_views.h>

Public Member Functions

 MutatorsStack ()=default
 
void PushClipRect (const DlRect &rect)
 
void PushClipRRect (const DlRoundRect &rrect)
 
void PushClipRSE (const DlRoundSuperellipse &rrect)
 
void PushClipPath (const DlPath &path)
 
void PushTransform (const DlMatrix &matrix)
 
void PushOpacity (const uint8_t &alpha)
 
void PushBackdropFilter (const std::shared_ptr< DlImageFilter > &filter, const DlRect &filter_rect)
 
void Pop ()
 
void PopTo (size_t stack_count)
 
const std::vector< std::shared_ptr< Mutator > >::const_reverse_iterator Top () const
 
const std::vector< std::shared_ptr< Mutator > >::const_reverse_iterator Bottom () const
 
const std::vector< std::shared_ptr< Mutator > >::const_iterator Begin () const
 
const std::vector< std::shared_ptr< Mutator > >::const_iterator End () const
 
bool is_empty () const
 
size_t stack_count () const
 
bool operator== (const MutatorsStack &other) const
 
bool operator== (const std::vector< Mutator > &other) const
 
bool operator!= (const MutatorsStack &other) const
 
bool operator!= (const std::vector< Mutator > &other) const
 

Detailed Description

Definition at line 140 of file embedded_views.h.

Constructor & Destructor Documentation

◆ MutatorsStack()

flutter::MutatorsStack::MutatorsStack ( )
default

Member Function Documentation

◆ Begin()

const std::vector< std::shared_ptr< Mutator > >::const_iterator flutter::MutatorsStack::Begin ( ) const

◆ Bottom()

const std::vector< std::shared_ptr< Mutator > >::const_reverse_iterator flutter::MutatorsStack::Bottom ( ) const

◆ End()

const std::vector< std::shared_ptr< Mutator > >::const_iterator flutter::MutatorsStack::End ( ) const

◆ is_empty()

bool flutter::MutatorsStack::is_empty ( ) const
inline

Definition at line 177 of file embedded_views.h.

177{ return vector_.empty(); }

Referenced by flutter::testing::TEST(), and flutter::testing::TEST_F().

◆ operator!=() [1/2]

bool flutter::MutatorsStack::operator!= ( const MutatorsStack other) const
inline

Definition at line 204 of file embedded_views.h.

204 {
205 return !operator==(other);
206 }
bool operator==(const MutatorsStack &other) const

References operator==().

◆ operator!=() [2/2]

bool flutter::MutatorsStack::operator!= ( const std::vector< Mutator > &  other) const
inline

Definition at line 208 of file embedded_views.h.

208 {
209 return !operator==(other);
210 }

References operator==().

◆ operator==() [1/2]

bool flutter::MutatorsStack::operator== ( const MutatorsStack other) const
inline

Definition at line 180 of file embedded_views.h.

180 {
181 if (vector_.size() != other.vector_.size()) {
182 return false;
183 }
184 for (size_t i = 0; i < vector_.size(); i++) {
185 if (*vector_[i] != *other.vector_[i]) {
186 return false;
187 }
188 }
189 return true;
190 }

References i.

Referenced by operator!=(), and operator!=().

◆ operator==() [2/2]

bool flutter::MutatorsStack::operator== ( const std::vector< Mutator > &  other) const
inline

Definition at line 192 of file embedded_views.h.

192 {
193 if (vector_.size() != other.size()) {
194 return false;
195 }
196 for (size_t i = 0; i < vector_.size(); i++) {
197 if (*vector_[i] != other[i]) {
198 return false;
199 }
200 }
201 return true;
202 }

References i.

◆ Pop()

void flutter::MutatorsStack::Pop ( )

Definition at line 99 of file embedded_views.cc.

99 {
100 vector_.pop_back();
101}

Referenced by PopTo(), flutter::testing::TEST(), and flutter::testing::TEST().

◆ PopTo()

void flutter::MutatorsStack::PopTo ( size_t  stack_count)

Definition at line 103 of file embedded_views.cc.

103 {
104 while (vector_.size() > stack_count) {
105 Pop();
106 }
107}
size_t stack_count() const

References Pop(), and stack_count().

◆ PushBackdropFilter()

void flutter::MutatorsStack::PushBackdropFilter ( const std::shared_ptr< DlImageFilter > &  filter,
const DlRect filter_rect 
)

Definition at line 91 of file embedded_views.cc.

93 {
94 std::shared_ptr<Mutator> element =
95 std::make_shared<Mutator>(filter, filter_rect);
96 vector_.push_back(element);
97}

Referenced by flutter::EmbeddedViewParams::PushImageFilter(), flutter::testing::TEST(), and flutter::testing::TEST().

◆ PushClipPath()

void flutter::MutatorsStack::PushClipPath ( const DlPath path)

Definition at line 76 of file embedded_views.cc.

76 {
77 std::shared_ptr<Mutator> element = std::make_shared<Mutator>(path);
78 vector_.push_back(element);
79}
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir path
Definition switch_defs.h:52

References flutter::path.

Referenced by flutter::testing::TEST(), flutter::testing::TEST(), and flutter::ClipPathEntry::update_mutators().

◆ PushClipRect()

void flutter::MutatorsStack::PushClipRect ( const DlRect rect)

Definition at line 61 of file embedded_views.cc.

61 {
62 std::shared_ptr<Mutator> element = std::make_shared<Mutator>(rect);
63 vector_.push_back(element);
64}

Referenced by flutter::testing::TEST(), flutter::testing::TEST(), flutter::testing::TEST(), flutter::testing::TEST(), flutter::testing::TEST(), and flutter::ClipRectEntry::update_mutators().

◆ PushClipRRect()

void flutter::MutatorsStack::PushClipRRect ( const DlRoundRect rrect)

Definition at line 66 of file embedded_views.cc.

66 {
67 std::shared_ptr<Mutator> element = std::make_shared<Mutator>(rrect);
68 vector_.push_back(element);
69}

Referenced by flutter::testing::TEST(), flutter::testing::TEST(), flutter::testing::TEST(), flutter::testing::TEST(), flutter::testing::TEST(), and flutter::ClipRRectEntry::update_mutators().

◆ PushClipRSE()

void flutter::MutatorsStack::PushClipRSE ( const DlRoundSuperellipse rrect)

Definition at line 71 of file embedded_views.cc.

71 {
72 std::shared_ptr<Mutator> element = std::make_shared<Mutator>(rrect);
73 vector_.push_back(element);
74}

Referenced by flutter::testing::TEST(), and flutter::ClipRSuperellipseEntry::update_mutators().

◆ PushOpacity()

void flutter::MutatorsStack::PushOpacity ( const uint8_t &  alpha)

Definition at line 86 of file embedded_views.cc.

86 {
87 std::shared_ptr<Mutator> element = std::make_shared<Mutator>(alpha);
88 vector_.push_back(element);
89}

Referenced by flutter::testing::TEST(), flutter::testing::TEST(), and flutter::OpacityEntry::update_mutators().

◆ PushTransform()

◆ stack_count()

size_t flutter::MutatorsStack::stack_count ( ) const
inline

Definition at line 178 of file embedded_views.h.

178{ return vector_.size(); }

Referenced by PopTo().

◆ Top()

const std::vector< std::shared_ptr< Mutator > >::const_reverse_iterator flutter::MutatorsStack::Top ( ) const

Definition at line 110 of file embedded_views.cc.

110 {
111 return vector_.rend();
112}

Referenced by flutter::testing::TEST(), and flutter::testing::TEST().


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