OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "components/test_runner/web_test_proxy.h" | 5 #include "components/test_runner/web_test_proxy.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <cctype> | 10 #include <cctype> |
(...skipping 574 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
585 new LayoutAndPaintCallback(callback); | 585 new LayoutAndPaintCallback(callback); |
586 web_widget_->layoutAndPaintAsync(layout_and_paint_callback); | 586 web_widget_->layoutAndPaintAsync(layout_and_paint_callback); |
587 if (blink::WebPagePopup* popup = web_widget_->pagePopup()) { | 587 if (blink::WebPagePopup* popup = web_widget_->pagePopup()) { |
588 layout_and_paint_callback->set_wait_for_popup(true); | 588 layout_and_paint_callback->set_wait_for_popup(true); |
589 popup->layoutAndPaintAsync(layout_and_paint_callback); | 589 popup->layoutAndPaintAsync(layout_and_paint_callback); |
590 } | 590 } |
591 } | 591 } |
592 | 592 |
593 void WebTestProxyBase::GetScreenOrientationForTesting( | 593 void WebTestProxyBase::GetScreenOrientationForTesting( |
594 blink::WebScreenInfo& screen_info) { | 594 blink::WebScreenInfo& screen_info) { |
595 if (!screen_orientation_client_ || !screen_orientation_client_->is_active()) | 595 if (!screen_orientation_client_) |
596 return; | 596 return; |
597 // Override screen orientation information with mock data. | 597 // Override screen orientation information with mock data. |
598 screen_info.orientationType = | 598 screen_info.orientationType = |
599 screen_orientation_client_->CurrentOrientationType(); | 599 screen_orientation_client_->CurrentOrientationType(); |
600 screen_info.orientationAngle = | 600 screen_info.orientationAngle = |
601 screen_orientation_client_->CurrentOrientationAngle(); | 601 screen_orientation_client_->CurrentOrientationAngle(); |
602 } | 602 } |
603 | 603 |
604 MockScreenOrientationClient* | 604 MockScreenOrientationClient* |
605 WebTestProxyBase::GetScreenOrientationClientMock() { | 605 WebTestProxyBase::GetScreenOrientationClientMock() { |
(...skipping 690 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1296 callback->onError(blink::WebSetSinkIdError::NotAuthorized); | 1296 callback->onError(blink::WebSetSinkIdError::NotAuthorized); |
1297 else | 1297 else |
1298 callback->onError(blink::WebSetSinkIdError::NotFound); | 1298 callback->onError(blink::WebSetSinkIdError::NotFound); |
1299 } | 1299 } |
1300 | 1300 |
1301 blink::WebString WebTestProxyBase::acceptLanguages() { | 1301 blink::WebString WebTestProxyBase::acceptLanguages() { |
1302 return blink::WebString::fromUTF8(accept_languages_); | 1302 return blink::WebString::fromUTF8(accept_languages_); |
1303 } | 1303 } |
1304 | 1304 |
1305 } // namespace test_runner | 1305 } // namespace test_runner |
OLD | NEW |