Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(149)

Side by Side Diff: content/shell/renderer/test_runner/web_test_proxy.cc

Issue 768173003: DO NOT LAND: Magic delay for inducing layout test failures Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "content/shell/renderer/test_runner/web_test_proxy.h" 5 #include "content/shell/renderer/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 642 matching lines...) Expand 10 before | Expand all | Expand 10 after
653 return credential_manager_client_.get(); 653 return credential_manager_client_.get();
654 } 654 }
655 655
656 void WebTestProxyBase::ScheduleAnimation() { 656 void WebTestProxyBase::ScheduleAnimation() {
657 if (!test_interfaces_->GetTestRunner()->TestIsRunning()) 657 if (!test_interfaces_->GetTestRunner()->TestIsRunning())
658 return; 658 return;
659 659
660 if (!animate_scheduled_) { 660 if (!animate_scheduled_) {
661 animate_scheduled_ = true; 661 animate_scheduled_ = true;
662 delegate_->PostDelayedTask( 662 delegate_->PostDelayedTask(
663 new HostMethodTask(this, &WebTestProxyBase::AnimateNow), 1); 663 new HostMethodTask(this, &WebTestProxyBase::AnimateNow), 200);
664 } 664 }
665 } 665 }
666 666
667 void WebTestProxyBase::AnimateNow() { 667 void WebTestProxyBase::AnimateNow() {
668 if (animate_scheduled_) { 668 if (animate_scheduled_) {
669 animate_scheduled_ = false; 669 animate_scheduled_ = false;
670 web_widget_->animate(0.0); 670 web_widget_->animate(0.0);
671 web_widget_->layout(); 671 web_widget_->layout();
672 if (blink::WebPagePopup* popup = web_widget_->pagePopup()) { 672 if (blink::WebPagePopup* popup = web_widget_->pagePopup()) {
673 popup->animate(0.0); 673 popup->animate(0.0);
(...skipping 660 matching lines...) Expand 10 before | Expand all | Expand 10 after
1334 if (!push_client_.get()) 1334 if (!push_client_.get())
1335 push_client_.reset(new MockWebPushClient); 1335 push_client_.reset(new MockWebPushClient);
1336 return push_client_.get(); 1336 return push_client_.get();
1337 } 1337 }
1338 1338
1339 blink::WebPushClient* WebTestProxyBase::GetWebPushClient() { 1339 blink::WebPushClient* WebTestProxyBase::GetWebPushClient() {
1340 return GetPushClientMock(); 1340 return GetPushClientMock();
1341 } 1341 }
1342 1342
1343 } // namespace content 1343 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698