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

Side by Side Diff: content/public/test/browser_test_utils.h

Issue 2482453002: Don't restart the hang renderer timeout on messages ack'd from the compositor thread. (Closed)
Patch Set: Fix mac build Created 4 years, 1 month 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 | « content/common/input_messages.h ('k') | content/public/test/browser_test_utils.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ 5 #ifndef CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_
6 #define CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ 6 #define CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_
7 7
8 #include <queue> 8 #include <queue>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 534 matching lines...) Expand 10 before | Expand all | Expand 10 after
545 // Watches for an input msg to be consumed. 545 // Watches for an input msg to be consumed.
546 class InputMsgWatcher : public BrowserMessageFilter { 546 class InputMsgWatcher : public BrowserMessageFilter {
547 public: 547 public:
548 InputMsgWatcher(RenderWidgetHost* render_widget_host, 548 InputMsgWatcher(RenderWidgetHost* render_widget_host,
549 blink::WebInputEvent::Type type); 549 blink::WebInputEvent::Type type);
550 550
551 // Wait until ack message occurs, returning the ack result from 551 // Wait until ack message occurs, returning the ack result from
552 // the message. 552 // the message.
553 uint32_t WaitForAck(); 553 uint32_t WaitForAck();
554 554
555 uint32_t last_event_ack_source() const { return ack_source_; }
556
555 private: 557 private:
556 ~InputMsgWatcher() override; 558 ~InputMsgWatcher() override;
557 559
558 // Overridden BrowserMessageFilter methods. 560 // Overridden BrowserMessageFilter methods.
559 bool OnMessageReceived(const IPC::Message& message) override; 561 bool OnMessageReceived(const IPC::Message& message) override;
560 562
561 void ReceivedAck(blink::WebInputEvent::Type ack_type, uint32_t ack_state); 563 void ReceivedAck(blink::WebInputEvent::Type ack_type,
564 uint32_t ack_state,
565 uint32_t ack_source);
562 566
563 blink::WebInputEvent::Type wait_for_type_; 567 blink::WebInputEvent::Type wait_for_type_;
564 uint32_t ack_result_; 568 uint32_t ack_result_;
569 uint32_t ack_source_;
565 base::Closure quit_; 570 base::Closure quit_;
566 571
567 DISALLOW_COPY_AND_ASSIGN(InputMsgWatcher); 572 DISALLOW_COPY_AND_ASSIGN(InputMsgWatcher);
568 }; 573 };
569 574
570 // Sets up a ui::TestClipboard for use in browser tests. On Windows, 575 // Sets up a ui::TestClipboard for use in browser tests. On Windows,
571 // clipboard is handled on the IO thread, BrowserTestClipboardScope 576 // clipboard is handled on the IO thread, BrowserTestClipboardScope
572 // hops messages onto the right thread. 577 // hops messages onto the right thread.
573 class BrowserTestClipboardScope { 578 class BrowserTestClipboardScope {
574 public: 579 public:
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
705 710
706 // The MessageLoopRunner used to spin the message loop. 711 // The MessageLoopRunner used to spin the message loop.
707 scoped_refptr<MessageLoopRunner> message_loop_runner_; 712 scoped_refptr<MessageLoopRunner> message_loop_runner_;
708 713
709 DISALLOW_COPY_AND_ASSIGN(ConsoleObserverDelegate); 714 DISALLOW_COPY_AND_ASSIGN(ConsoleObserverDelegate);
710 }; 715 };
711 716
712 } // namespace content 717 } // namespace content
713 718
714 #endif // CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ 719 #endif // CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_
OLDNEW
« no previous file with comments | « content/common/input_messages.h ('k') | content/public/test/browser_test_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698