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

Unified Diff: third_party/WebKit/Source/core/frame/WebLocalFrameBase.cpp

Issue 2863913002: Change AudioOutputDeviceClientImpl to use WebLocalFrameBase and move to modules. (Closed)
Patch Set: Created 3 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/frame/WebLocalFrameBase.cpp
diff --git a/third_party/WebKit/Source/core/frame/WebLocalFrameBase.cpp b/third_party/WebKit/Source/core/frame/WebLocalFrameBase.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..5c09d33f16797a58d04591c807145c91b918158c
--- /dev/null
+++ b/third_party/WebKit/Source/core/frame/WebLocalFrameBase.cpp
@@ -0,0 +1,34 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "core/frame/WebLocalFrameBase.h"
+
+namespace blink {
+
+WebLocalFrameBase::CreateFromLocalFramePtrCallback
+ WebLocalFrameBase::create_local_frame_ptr_callback_ = nullptr;
+WebLocalFrameBase::CreateFromLocalFrameRefCallback
+ WebLocalFrameBase::create_local_frame_ref_callback_ = nullptr;
+
+WebLocalFrameBase* WebLocalFrameBase::FromFrame(LocalFrame* frame) {
+ DCHECK(create_local_frame_ptr_callback_);
+ return create_local_frame_ptr_callback_(frame);
+}
+
+WebLocalFrameBase* WebLocalFrameBase::FromFrame(LocalFrame& frame) {
+ DCHECK(create_local_frame_ref_callback_);
+ return create_local_frame_ref_callback_(frame);
dcheng 2017/05/05 04:54:52 Maybe this can just use the pointer version?
slangley 2017/05/05 06:25:00 Done
+}
+
+void WebLocalFrameBase::RegisterCreateFromLocalFramePtrCallback(
+ CreateFromLocalFramePtrCallback callback) {
+ create_local_frame_ptr_callback_ = callback;
+}
+
+void WebLocalFrameBase::RegisterCreateFromLocalFrameRefCallback(
+ CreateFromLocalFrameRefCallback callback) {
+ create_local_frame_ref_callback_ = callback;
+}
+
+} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698