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
diff --git a/WebCore/html/HTMLBodyElement.cpp b/WebCore/html/HTMLBodyElement.cpp
index b9e2c75..e5a16cb 100644
--- a/WebCore/html/HTMLBodyElement.cpp
+++ b/WebCore/html/HTMLBodyElement.cpp
@@ -191,7 +191,7 @@
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