summaryrefslogtreecommitdiffstats
path: root/WebCore/html/HTMLMetaElement.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/html/HTMLMetaElement.cpp')
-rw-r--r--WebCore/html/HTMLMetaElement.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/WebCore/html/HTMLMetaElement.cpp b/WebCore/html/HTMLMetaElement.cpp
index 48284e3..5d3e925 100644
--- a/WebCore/html/HTMLMetaElement.cpp
+++ b/WebCore/html/HTMLMetaElement.cpp
@@ -27,6 +27,10 @@
#include "HTMLNames.h"
#include "MappedAttribute.h"
+#ifdef ANDROID_META_SUPPORT
+#include "Settings.h"
+#endif
+
namespace WebCore {
using namespace HTMLNames;
@@ -68,6 +72,10 @@ void HTMLMetaElement::process()
return;
if (equalIgnoringCase(name(), "viewport") || equalIgnoringCase(name(), "format-detection"))
document()->processMetadataSettings(m_content);
+ else if (equalIgnoringCase(name(), "HandheldFriendly") && equalIgnoringCase(m_content, "true")
+ && document()->settings()->viewportWidth() == -1)
+ // fit mobile sites directly in the screen
+ document()->settings()->setMetadataSettings("width", "device-width");
#endif
// Get the document to process the tag, but only if we're actually part of DOM tree (changing a meta tag while
// it's not in the tree shouldn't have any effect on the document)