| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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.#ifndef WebViewBase_h | 3 // found in the LICENSE file.#ifndef WebViewBase_h |
| 4 | 4 |
| 5 #ifndef WebLocalFrameBase_h | 5 #ifndef WebLocalFrameBase_h |
| 6 #define WebLocalFrameBase_h | 6 #define WebLocalFrameBase_h |
| 7 | 7 |
| 8 #include "core/CoreExport.h" | 8 #include "core/CoreExport.h" |
| 9 #include "public/web/WebLocalFrame.h" | 9 #include "public/web/WebLocalFrame.h" |
| 10 | 10 |
| 11 namespace blink { | 11 namespace blink { |
| 12 | 12 |
| 13 class LocalFrame; | 13 class LocalFrame; |
| 14 class Node; |
| 15 class WebFrameClient; |
| 16 class WebTextCheckClient; |
| 17 class WebViewBase; |
| 14 | 18 |
| 15 // WebLocalFrameBase is a temporary class the provides a layer of abstraction | 19 // WebLocalFrameBase is a temporary class the provides a layer of abstraction |
| 16 // for WebLocalFrameImpl. Mehtods that are declared public in WebLocalFrameImpl | 20 // for WebLocalFrameImpl. Mehtods that are declared public in WebLocalFrameImpl |
| 17 // that are not overrides from WebLocalFrame will be declared pure virtual in | 21 // that are not overrides from WebLocalFrame will be declared pure virtual in |
| 18 // WebLocalFrameBase. Classes that then have a dependency on WebLocalFrameImpl | 22 // WebLocalFrameBase. Classes that then have a dependency on WebLocalFrameImpl |
| 19 // will then take a dependency on WebLocalFrameBase instead, so we can remove | 23 // will then take a dependency on WebLocalFrameBase instead, so we can remove |
| 20 // cyclic dependencies in web/ and move classes from web/ into core/ or | 24 // cyclic dependencies in web/ and move classes from web/ into core/ or |
| 21 // modules. | 25 // modules. |
| 22 // TODO(slangley): Remove this class once WebLocalFrameImpl is in core/. | 26 // TODO(slangley): Remove this class once WebLocalFrameImpl is in core/. |
| 23 class WebLocalFrameBase : public WebLocalFrame { | 27 class WebLocalFrameBase : public WebLocalFrame { |
| 24 public: | 28 public: |
| 25 CORE_EXPORT static WebLocalFrameBase* FromFrame(LocalFrame*); | 29 CORE_EXPORT static WebLocalFrameBase* FromFrame(LocalFrame*); |
| 26 CORE_EXPORT static WebLocalFrameBase* FromFrame(LocalFrame&); | 30 CORE_EXPORT static WebLocalFrameBase* FromFrame(LocalFrame&); |
| 27 | 31 |
| 32 virtual WebViewBase* ViewImpl() const = 0; |
| 33 virtual WebFrameClient* Client() const = 0; |
| 34 virtual WebTextCheckClient* TextCheckClient() const = 0; |
| 35 virtual void SetContextMenuNode(Node*) = 0; |
| 36 virtual void ClearContextMenuNode() = 0; |
| 37 |
| 28 protected: | 38 protected: |
| 29 explicit WebLocalFrameBase(WebTreeScopeType scope) : WebLocalFrame(scope) {} | 39 explicit WebLocalFrameBase(WebTreeScopeType scope) : WebLocalFrame(scope) {} |
| 30 }; | 40 }; |
| 31 } | 41 } |
| 32 | 42 |
| 33 #endif // WebLocalFrameBase_h | 43 #endif // WebLocalFrameBase_h |
| OLD | NEW |