Skip to content
Permalink
Browse files
fix windows build
  • Loading branch information
jef-n committed May 22, 2015
1 parent f2d4d30 commit 5910adf55e7b2dd1b1d17b52d89eb936e6065c13
Showing with 60 additions and 57 deletions.
  1. +3 −3 src/core/qgswebframe.h
  2. +48 −45 src/core/qgswebpage.h
  3. +9 −9 src/core/qgswebview.h
@@ -24,13 +24,13 @@
#include <QPainter>
#include <QUrl>

class QWebFrame : public QObject
class CORE_EXPORT QWebFrame : public QObject
{
Q_OBJECT
Q_OBJECT

public:
QWebFrame( QObject* parent = 0 )
:QObject( parent )
: QObject( parent )
{

}
@@ -28,47 +28,48 @@
#include <QNetworkAccessManager>
#include <QPalette>

class QWebSettings : public QObject
class CORE_EXPORT QWebSettings : public QObject
{
Q_OBJECT

public:

enum WebAttribute {
AutoLoadImages,
JavascriptEnabled,
JavaEnabled,
PluginsEnabled,
PrivateBrowsingEnabled,
JavascriptCanOpenWindows,
JavascriptCanAccessClipboard,
DeveloperExtrasEnabled,
LinksIncludedInFocusChain,
ZoomTextOnly,
PrintElementBackgrounds,
OfflineStorageDatabaseEnabled,
OfflineWebApplicationCacheEnabled,
LocalStorageEnabled,
LocalContentCanAccessRemoteUrls,
DnsPrefetchEnabled,
XSSAuditingEnabled,
AcceleratedCompositingEnabled,
SpatialNavigationEnabled,
LocalContentCanAccessFileUrls,
TiledBackingStoreEnabled,
FrameFlatteningEnabled,
SiteSpecificQuirksEnabled,
JavascriptCanCloseWindows,
WebGLEnabled,
CSSRegionsEnabled,
HyperlinkAuditingEnabled,
CSSGridLayoutEnabled,
ScrollAnimatorEnabled,
CaretBrowsingEnabled,
NotificationsEnabled
enum WebAttribute
{
AutoLoadImages,
JavascriptEnabled,
JavaEnabled,
PluginsEnabled,
PrivateBrowsingEnabled,
JavascriptCanOpenWindows,
JavascriptCanAccessClipboard,
DeveloperExtrasEnabled,
LinksIncludedInFocusChain,
ZoomTextOnly,
PrintElementBackgrounds,
OfflineStorageDatabaseEnabled,
OfflineWebApplicationCacheEnabled,
LocalStorageEnabled,
LocalContentCanAccessRemoteUrls,
DnsPrefetchEnabled,
XSSAuditingEnabled,
AcceleratedCompositingEnabled,
SpatialNavigationEnabled,
LocalContentCanAccessFileUrls,
TiledBackingStoreEnabled,
FrameFlatteningEnabled,
SiteSpecificQuirksEnabled,
JavascriptCanCloseWindows,
WebGLEnabled,
CSSRegionsEnabled,
HyperlinkAuditingEnabled,
CSSGridLayoutEnabled,
ScrollAnimatorEnabled,
CaretBrowsingEnabled,
NotificationsEnabled
};
explicit QWebSettings( QObject* parent = 0 )
:QObject( parent )
: QObject( parent )
{

}
@@ -90,21 +91,23 @@ class QWebPage : public QObject

public:

enum LinkDelegationPolicy {
DontDelegateLinks,
DelegateExternalLinks,
DelegateAllLinks
enum LinkDelegationPolicy
{
DontDelegateLinks,
DelegateExternalLinks,
DelegateAllLinks
};

enum WebWindowType {
WebBrowserWindow,
WebModalDialog
enum WebWindowType
{
WebBrowserWindow,
WebModalDialog
};

explicit QWebPage( QObject* parent = 0 )
: QObject( parent )
, mSettings( new QWebSettings() )
, mFrame( new QWebFrame() )
: QObject( parent )
, mSettings( new QWebSettings() )
, mFrame( new QWebFrame() )
{
}

@@ -124,7 +127,7 @@ class QWebPage : public QObject
Q_UNUSED( palette );
}

void setViewportSize(const QSize & size) const
void setViewportSize( const QSize & size ) const
{
Q_UNUSED( size );
}
@@ -22,26 +22,26 @@
#ifdef WITH_QTWEBKIT
#include <QtWebKit/QWebView>

class QgsWebView : public QWebView
class CORE_EXPORT QgsWebView : public QWebView
{
Q_OBJECT

public:
explicit QgsWebView(QWidget* parent = 0)
: QWebView( parent )
explicit QgsWebView( QWidget* parent = 0 )
: QWebView( parent )
{}
};
#else
#include "qgswebpage.h"

class QgsWebView : public QWidget
class CORE_EXPORT QgsWebView : public QWidget
{
Q_OBJECT
public:
explicit QgsWebView(QWidget *parent = 0)
: QWidget(parent )
, mSettings( new QWebSettings() )
, mPage( new QWebPage() )
explicit QgsWebView( QWidget *parent = 0 )
: QWidget( parent )
, mSettings( new QWebSettings() )
, mPage( new QWebPage() )
{
}

@@ -77,7 +77,7 @@ class QgsWebView : public QWidget
Q_UNUSED( html );
}

virtual QgsWebView* createWindow(QWebPage::WebWindowType)
virtual QgsWebView* createWindow( QWebPage::WebWindowType )
{
return new QgsWebView();
}

0 comments on commit 5910adf

Please sign in to comment.