File indexing completed on 2024-05-19 08:36:41
0001 #include "projectsmodel.h" 0002 #include <QDebug> 0003 0004 ProjectsModel::ProjectsModel(QObject *parent) : MauiList(parent) 0005 { 0006 0007 } 0008 0009 0010 void ProjectsModel::componentComplete() 0011 { 0012 } 0013 0014 const FMH::MODEL_LIST &ProjectsModel::items() const 0015 { 0016 return m_list; 0017 } 0018 0019 void ProjectsModel::setList(const FMH::MODEL_LIST &list) 0020 { 0021 this->preListChanged(); 0022 this->m_list << list; 0023 this->postListChanged(); 0024 } 0025 0026 void ProjectsModel::insert(const FMH::MODEL &item) 0027 { 0028 qDebug() << "inserting item << " << item; 0029 emit this->preItemAppended(); 0030 this->m_list << item; 0031 emit this->postItemAppended(); 0032 emit this->countChanged(); 0033 }