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 <cctype> | 7 #include <cctype> |
8 | 8 |
9 #include "base/callback_helpers.h" | 9 #include "base/callback_helpers.h" |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 751 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
762 if (animate_scheduled_) { | 762 if (animate_scheduled_) { |
763 base::TimeDelta animate_time = base::TimeTicks::Now() - base::TimeTicks(); | 763 base::TimeDelta animate_time = base::TimeTicks::Now() - base::TimeTicks(); |
764 base::TimeDelta interval = base::TimeDelta::FromMicroseconds(16666); | 764 base::TimeDelta interval = base::TimeDelta::FromMicroseconds(16666); |
765 blink::WebBeginFrameArgs args(animate_time.InSecondsF(), | 765 blink::WebBeginFrameArgs args(animate_time.InSecondsF(), |
766 (animate_time + interval).InSecondsF(), | 766 (animate_time + interval).InSecondsF(), |
767 interval.InSecondsF()); | 767 interval.InSecondsF()); |
768 | 768 |
769 animate_scheduled_ = false; | 769 animate_scheduled_ = false; |
770 web_widget_->beginFrame(args); | 770 web_widget_->beginFrame(args); |
771 web_widget_->layout(); | 771 web_widget_->layout(); |
| 772 web_widget_->didCommitCompositorFrame(); |
772 if (blink::WebPagePopup* popup = web_widget_->pagePopup()) { | 773 if (blink::WebPagePopup* popup = web_widget_->pagePopup()) { |
773 popup->beginFrame(args); | 774 popup->beginFrame(args); |
774 popup->layout(); | 775 popup->layout(); |
| 776 popup->didCommitCompositorFrame(); |
775 } | 777 } |
776 } | 778 } |
777 } | 779 } |
778 | 780 |
779 void WebTestProxyBase::PostAccessibilityEvent(const blink::WebAXObject& obj, | 781 void WebTestProxyBase::PostAccessibilityEvent(const blink::WebAXObject& obj, |
780 blink::WebAXEvent event) { | 782 blink::WebAXEvent event) { |
781 // Only hook the accessibility events occured during the test run. | 783 // Only hook the accessibility events occured during the test run. |
782 // This check prevents false positives in WebLeakDetector. | 784 // This check prevents false positives in WebLeakDetector. |
783 // The pending tasks in browser/renderer message queue may trigger | 785 // The pending tasks in browser/renderer message queue may trigger |
784 // accessibility events, | 786 // accessibility events, |
(...skipping 631 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1416 // to cancel the input method's ongoing composition session. | 1418 // to cancel the input method's ongoing composition session. |
1417 if (web_widget_) | 1419 if (web_widget_) |
1418 web_widget_->confirmComposition(); | 1420 web_widget_->confirmComposition(); |
1419 } | 1421 } |
1420 | 1422 |
1421 blink::WebString WebTestProxyBase::acceptLanguages() { | 1423 blink::WebString WebTestProxyBase::acceptLanguages() { |
1422 return blink::WebString::fromUTF8(accept_languages_); | 1424 return blink::WebString::fromUTF8(accept_languages_); |
1423 } | 1425 } |
1424 | 1426 |
1425 } // namespace test_runner | 1427 } // namespace test_runner |
OLD | NEW |