Skip to content

Commit

Permalink
gui2/tstacked_widget: Add getter for the total number of layers
Browse files Browse the repository at this point in the history
  • Loading branch information
irydacea committed Jul 11, 2015
1 parent 4854413 commit 86df4a9
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/gui/widgets/stacked_widget.cpp
Expand Up @@ -148,4 +148,9 @@ void tstacked_widget::select_layer(const int layer)
}
}

unsigned int tstacked_widget::get_layer_count() const
{
return generator_->get_item_count();
}

} // namespace gui2
5 changes: 5 additions & 0 deletions src/gui/widgets/stacked_widget.hpp
Expand Up @@ -63,6 +63,11 @@ class tstacked_widget : public tcontainer_
*/
void select_layer(const int layer);

/**
* Gets the total number of layers.
*/
unsigned int get_layer_count() const;

private:
/**
* Finishes the building initialization of the widget.
Expand Down

0 comments on commit 86df4a9

Please sign in to comment.