Index: Source/core/page/Settings.cpp |
diff --git a/Source/core/page/Settings.cpp b/Source/core/page/Settings.cpp |
index 68a69d3e5665b447ff0007471d7eb22468b3373f..c9c952a64061f2ffea955471ab6ceb617f16aff8 100644 |
--- a/Source/core/page/Settings.cpp |
+++ b/Source/core/page/Settings.cpp |
@@ -137,6 +137,7 @@ Settings::Settings(Page* page) |
, m_cssStickyPositionEnabled(true) |
, m_dnsPrefetchingEnabled(false) |
, m_touchEventEmulationEnabled(false) |
+ , m_viewportEnabled(false) |
, m_setImageLoadingSettingsTimer(this, &Settings::imageLoadingSettingsTimerFired) |
{ |
m_page = page; // Page is not yet fully initialized wen constructing Settings, so keeping m_page null over initializeDefaultFontFamilies() call. |
@@ -380,4 +381,14 @@ bool Settings::openGLMultisamplingEnabled() |
return m_openGLMultisamplingEnabled; |
} |
+void Settings::setViewportEnabled(bool enabled) |
+{ |
+ if (m_viewportEnabled == enabled) |
+ return; |
+ |
+ m_viewportEnabled = enabled; |
+ if (m_page->mainFrame()) |
+ m_page->mainFrame()->document()->updateViewportArguments(); |
+} |
+ |
} // namespace WebCore |