OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
193 // Consequently, all external image resources must be mocked. | 193 // Consequently, all external image resources must be mocked. |
194 m_webView->settings()->setLoadsImagesAutomatically(true); | 194 m_webView->settings()->setLoadsImagesAutomatically(true); |
195 if (updateSettingsFunc) | 195 if (updateSettingsFunc) |
196 updateSettingsFunc(m_webView->settings()); | 196 updateSettingsFunc(m_webView->settings()); |
197 else | 197 else |
198 m_webView->settings()->setDeviceSupportsMouse(false); | 198 m_webView->settings()->setDeviceSupportsMouse(false); |
199 if (m_settingOverrider) | 199 if (m_settingOverrider) |
200 m_settingOverrider->overrideSettings(m_webView->settings()); | 200 m_settingOverrider->overrideSettings(m_webView->settings()); |
201 m_webView->setDeviceScaleFactor(webViewClient->screenInfo().deviceScaleFacto
r); | 201 m_webView->setDeviceScaleFactor(webViewClient->screenInfo().deviceScaleFacto
r); |
202 m_webView->setDefaultPageScaleLimits(1, 4); | 202 m_webView->setDefaultPageScaleLimits(1, 4); |
203 WebLocalFrame* frame = WebLocalFrameImpl::create(WebTreeScopeType::Document,
webFrameClient, opener); | 203 WebLocalFrame* frame = WebLocalFrameImpl::create(WebTreeScopeType::Document,
webFrameClient, opener, nullptr); |
204 m_webView->setMainFrame(frame); | 204 m_webView->setMainFrame(frame); |
205 // TODO(dcheng): The main frame widget currently has a special case. | 205 // TODO(dcheng): The main frame widget currently has a special case. |
206 // Eliminate this once WebView is no longer a WebWidget. | 206 // Eliminate this once WebView is no longer a WebWidget. |
207 m_webViewWidget = blink::WebFrameWidget::create(webViewClient, m_webView, fr
ame); | 207 m_webViewWidget = blink::WebFrameWidget::create(webViewClient, m_webView, fr
ame); |
208 | 208 |
209 m_testWebViewClient = webViewClient; | 209 m_testWebViewClient = webViewClient; |
210 | 210 |
211 return m_webView; | 211 return m_webView; |
212 } | 212 } |
213 | 213 |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
289 } | 289 } |
290 | 290 |
291 void TestWebViewClient::initializeLayerTreeView() | 291 void TestWebViewClient::initializeLayerTreeView() |
292 { | 292 { |
293 m_layerTreeView = adoptPtr(Platform::current()->unitTestSupport()->createLay
erTreeViewForTesting()); | 293 m_layerTreeView = adoptPtr(Platform::current()->unitTestSupport()->createLay
erTreeViewForTesting()); |
294 ASSERT(m_layerTreeView); | 294 ASSERT(m_layerTreeView); |
295 } | 295 } |
296 | 296 |
297 } // namespace FrameTestHelpers | 297 } // namespace FrameTestHelpers |
298 } // namespace blink | 298 } // namespace blink |
OLD | NEW |