From be8331afa8b397e7f0162031a62e5964dacd03a2 Mon Sep 17 00:00:00 2001 From: YiFang Xiao Date: Fri, 12 May 2023 08:04:21 +0800 Subject: [PATCH] opt: inspector debug message changes --- src/ui/article_inspect.cc | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/src/ui/article_inspect.cc b/src/ui/article_inspect.cc index 513cea9c..b1d08863 100644 --- a/src/ui/article_inspect.cc +++ b/src/ui/article_inspect.cc @@ -21,27 +21,23 @@ void ArticleInspector::setInspectPage( QWebEnginePage * page ) { viewContainer->page()->setInspectedPage( page ); - if( !page ) - { - qDebug() << "set inspected page to nullptr"; + if ( !page ) { + qDebug() << "reset inspector"; return; } raise(); show(); - qDebug() << "inspector finished"; } void ArticleInspector::triggerAction( QWebEnginePage * page ) { - if( !page ) - { - qDebug() << "set inspected page to nullptr"; + setInspectPage( page ); + + if ( !page ) { return; } - setInspectPage(page); - #if( QT_VERSION < QT_VERSION_CHECK( 6, 0, 0 ) || QT_VERSION > QT_VERSION_CHECK(6,3,0) ) page->triggerAction( QWebEnginePage::InspectElement ); #endif