3D CSS webkit effects were not fully functional, as the compositor is disabled for the Chrome UI. So instead of using the VirtualURL, we use the URL.
BUG=114652
TEST=Use extension that replaces new tab page and uses webkit CSS 3D effects
-webkit-transform and -webkit-backface-hidden
Review URL: http://codereview.chromium.org/9652022
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@127177 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/content/browser/tab_contents/tab_contents.cc b/content/browser/tab_contents/tab_contents.cc
index cf3fd3dc..d52c3fd 100644
--- a/content/browser/tab_contents/tab_contents.cc
+++ b/content/browser/tab_contents/tab_contents.cc
@@ -2318,7 +2318,11 @@
}
WebPreferences TabContents::GetWebkitPrefs() {
- return GetWebkitPrefs(GetRenderViewHost(), GetURL());
+ // We want to base the page config off of the real URL, rather than the
+ // display URL.
+ GURL url = controller_.GetActiveEntry()
+ ? controller_.GetActiveEntry()->GetURL() : GURL::EmptyGURL();
+ return GetWebkitPrefs(GetRenderViewHost(), url);
}
void TabContents::OnUserGesture() {