QWebKit causes Qt application to freeze and become non-responsive
Unsolved
Qt WebKit
-
I'm trying to load a url using QWebView on Linux Ubuntu 18.04 and RHEL 8.
m_webView->page()->mainFrame()->load(m_url); m_webView->resize(1024, 750); m_webView->show();
What I'm seeing is that while loading the url the entire application freezes. The UI process is using up 100% of the CPU as we see in the
top
function.I was thinking to add a timer and stop from loading since I do not yet see that loading has finished in the slot:
connect(m_webView, SIGNAL(loadFinished(bool)), this, SLOT(onLoadFinished(bool)));
Basically QWebView is causing the entire application to become non-responsive. This occurs intermittently.
Is there any way to stop QWebView from loading the url so that the application can recover?
Should I have QWebView in its own thread so it doesn't affect the rest of the application?