aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/util/qqmladaptormodel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/qml/util/qqmladaptormodel.cpp')
-rw-r--r--src/qml/util/qqmladaptormodel.cpp30
1 files changed, 30 insertions, 0 deletions
diff --git a/src/qml/util/qqmladaptormodel.cpp b/src/qml/util/qqmladaptormodel.cpp
index 7afafec1fe..96a18a1c3d 100644
--- a/src/qml/util/qqmladaptormodel.cpp
+++ b/src/qml/util/qqmladaptormodel.cpp
@@ -458,6 +458,16 @@ public:
return model.aim()->rowCount(model.rootIndex);
}
+ int rowCount(const QQmlAdaptorModel &model) const override
+ {
+ return model.aim()->rowCount(model.rootIndex);
+ }
+
+ int columnCount(const QQmlAdaptorModel &model) const override
+ {
+ return model.aim()->columnCount(model.rootIndex);
+ }
+
void cleanup(QQmlAdaptorModel &model, QQmlDelegateModel *vdm) const override
{
QAbstractItemModel * const aim = model.aim();
@@ -658,6 +668,16 @@ public:
return model.list.count();
}
+ int rowCount(const QQmlAdaptorModel &model) const override
+ {
+ return model.list.count();
+ }
+
+ int columnCount(const QQmlAdaptorModel &) const override
+ {
+ return 1;
+ }
+
QVariant value(const QQmlAdaptorModel &model, int index, const QString &role) const override
{
return role == QLatin1String("modelData")
@@ -742,6 +762,16 @@ public:
return model.list.count();
}
+ int rowCount(const QQmlAdaptorModel &model) const override
+ {
+ return model.list.count();
+ }
+
+ int columnCount(const QQmlAdaptorModel &) const override
+ {
+ return 1;
+ }
+
QVariant value(const QQmlAdaptorModel &model, int index, const QString &role) const override
{
if (QObject *object = model.list.at(index).value<QObject *>())