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

Side by Side Diff: content/browser/android/in_process/synchronous_input_event_filter.cc

Issue 1008613002: favor DCHECK_CURRENTLY_ON for better logs in content/browser/[a-d]* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/browser/android/in_process/synchronous_input_event_filter.h" 5 #include "content/browser/android/in_process/synchronous_input_event_filter.h"
6 6
7 #include "base/callback.h" 7 #include "base/callback.h"
8 #include "cc/input/input_handler.h" 8 #include "cc/input/input_handler.h"
9 #include "content/browser/android/in_process/synchronous_compositor_impl.h" 9 #include "content/browser/android/in_process/synchronous_compositor_impl.h"
10 #include "content/public/browser/browser_thread.h" 10 #include "content/public/browser/browser_thread.h"
(...skipping 23 matching lines...) Expand all
34 34
35 void SynchronousInputEventFilter::SetBoundHandler(const Handler& handler) { 35 void SynchronousInputEventFilter::SetBoundHandler(const Handler& handler) {
36 BrowserThread::PostTask( 36 BrowserThread::PostTask(
37 BrowserThread::UI, FROM_HERE, 37 BrowserThread::UI, FROM_HERE,
38 base::Bind(&SynchronousInputEventFilter::SetBoundHandlerOnUIThread, 38 base::Bind(&SynchronousInputEventFilter::SetBoundHandlerOnUIThread,
39 base::Unretained(this), handler)); 39 base::Unretained(this), handler));
40 } 40 }
41 41
42 void SynchronousInputEventFilter::SetBoundHandlerOnUIThread( 42 void SynchronousInputEventFilter::SetBoundHandlerOnUIThread(
43 const Handler& handler) { 43 const Handler& handler) {
44 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 44 DCHECK_CURRENTLY_ON(BrowserThread::UI);
45 handler_ = handler; 45 handler_ = handler;
46 } 46 }
47 47
48 void SynchronousInputEventFilter::DidAddInputHandler( 48 void SynchronousInputEventFilter::DidAddInputHandler(
49 int routing_id, 49 int routing_id,
50 cc::InputHandler* input_handler) { 50 cc::InputHandler* input_handler) {
51 // The SynchronusCompositorImpl can be NULL if the WebContents that it's 51 // The SynchronusCompositorImpl can be NULL if the WebContents that it's
52 // bound to has already been deleted. 52 // bound to has already been deleted.
53 SynchronousCompositorImpl* compositor = 53 SynchronousCompositorImpl* compositor =
54 SynchronousCompositorImpl::FromRoutingID(routing_id); 54 SynchronousCompositorImpl::FromRoutingID(routing_id);
(...skipping 24 matching lines...) Expand all
79 void SynchronousInputEventFilter::DidStopFlinging(int routing_id) { 79 void SynchronousInputEventFilter::DidStopFlinging(int routing_id) {
80 // The SynchronusCompositorImpl can be NULL if the WebContents that it's 80 // The SynchronusCompositorImpl can be NULL if the WebContents that it's
81 // bound to has already been deleted. 81 // bound to has already been deleted.
82 SynchronousCompositorImpl* compositor = 82 SynchronousCompositorImpl* compositor =
83 SynchronousCompositorImpl::FromRoutingID(routing_id); 83 SynchronousCompositorImpl::FromRoutingID(routing_id);
84 if (compositor) 84 if (compositor)
85 compositor->DidStopFlinging(); 85 compositor->DidStopFlinging();
86 } 86 }
87 87
88 } // namespace content 88 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/android/download_controller_android_impl.cc ('k') | content/browser/appcache/chrome_appcache_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698