Skip to content

Invoke insteed direct call#629

Open
NickNevzorov wants to merge 1 commit into
gyunaev:masterfrom
NickNevzorov:patch-1
Open

Invoke insteed direct call#629
NickNevzorov wants to merge 1 commit into
gyunaev:masterfrom
NickNevzorov:patch-1

Conversation

@NickNevzorov

Copy link
Copy Markdown

For multithreading, you need to use invoke.

In the latest version of QT (6.9), the application crashes when adding log events (access violation on module QT6Widgets.dll).

@Abestanis

Copy link
Copy Markdown
Collaborator

Indeed, we need to make sure QPlainTextEdit::appendPlainText is called on the GUI thread. Another option would have been to convert the add method into a signal, but I think it's fine like this.

@Abestanis

Copy link
Copy Markdown
Collaborator

The concept is fine, but I think we need to mark the function with Q_INVOKABLE.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants