MCPcopy Create free account
hub / github.com/TankOs/SFGUI / GetPageOf

Method GetPageOf

src/SFGUI/Notebook.cpp:197–205  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

195}
196
197Notebook::IndexType Notebook::GetPageOf( Widget::Ptr widget ) const {
198 ChildrenList::const_iterator iter( std::find( m_children.begin(), m_children.end(), ChildLabelPair( widget, Widget::Ptr() ) ) );
199
200 if( iter == m_children.end() ) {
201 return -1;
202 }
203
204 return static_cast<IndexType>( iter - m_children.begin() );
205}
206
207void Notebook::NextPage() {
208 auto old_page = m_current_page;

Callers

nothing calls this directly

Calls 2

ChildLabelPairClass · 0.85
endMethod · 0.80

Tested by

no test coverage detected