[DeckList] refactor: pass DeckList by const ref (#6437)

* [DeckList] refactor: pass DeckList by const ref

* Change getDeckList to return a const ref
This commit is contained in:
RickyRister 2025-12-21 16:19:33 -08:00 committed by GitHub
parent 73a90bdf38
commit a0f977e80c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 70 additions and 75 deletions

View file

@ -150,7 +150,7 @@ DlgEditDeckInClipboard::DlgEditDeckInClipboard(const DeckList &_deckList, bool _
* @param addComments Whether to add annotations
* @return A QString
*/
static QString deckListToString(const DeckList *deckList, bool addComments)
static QString deckListToString(const DeckList &deckList, bool addComments)
{
QString buffer;
QTextStream stream(&buffer);
@ -160,7 +160,7 @@ static QString deckListToString(const DeckList *deckList, bool addComments)
void DlgEditDeckInClipboard::actRefresh()
{
setText(deckListToString(&deckList, annotated));
setText(deckListToString(deckList, annotated));
}
void DlgEditDeckInClipboard::actOK()