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

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

Issue 1749343004: Implement Wheel Gesture Scrolling on OSX. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Ensure only high precision scroll begins are used Created 4 years, 9 months 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
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>
11 11
12 #include "base/callback.h" 12 #include "base/callback.h"
13 #include "base/compiler_specific.h" 13 #include "base/compiler_specific.h"
14 #include "base/files/scoped_temp_dir.h" 14 #include "base/files/scoped_temp_dir.h"
15 #include "base/macros.h" 15 #include "base/macros.h"
16 #include "base/memory/ref_counted.h" 16 #include "base/memory/ref_counted.h"
17 #include "base/process/process.h" 17 #include "base/process/process.h"
18 #include "base/strings/string16.h" 18 #include "base/strings/string16.h"
19 #include "build/build_config.h" 19 #include "build/build_config.h"
20 #include "cc/output/compositor_frame.h" 20 #include "cc/output/compositor_frame.h"
21 #include "content/public/browser/browser_message_filter.h" 21 #include "content/public/browser/browser_message_filter.h"
22 #include "content/public/browser/notification_observer.h" 22 #include "content/public/browser/notification_observer.h"
23 #include "content/public/browser/notification_registrar.h" 23 #include "content/public/browser/notification_registrar.h"
24 #include "content/public/browser/render_process_host_observer.h" 24 #include "content/public/browser/render_process_host_observer.h"
25 #include "content/public/browser/web_contents_observer.h" 25 #include "content/public/browser/web_contents_observer.h"
26 #include "content/public/common/page_type.h" 26 #include "content/public/common/page_type.h"
27 #include "ipc/message_filter.h"
27 #include "third_party/WebKit/public/web/WebInputEvent.h" 28 #include "third_party/WebKit/public/web/WebInputEvent.h"
28 #include "ui/events/keycodes/keyboard_codes.h" 29 #include "ui/events/keycodes/keyboard_codes.h"
29 #include "url/gurl.h" 30 #include "url/gurl.h"
30 31
31 #if defined(OS_WIN) 32 #if defined(OS_WIN)
32 #include "base/win/scoped_handle.h" 33 #include "base/win/scoped_handle.h"
33 #endif 34 #endif
34 35
35 namespace gfx { 36 namespace gfx {
36 class Point; 37 class Point;
(...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after
409 410
410 DISALLOW_COPY_AND_ASSIGN(WebContentsAddedObserver); 411 DISALLOW_COPY_AND_ASSIGN(WebContentsAddedObserver);
411 }; 412 };
412 413
413 // Request a new frame be drawn, returns false if request fails. 414 // Request a new frame be drawn, returns false if request fails.
414 bool RequestFrame(WebContents* web_contents); 415 bool RequestFrame(WebContents* web_contents);
415 416
416 // Watches compositor frame changes, blocking until a frame has been 417 // Watches compositor frame changes, blocking until a frame has been
417 // composited. This class is intended to be run on the main thread; to 418 // composited. This class is intended to be run on the main thread; to
418 // synchronize the main thread against the impl thread. 419 // synchronize the main thread against the impl thread.
419 class FrameWatcher : public BrowserMessageFilter { 420 class FrameWatcher : public IPC::MessageFilter {
420 public: 421 public:
421 FrameWatcher(); 422 FrameWatcher();
422 423
423 // Listen for new frames from the |web_contents| renderer process. 424 // Listen for new frames from the |web_contents| renderer process.
424 void AttachTo(WebContents* web_contents); 425 void AttachTo(WebContents* web_contents);
425 426
426 // Wait for |frames_to_wait| swap mesages from the compositor. 427 // Wait for |frames_to_wait| swap mesages from the compositor.
427 void WaitFrames(int frames_to_wait); 428 void WaitFrames(int frames_to_wait);
428 429
429 // Return the meta data received in the last compositor 430 // Return the meta data received in the last compositor
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
490 blink::WebInputEvent::Type wait_for_type_; 491 blink::WebInputEvent::Type wait_for_type_;
491 uint32_t ack_result_; 492 uint32_t ack_result_;
492 base::Closure quit_; 493 base::Closure quit_;
493 494
494 DISALLOW_COPY_AND_ASSIGN(InputMsgWatcher); 495 DISALLOW_COPY_AND_ASSIGN(InputMsgWatcher);
495 }; 496 };
496 497
497 } // namespace content 498 } // namespace content
498 499
499 #endif // CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ 500 #endif // CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_
OLDNEW
« no previous file with comments | « content/browser/web_contents/web_contents_view_aura_browsertest.cc ('k') | content/public/test/browser_test_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698