mirror of https://github.com/axmolengine/axmol.git
Adds empty constructor for TableView and TableViewCell.
This commit is contained in:
parent
01745f5ba6
commit
4bb091067f
|
@ -29,6 +29,10 @@
|
|||
|
||||
NS_CC_EXT_BEGIN
|
||||
|
||||
TableView* TableView::create()
|
||||
{
|
||||
return TableView::create(nullptr, Size::ZERO);
|
||||
}
|
||||
|
||||
TableView* TableView::create(TableViewDataSource* dataSource, Size size)
|
||||
{
|
||||
|
@ -51,6 +55,7 @@ bool TableView::initWithViewSize(Size size, Node* container/* = NULL*/)
|
|||
{
|
||||
if (ScrollView::initWithViewSize(size,container))
|
||||
{
|
||||
CC_SAFE_DELETE(_indices);
|
||||
_indices = new std::set<ssize_t>();
|
||||
_vordering = VerticalFillOrder::BOTTOM_UP;
|
||||
this->setDirection(Direction::VERTICAL);
|
||||
|
|
|
@ -148,6 +148,10 @@ public:
|
|||
TOP_DOWN,
|
||||
BOTTOM_UP
|
||||
};
|
||||
|
||||
/** Empty contructor of TableView */
|
||||
static TableView* create();
|
||||
|
||||
/**
|
||||
* An intialized table view object
|
||||
*
|
||||
|
|
|
@ -37,6 +37,8 @@ NS_CC_EXT_BEGIN
|
|||
class TableViewCell: public Node
|
||||
{
|
||||
public:
|
||||
CREATE_FUNC(TableViewCell);
|
||||
|
||||
TableViewCell() {}
|
||||
/**
|
||||
* The index used internally by SWTableView and its subclasses
|
||||
|
|
Loading…
Reference in New Issue