Skip to content

Commit

Permalink
This exactly matches copy behavior in v3.5.3.
Browse files Browse the repository at this point in the history
Signed-off-by: Adam Treat <[email protected]>
  • Loading branch information
manyoso committed Dec 20, 2024
1 parent 45c53ee commit 066255b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions gpt4all-chat/src/chatmodel.h
Original file line number Diff line number Diff line change
Expand Up @@ -987,10 +987,12 @@ class ChatModel : public QAbstractListModel
QMutexLocker locker(&m_mutex);
QStringList content;
for (ChatItem *item : m_chatItems) {
content << item->clipboardContent();
QString string = item->name;
string += item->clipboardContent();
content << string;
}
QClipboard *clipboard = QGuiApplication::clipboard();
clipboard->setText(content.join("\n\n"), QClipboard::Clipboard);
clipboard->setText(content.join("\n"), QClipboard::Clipboard);
}

Q_INVOKABLE void copyToClipboard(int index)
Expand Down

0 comments on commit 066255b

Please sign in to comment.