Skip to content

Commit

Permalink
Merge pull request #9932 from rouault/fix_build_without_qtwebkit
Browse files Browse the repository at this point in the history
Fix build without WITH_QTWEBKIT
  • Loading branch information
rouault committed May 6, 2019
2 parents 24259f9 + 6efe30c commit 1148ecb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/app/qgsidentifyresultsdialog.cpp
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@
#include <QPixmap> #include <QPixmap>
#include <QMenu> #include <QMenu>
#include <QClipboard> #include <QClipboard>
#include <QDesktopWidget>
#include <QMenuBar> #include <QMenuBar>
#include <QPushButton> #include <QPushButton>
#include <QPrinter> #include <QPrinter>
Expand Down Expand Up @@ -930,6 +931,7 @@ void QgsIdentifyResultsDialog::addFeature( QgsRasterLayer *layer,
if ( currentFormat == QgsRaster::IdentifyFormatHtml || currentFormat == QgsRaster::IdentifyFormatText ) if ( currentFormat == QgsRaster::IdentifyFormatHtml || currentFormat == QgsRaster::IdentifyFormatText )
{ {
QgsIdentifyResultsWebViewItem *attrItem = new QgsIdentifyResultsWebViewItem( lstResults ); QgsIdentifyResultsWebViewItem *attrItem = new QgsIdentifyResultsWebViewItem( lstResults );
#ifdef WITH_QTWEBKIT
attrItem->webView()->page()->setLinkDelegationPolicy( QWebPage::DelegateExternalLinks ); attrItem->webView()->page()->setLinkDelegationPolicy( QWebPage::DelegateExternalLinks );
const int horizontalDpi = qApp->desktop()->screen()->logicalDpiX(); const int horizontalDpi = qApp->desktop()->screen()->logicalDpiX();
// Adjust zoom: text is ok, but HTML seems rather big at least on Linux/KDE // Adjust zoom: text is ok, but HTML seems rather big at least on Linux/KDE
Expand All @@ -941,6 +943,7 @@ void QgsIdentifyResultsDialog::addFeature( QgsRasterLayer *layer,
{ {
QDesktopServices::openUrl( url ); QDesktopServices::openUrl( url );
} ); } );
#endif
featItem->addChild( attrItem ); // before setHtml()! featItem->addChild( attrItem ); // before setHtml()!
if ( !attributes.isEmpty() ) if ( !attributes.isEmpty() )
{ {
Expand Down

0 comments on commit 1148ecb

Please sign in to comment.