diff options
| author | Xavier Del Campo Romero <xavi92@disroot.org> | 2026-02-03 23:06:44 +0100 |
|---|---|---|
| committer | Xavier Del Campo Romero <xavi92@disroot.org> | 2026-02-03 23:06:44 +0100 |
| commit | b934e6b0fdcc56f2cca1cca9ebce289cebaaafa2 (patch) | |
| tree | 686950abbdc508561a635d5551a38d811c75d337 /conversationmodel.cpp | |
| parent | 997e9b168d362a50cdcdc82c6cc3488a6852737a (diff) | |
| download | yachat6-b934e6b0fdcc56f2cca1cca9ebce289cebaaafa2.tar.gz | |
Replace ConversationModel with ListModel
Diffstat (limited to 'conversationmodel.cpp')
| -rw-r--r-- | conversationmodel.cpp | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/conversationmodel.cpp b/conversationmodel.cpp deleted file mode 100644 index 8257fb1..0000000 --- a/conversationmodel.cpp +++ /dev/null @@ -1,34 +0,0 @@ -#include "conversationmodel.h" -#include <QAbstractItemModel> - -int ConversationModel::rowCount(const QModelIndex &parent) const -{ - qDebug() << conversations.count(); - return conversations.count(); -} - -QVariant ConversationModel::data(const QModelIndex &index, int role) const -{ - qDebug() << conversations; - return conversations.at(index.row()); -} - -void ConversationModel::append(const QString &value) -{ - beginInsertRows(QModelIndex(), rowCount(), rowCount()); - endInsertRows(); - conversations << value; - qDebug() << conversations; - qDebug() << conversations.count(); -} - -bool ConversationModel::setData(const QModelIndex &index, const QVariant &value, - int role) -{ - return false; -} - -QStringList ConversationModel::getConversations() const -{ - return conversations; -} |
