| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 ruleSet->addRulesFromSheet(styleSheet.get(), blink::MediaQueryEvaluator(
"screen")); | 161 ruleSet->addRulesFromSheet(styleSheet.get(), blink::MediaQueryEvaluator(
"screen")); |
| 162 | 162 |
| 163 Document* document = toLocalFrame(webViewHelper->webViewImpl()->page()->
mainFrame())->document(); | 163 Document* document = toLocalFrame(webViewHelper->webViewImpl()->page()->
mainFrame())->document(); |
| 164 document->ensureStyleResolver().viewportStyleResolver()->collectViewport
Rules(ruleSet.get(), blink::ViewportStyleResolver::UserAgentOrigin); | 164 document->ensureStyleResolver().viewportStyleResolver()->collectViewport
Rules(ruleSet.get(), blink::ViewportStyleResolver::UserAgentOrigin); |
| 165 document->ensureStyleResolver().viewportStyleResolver()->resolve(); | 165 document->ensureStyleResolver().viewportStyleResolver()->resolve(); |
| 166 } | 166 } |
| 167 | 167 |
| 168 static void configueCompositingWebView(WebSettings* settings) | 168 static void configueCompositingWebView(WebSettings* settings) |
| 169 { | 169 { |
| 170 settings->setAcceleratedCompositingEnabled(true); | 170 settings->setAcceleratedCompositingEnabled(true); |
| 171 settings->setAcceleratedCompositingForFixedPositionEnabled(true); | 171 settings->setPreferCompositingToLCDTextEnabled(true); |
| 172 settings->setAcceleratedCompositingForOverflowScrollEnabled(true); | 172 settings->setAcceleratedCompositingForOverflowScrollEnabled(true); |
| 173 settings->setCompositedScrollingForFramesEnabled(true); | 173 settings->setCompositedScrollingForFramesEnabled(true); |
| 174 } | 174 } |
| 175 | 175 |
| 176 void initializeTextSelectionWebView(const std::string& url, FrameTestHelpers
::WebViewHelper* webViewHelper) | 176 void initializeTextSelectionWebView(const std::string& url, FrameTestHelpers
::WebViewHelper* webViewHelper) |
| 177 { | 177 { |
| 178 webViewHelper->initializeAndLoad(url, true); | 178 webViewHelper->initializeAndLoad(url, true); |
| 179 webViewHelper->webView()->settings()->setDefaultFontSize(12); | 179 webViewHelper->webView()->settings()->setDefaultFontSize(12); |
| 180 webViewHelper->webView()->resize(WebSize(640, 480)); | 180 webViewHelper->webView()->resize(WebSize(640, 480)); |
| 181 } | 181 } |
| (...skipping 5895 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6077 | 6077 |
| 6078 client.reset(); | 6078 client.reset(); |
| 6079 // Try to load the request with cross origin access. Should succeed. | 6079 // Try to load the request with cross origin access. Should succeed. |
| 6080 options.crossOriginRequestPolicy = blink::AllowCrossOriginRequests; | 6080 options.crossOriginRequestPolicy = blink::AllowCrossOriginRequests; |
| 6081 blink::DocumentThreadableLoader::loadResourceSynchronously( | 6081 blink::DocumentThreadableLoader::loadResourceSynchronously( |
| 6082 *frame->document(), blink::ResourceRequest(resourceUrl), client, options
, resourceLoaderOptions); | 6082 *frame->document(), blink::ResourceRequest(resourceUrl), client, options
, resourceLoaderOptions); |
| 6083 EXPECT_FALSE(client.failed()); | 6083 EXPECT_FALSE(client.failed()); |
| 6084 } | 6084 } |
| 6085 | 6085 |
| 6086 } // namespace | 6086 } // namespace |
| OLD | NEW |