27 #include "../../common/Translator.h"
28 #include "../../datatype/Property.h"
29 #include "../Exception.h"
35 #include <QtGui/QWidget>
38 : AbstractTreeItem(parent)
40 if(properties.empty())
43 for(
size_t i = 0; i < properties.size(); ++i)
52 m_items.push_back(item);
69 if(role == Qt::DisplayRole && column == 0)
70 return QVariant(
TR_VP(
"Properties"));
88 if(!children().empty ())
96 return Qt::ItemIsUserCheckable;
142 return m_items.size() > 0 ?
true :
false;
162 return "GROUPING_ITEM";
QMenu * getMenu(QWidget *parent=0) const
QVariant data(int column, int role) const
te::map::AbstractLayerPtr getLayer() const
PropertyGroupItem(std::vector< te::dt::Property * > properties, te::qt::widgets::AbstractTreeItem *parent)
bool setData(int column, const QVariant &value, int role=Qt::EditRole)
A class that represents a Property in a LayerTreeModel.
bool canFetchMore() const
const std::string getItemType() const
It returns the item type.
A class that represents a Layer in a LayerTreeModel.
The class that represents an item in a LayerTreeModel.
It models a property definition.
Qt::ItemFlags flags() const
int getType() const
It returns the property data type.
boost::intrusive_ptr< AbstractLayer > AbstractLayerPtr
A class that represents a group of Properties in a LayerTreeModel.
virtual Property * clone() const =0
It returns a clone of the object.
#define TR_VP(message)
It marks a string in order to get translated. This is a special mark used in the Terrralib Vector Pro...
std::vector< te::qt::widgets::AbstractTreeItem * > getItems() const