mirror of
https://github.com/nomic-ai/gpt4all.git
synced 2025-07-20 10:10:38 +00:00
do not connect layoutChanged to countChanged
layoutChanged is only used when the *order* changes. When rows are inserted or removed, one of the other three signals is fired. Signed-off-by: Jared Van Bortel <jared@nomic.ai>
This commit is contained in:
parent
d3840fb817
commit
45120d4d96
@ -20,7 +20,6 @@ LocalDocsCollectionsModel::LocalDocsCollectionsModel(QObject *parent)
|
|||||||
connect(this, &LocalDocsCollectionsModel::rowsInserted, this, &LocalDocsCollectionsModel::countChanged);
|
connect(this, &LocalDocsCollectionsModel::rowsInserted, this, &LocalDocsCollectionsModel::countChanged);
|
||||||
connect(this, &LocalDocsCollectionsModel::rowsRemoved, this, &LocalDocsCollectionsModel::countChanged);
|
connect(this, &LocalDocsCollectionsModel::rowsRemoved, this, &LocalDocsCollectionsModel::countChanged);
|
||||||
connect(this, &LocalDocsCollectionsModel::modelReset, this, &LocalDocsCollectionsModel::countChanged);
|
connect(this, &LocalDocsCollectionsModel::modelReset, this, &LocalDocsCollectionsModel::countChanged);
|
||||||
connect(this, &LocalDocsCollectionsModel::layoutChanged, this, &LocalDocsCollectionsModel::countChanged);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool LocalDocsCollectionsModel::filterAcceptsRow(int sourceRow,
|
bool LocalDocsCollectionsModel::filterAcceptsRow(int sourceRow,
|
||||||
@ -67,7 +66,6 @@ LocalDocsModel::LocalDocsModel(QObject *parent)
|
|||||||
connect(this, &LocalDocsModel::rowsInserted, this, &LocalDocsModel::countChanged);
|
connect(this, &LocalDocsModel::rowsInserted, this, &LocalDocsModel::countChanged);
|
||||||
connect(this, &LocalDocsModel::rowsRemoved, this, &LocalDocsModel::countChanged);
|
connect(this, &LocalDocsModel::rowsRemoved, this, &LocalDocsModel::countChanged);
|
||||||
connect(this, &LocalDocsModel::modelReset, this, &LocalDocsModel::countChanged);
|
connect(this, &LocalDocsModel::modelReset, this, &LocalDocsModel::countChanged);
|
||||||
connect(this, &LocalDocsModel::layoutChanged, this, &LocalDocsModel::countChanged);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
int LocalDocsModel::rowCount(const QModelIndex &parent) const
|
int LocalDocsModel::rowCount(const QModelIndex &parent) const
|
||||||
|
@ -398,7 +398,6 @@ InstalledModels::InstalledModels(QObject *parent, bool selectable)
|
|||||||
connect(this, &InstalledModels::rowsInserted, this, &InstalledModels::countChanged);
|
connect(this, &InstalledModels::rowsInserted, this, &InstalledModels::countChanged);
|
||||||
connect(this, &InstalledModels::rowsRemoved, this, &InstalledModels::countChanged);
|
connect(this, &InstalledModels::rowsRemoved, this, &InstalledModels::countChanged);
|
||||||
connect(this, &InstalledModels::modelReset, this, &InstalledModels::countChanged);
|
connect(this, &InstalledModels::modelReset, this, &InstalledModels::countChanged);
|
||||||
connect(this, &InstalledModels::layoutChanged, this, &InstalledModels::countChanged);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool InstalledModels::filterAcceptsRow(int sourceRow,
|
bool InstalledModels::filterAcceptsRow(int sourceRow,
|
||||||
@ -423,7 +422,6 @@ DownloadableModels::DownloadableModels(QObject *parent)
|
|||||||
connect(this, &DownloadableModels::rowsInserted, this, &DownloadableModels::countChanged);
|
connect(this, &DownloadableModels::rowsInserted, this, &DownloadableModels::countChanged);
|
||||||
connect(this, &DownloadableModels::rowsRemoved, this, &DownloadableModels::countChanged);
|
connect(this, &DownloadableModels::rowsRemoved, this, &DownloadableModels::countChanged);
|
||||||
connect(this, &DownloadableModels::modelReset, this, &DownloadableModels::countChanged);
|
connect(this, &DownloadableModels::modelReset, this, &DownloadableModels::countChanged);
|
||||||
connect(this, &DownloadableModels::layoutChanged, this, &DownloadableModels::countChanged);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool DownloadableModels::filterAcceptsRow(int sourceRow,
|
bool DownloadableModels::filterAcceptsRow(int sourceRow,
|
||||||
|
Loading…
Reference in New Issue
Block a user