| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/java/gin_java_bridge_message_filter.h" | 5 #include "content/browser/android/java/gin_java_bridge_message_filter.h" |
| 6 | 6 |
| 7 #include "base/auto_reset.h" | 7 #include "base/auto_reset.h" |
| 8 #include "build/build_config.h" | 8 #include "build/build_config.h" |
| 9 #include "content/browser/android/java/gin_java_bridge_dispatcher_host.h" | 9 #include "content/browser/android/java/gin_java_bridge_dispatcher_host.h" |
| 10 #include "content/browser/android/java/java_bridge_thread.h" | 10 #include "content/browser/android/java/java_bridge_thread.h" |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 } | 161 } |
| 162 | 162 |
| 163 void GinJavaBridgeMessageFilter::OnObjectWrapperDeleted( | 163 void GinJavaBridgeMessageFilter::OnObjectWrapperDeleted( |
| 164 GinJavaBoundObject::ObjectID object_id) { | 164 GinJavaBoundObject::ObjectID object_id) { |
| 165 DCHECK(JavaBridgeThread::CurrentlyOn()); | 165 DCHECK(JavaBridgeThread::CurrentlyOn()); |
| 166 GinJavaBridgeDispatcherHost* host = FindHost(); | 166 GinJavaBridgeDispatcherHost* host = FindHost(); |
| 167 if (host) | 167 if (host) |
| 168 host->OnObjectWrapperDeleted(current_routing_id_, object_id); | 168 host->OnObjectWrapperDeleted(current_routing_id_, object_id); |
| 169 } | 169 } |
| 170 | 170 |
| 171 // static |
| 172 void GinJavaBridgeMessageFilter::RemoveFilter( |
| 173 GinJavaBridgeDispatcherHost* host) { |
| 174 RenderProcessHost* rph = host->web_contents()->GetRenderProcessHost(); |
| 175 rph->RemoveUserData(kGinJavaBridgeMessageFilterKey); |
| 176 } |
| 177 |
| 171 } // namespace content | 178 } // namespace content |
| OLD | NEW |