mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-12-02 23:14:07 +00:00
fix:F12 crash on qt6.2
This commit is contained in:
parent
fa2aae908b
commit
eebe109e7e
|
@ -14,7 +14,10 @@ void ArticleInspector::setInspectPage( QWebEnginePage * page )
|
||||||
{
|
{
|
||||||
this->inspectedPage = page;
|
this->inspectedPage = page;
|
||||||
page->setDevToolsPage( inspectView->page() );
|
page->setDevToolsPage( inspectView->page() );
|
||||||
|
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||||
|
//this line will crash application on qt6.2 ,see https://bugreports.qt.io/browse/QTBUG-101724
|
||||||
page->triggerAction( QWebEnginePage::InspectElement );
|
page->triggerAction( QWebEnginePage::InspectElement );
|
||||||
|
#endif
|
||||||
raise();
|
raise();
|
||||||
show();
|
show();
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,8 +16,6 @@
|
||||||
/// to the view's current state. This is used to open links in new tabs when
|
/// to the view's current state. This is used to open links in new tabs when
|
||||||
/// they are clicked with middle button. There's also an added possibility to
|
/// they are clicked with middle button. There's also an added possibility to
|
||||||
/// get double-click events after the fact with the doubleClicked() signal.
|
/// get double-click events after the fact with the doubleClicked() signal.
|
||||||
/// 2. Manage our own QWebInspector instance. In order to show inspector correctly,
|
|
||||||
/// use triggerPageAction( QWebEnginePage::InspectElement ) instead.
|
|
||||||
class ArticleWebView: public QWebEngineView
|
class ArticleWebView: public QWebEngineView
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
Loading…
Reference in a new issue