use QT_VERSION for new features; refs #160

master
Marc Wäckerlin 12 years ago
parent a3bf97fbd4
commit e5df2889af
  1. 26
      src/qbrowserlib/settings.hxx

@ -62,8 +62,12 @@ namespace qbrowserlib {
_settingJavascriptCanAccessClipboard;
_attributes[QWebSettings::DeveloperExtrasEnabled] =
_settingDeveloperExtrasEnabled;
#if QT_VERSION >= QT_VERSION_CHECK(4, 7, 0)
_attributes[QWebSettings::SpatialNavigationEnabled] =
_settingSpatialNavigationEnabled;
#else
_settingSpatialNavigationEnabled->hide();
#fi
_attributes[QWebSettings::LinksIncludedInFocusChain] =
_settingLinksIncludedInFocusChain;
_attributes[QWebSettings::ZoomTextOnly] =
@ -78,20 +82,30 @@ namespace qbrowserlib {
_settingLocalStorageEnabled;
_attributes[QWebSettings::LocalContentCanAccessRemoteUrls] =
_settingLocalContentCanAccessRemoteUrls;
#if QT_VERSION >= QT_VERSION_CHECK(4, 7, 0)
_attributes[QWebSettings::LocalContentCanAccessFileUrls] =
_settingLocalContentCanAccessFileUrls;
// not in qt 4.7.0 (mac)
// _attributes[QWebSettings::XSSAuditingEnabled] =
// _settingXSSAuditingEnabled;
_attributes[QWebSettings::AcceleratedCompositingEnabled] =
_settingAcceleratedCompositingEnabled;
_attributes[QWebSettings::TiledBackingStoreEnabled] =
_settingTiledBackingStoreEnabled;
_attributes[QWebSettings::FrameFlatteningEnabled] =
_settingFrameFlatteningEnabled;
// not in qt 4.7.0 (mac)
// _attributes[QWebSettings::SiteSpecificQuirksEnabled] =
// _settingSiteSpecificQuirksEnabled;
#else
_settingLocalContentCanAccessFileUrls->hide();
_settingAcceleratedCompositingEnabled->hide();
_settingTiledBackingStoreEnabled->hide();
_settingFrameFlatteningEnabled->hide();
#fi
#if QT_VERSION >= QT_VERSION_CHECK(4, 8, 0)
_attributes[QWebSettings::XSSAuditingEnabled] =
_settingXSSAuditingEnabled;
_attributes[QWebSettings::SiteSpecificQuirksEnabled] =
_settingSiteSpecificQuirksEnabled;
#else
_settingXSSAuditingEnabled->hide();
_settingSiteSpecificQuirksEnabled->hide();
#fi
// CheckBoxes
_checkboxes["SaveWindowState"] =

Loading…
Cancel
Save