Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2000 Simon Hausmann <hausmann@kde.org> | 3 * (C) 2000 Simon Hausmann <hausmann@kde.org> |
| 4 * Copyright (C) 2006, 2009 Apple Inc. All rights reserved. | 4 * Copyright (C) 2006, 2009 Apple Inc. All rights reserved. |
| 5 * | 5 * |
| 6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
| 7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
| 8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
| 9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
| 10 * | 10 * |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 42 bool NeedsPreferredWidthsRecalculation() const final; | 42 bool NeedsPreferredWidthsRecalculation() const final; |
| 43 | 43 |
| 44 bool NodeAtPoint(HitTestResult&, | 44 bool NodeAtPoint(HitTestResult&, |
| 45 const HitTestLocation& location_in_container, | 45 const HitTestLocation& location_in_container, |
| 46 const LayoutPoint& accumulated_offset, | 46 const LayoutPoint& accumulated_offset, |
| 47 HitTestAction) override; | 47 HitTestAction) override; |
| 48 | 48 |
| 49 void Ref() { ++ref_count_; } | 49 void Ref() { ++ref_count_; } |
| 50 void Deref(); | 50 void Deref(); |
| 51 | 51 |
| 52 FrameViewBase* GetFrameViewBase() const; | 52 // LayoutPart::GetNodeFrameView returns the FrameView associated with |
| 53 // the current Node, if Node is HTMLFrameOwnerElement. | |
| 54 // This is different to LayoutObject::GetFrameView which returns | |
| 55 // the FrameView associated with the root Document Frame. | |
|
haraken
2017/04/12 07:21:01
I'm wondering when the two FrameViews can differ.
dcheng
2017/04/12 23:44:37
The difference is kind of subtle, but my understan
| |
| 56 FrameView* GetNodeFrameView() const; | |
| 53 PluginView* Plugin() const; | 57 PluginView* Plugin() const; |
| 54 // TODO(joelhockey): This method will be removed once FrameViewBase | |
| 55 // class is removed. New abstract base classes will be defined | |
| 56 // for when polymorphism is required for plugins and frames and | |
| 57 // other methods provided. | |
| 58 FrameViewBase* PluginOrFrame() const; | 58 FrameViewBase* PluginOrFrame() const; |
| 59 | 59 |
| 60 LayoutRect ReplacedContentRect() const final; | 60 LayoutRect ReplacedContentRect() const final; |
| 61 | 61 |
| 62 void UpdateOnWidgetChange(); | 62 void UpdateOnWidgetChange(); |
| 63 void UpdateGeometry(); | 63 void UpdateGeometry(); |
| 64 | 64 |
| 65 bool IsLayoutPart() const final { return true; } | 65 bool IsLayoutPart() const final { return true; } |
| 66 virtual void PaintContents(const PaintInfo&, const LayoutPoint&) const; | 66 virtual void PaintContents(const PaintInfo&, const LayoutPoint&) const; |
| 67 | 67 |
| (...skipping 25 matching lines...) Expand all Loading... | |
| 93 HitTestAction); | 93 HitTestAction); |
| 94 | 94 |
| 95 int ref_count_; | 95 int ref_count_; |
| 96 }; | 96 }; |
| 97 | 97 |
| 98 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutPart, IsLayoutPart()); | 98 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutPart, IsLayoutPart()); |
| 99 | 99 |
| 100 } // namespace blink | 100 } // namespace blink |
| 101 | 101 |
| 102 #endif // LayoutPart_h | 102 #endif // LayoutPart_h |
| OLD | NEW |