25 #ifndef __TERRALIB_QT_WIDGETS_LAYER_INTERNAL_LAYERITEMMODEL_H 
   26 #define __TERRALIB_QT_WIDGETS_LAYER_INTERNAL_LAYERITEMMODEL_H 
   28 #include "../../Config.h" 
   31 #include "../../../../maptools/AbstractLayer.h" 
   34 #include <QAbstractItemModel> 
   41 #ifndef Q_DECL_OVERRIDE 
   42   #define Q_DECL_OVERRIDE 
  126         void addLayers(
const std::list<te::map::AbstractLayerPtr>& layers, 
const std::string& idxPath = 
"./");
 
  137         void addLayers(
const std::list<te::map::AbstractLayerPtr>& layers, 
const QModelIndex& parent, 
const std::string& idxPath = 
"./");
 
  146         void setLayers(
const std::list<te::map::AbstractLayerPtr>& layers);
 
  166         void addItems(
const std::vector<TreeItem*> items, 
TreeItem* parent, 
const int& pos = 0);
 
  175         void addFolder(
const std::string& name, 
TreeItem* parent = 0);
 
  184         void addFolder(
const std::string& name, 
const QModelIndex& idx);
 
  199         std::list<te::map::AbstractLayerPtr> getAllLayers();
 
  208         std::list<te::map::AbstractLayerPtr> getVisibleLayers();
 
  217         QVariant data(
const QModelIndex &index, 
int role) 
const Q_DECL_OVERRIDE;
 
  221         QVariant headerData(
int section, Qt::Orientation orientation,
 
  224         QModelIndex index(
int row, 
int column,
 
  229         int rowCount(
const QModelIndex &parent = QModelIndex()) 
const Q_DECL_OVERRIDE;
 
  231         int columnCount(
const QModelIndex &parent = QModelIndex()) 
const Q_DECL_OVERRIDE;
 
  233         bool setData(
const QModelIndex & index, 
const QVariant & value, 
int role = Qt::EditRole) 
Q_DECL_OVERRIDE;
 
  235         bool removeRows(
int row, 
int count, 
const QModelIndex & parent = QModelIndex()) 
Q_DECL_OVERRIDE;
 
  237         bool insertRows(
int row, 
int count, 
const QModelIndex& parent = QModelIndex()) 
Q_DECL_OVERRIDE;
 
  243         QMimeData* mimeData(
const QModelIndexList &indexes) 
const Q_DECL_OVERRIDE;
 
  245         bool canDropMimeData(
const QMimeData *data, Qt::DropAction action, 
int row, 
int column, 
const QModelIndex &parent);
 
  247         bool dropMimeData(
const QMimeData *data, Qt::DropAction action, 
int row, 
int column, 
const QModelIndex &parent) 
Q_DECL_OVERRIDE;
 
  255         void removeItems(
const QModelIndexList& lst);
 
  269         void visibilityChanged();
 
  280 #endif // __TERRALIB_QT_WIDGETS_LAYER_INTERNAL_LAYERITEMMODEL_H 
boost::intrusive_ptr< AbstractLayer > AbstractLayerPtr