108 void setItemsCheckable(
bool checkable );
123 void setItemsCanBeReordered(
bool allow );
131 bool itemsCanBeReordered() const;
136 void checkAll( Qt::CheckState checkState );
145 void setAllowEmptyLayer(
bool allowEmpty, const QString &text = QString(), const QIcon &icon = QIcon() );
157 void setShowCrs(
bool showCrs );
168 QList<QgsMapLayer *> layersChecked( Qt::CheckState checkState = Qt::Checked );
173 void setLayersChecked(
const QList< QgsMapLayer * > &layers );
182 QModelIndex indexFromLayer(
QgsMapLayer *layer )
const;
188 QgsMapLayer *layerFromIndex(
const QModelIndex &index )
const;
196 void setAdditionalItems(
const QStringList &items );
213 void setAdditionalLayers(
const QList<QgsMapLayer *> &layers );
221 QList< QgsMapLayer * > additionalLayers()
const;
224 QModelIndex index(
int row,
int column,
const QModelIndex &parent = QModelIndex() )
const override;
225 QModelIndex parent(
const QModelIndex &child )
const override;
226 int rowCount(
const QModelIndex &parent = QModelIndex() )
const override;
227 int columnCount(
const QModelIndex &parent = QModelIndex() )
const override;
228 QVariant data(
const QModelIndex &index,
int role = Qt::DisplayRole )
const override;
229 bool setData(
const QModelIndex &index,
const QVariant &value,
int role = Qt::EditRole )
override;
230 Qt::ItemFlags flags(
const QModelIndex &index )
const override;
231 bool insertRows(
int row,
int count,
const QModelIndex &parent = QModelIndex() )
override;
232 bool removeRows(
int row,
int count,
const QModelIndex &parent = QModelIndex() )
override;
233 QStringList mimeTypes()
const override;
234 bool canDropMimeData(
const QMimeData *data, Qt::DropAction action,
int row,
int column,
const QModelIndex &parent )
const override;
235 QMimeData *mimeData(
const QModelIndexList &indexes )
const override;
236 bool dropMimeData(
const QMimeData *data, Qt::DropAction action,
int row,
int column,
const QModelIndex &parent )
override;
237 Qt::DropActions supportedDropActions()
const override;
244 QHash<int, QByteArray> roleNames() const override
SIP_SKIP;
252 void removeLayers( const QStringList &layerIds );
253 void addLayers( const QList<
QgsMapLayer *> &layers );
265 bool mAllowEmpty = false;
268 bool mShowCrs = false;
269 QStringList mAdditionalItems;