Skip to content

Commit

Permalink
fix build without webkit
Browse files Browse the repository at this point in the history
  • Loading branch information
3nids authored Aug 8, 2018
1 parent 4f59bca commit 0c97b7c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/gui/qgsmaptip.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -155,12 +155,16 @@ void QgsMapTip::showMapTip( QgsMapLayer *pLayer,

void QgsMapTip::resizeContent()
{
#if WITH_QTWEBKIT
// Get the content size
QWebElement container = mWebView->page()->mainFrame()->findFirstElement(
QStringLiteral( "#QgsWebViewContainer" ) );
int width = container.geometry().width() + MARGIN_VALUE * 2;
int height = container.geometry().height() + MARGIN_VALUE * 2;
mWidget->resize( width, height );
#else
mWebView->adjustSize();
#endif
}

void QgsMapTip::clear( QgsMapCanvas * )
Expand Down

0 comments on commit 0c97b7c

Please sign in to comment.