From 70c51bc27de063df953afe9c3a04993b09140a70 Mon Sep 17 00:00:00 2001 From: Grace Kloba Date: Tue, 23 Mar 2010 16:14:34 -0700 Subject: [PATCH] Add a special case to handle "wap" style html. If we get here, it is html mimetype, not wap mimetype. Treat the "wap" style like "mobile" style by using device-width as viewport width. Fix http://b/issue?id=2538320 --- WebCore/html/HTMLBodyElement.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/WebCore/html/HTMLBodyElement.cpp b/WebCore/html/HTMLBodyElement.cpp index b9e2c7577..e5a16cbdf 100644 --- a/WebCore/html/HTMLBodyElement.cpp +++ b/WebCore/html/HTMLBodyElement.cpp @@ -191,7 +191,7 @@ void HTMLBodyElement::insertedIntoDocument() if (settings) { String host = document()->baseURI().host().lower(); if (settings->viewportWidth() == -1 && (host.startsWith("m.") || host.startsWith("mobile.") - || host.contains(".m.") || host.contains(".mobile."))) { + || host.startsWith("wap.") || host.contains(".m.") || host.contains(".mobile." || host.contains(".wap.")))) { // fit mobile sites directly in the screen settings->setMetadataSettings("width", "device-width"); // update the meta data if it is the top document -- 2.11.0