OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> | 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> |
3 * 1999-2001 Lars Knoll <knoll@kde.org> | 3 * 1999-2001 Lars Knoll <knoll@kde.org> |
4 * 1999-2001 Antti Koivisto <koivisto@kde.org> | 4 * 1999-2001 Antti Koivisto <koivisto@kde.org> |
5 * 2000-2001 Simon Hausmann <hausmann@kde.org> | 5 * 2000-2001 Simon Hausmann <hausmann@kde.org> |
6 * 2000-2001 Dirk Mueller <mueller@kde.org> | 6 * 2000-2001 Dirk Mueller <mueller@kde.org> |
7 * 2000 Stefan Schimanski <1Stein@gmx.de> | 7 * 2000 Stefan Schimanski <1Stein@gmx.de> |
8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights
reserved. | 8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights
reserved. |
9 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 9 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
10 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> | 10 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> |
(...skipping 19 matching lines...) Expand all Loading... |
30 | 30 |
31 #include "sky/engine/core/frame/Frame.h" | 31 #include "sky/engine/core/frame/Frame.h" |
32 #include "sky/engine/core/loader/FrameLoader.h" | 32 #include "sky/engine/core/loader/FrameLoader.h" |
33 #include "sky/engine/platform/Supplementable.h" | 33 #include "sky/engine/platform/Supplementable.h" |
34 #include "sky/engine/platform/heap/Handle.h" | 34 #include "sky/engine/platform/heap/Handle.h" |
35 #include "sky/engine/wtf/HashSet.h" | 35 #include "sky/engine/wtf/HashSet.h" |
36 | 36 |
37 namespace blink { | 37 namespace blink { |
38 | 38 |
39 class Color; | 39 class Color; |
| 40 class DartController; |
40 class Document; | 41 class Document; |
41 class Editor; | 42 class Editor; |
42 class Element; | 43 class Element; |
43 class EventHandler; | 44 class EventHandler; |
44 class FetchContext; | 45 class FetchContext; |
45 class FloatRect; | 46 class FloatRect; |
46 class FloatSize; | 47 class FloatSize; |
47 class FrameConsole; | 48 class FrameConsole; |
48 class FrameDestructionObserver; | 49 class FrameDestructionObserver; |
49 class FrameSelection; | 50 class FrameSelection; |
50 class FrameView; | 51 class FrameView; |
51 class InputMethodController; | 52 class InputMethodController; |
52 class IntPoint; | 53 class IntPoint; |
53 class IntSize; | 54 class IntSize; |
54 class MojoLoader; | 55 class MojoLoader; |
55 class NewEventHandler; | 56 class NewEventHandler; |
56 class Node; | 57 class Node; |
57 class Range; | 58 class Range; |
58 class RenderView; | 59 class RenderView; |
59 class ScriptController; | |
60 class SpellChecker; | 60 class SpellChecker; |
61 class TreeScope; | 61 class TreeScope; |
62 class TreeScope; | 62 class TreeScope; |
63 class VisiblePosition; | 63 class VisiblePosition; |
64 | 64 |
65 class LocalFrame : public Frame, public Supplementable<LocalFrame> { | 65 class LocalFrame : public Frame, public Supplementable<LocalFrame> { |
66 public: | 66 public: |
67 static PassRefPtr<LocalFrame> create(FrameLoaderClient*, FrameHost*); | 67 static PassRefPtr<LocalFrame> create(FrameLoaderClient*, FrameHost*); |
68 | 68 |
69 void setView(PassRefPtr<FrameView>); | 69 void setView(PassRefPtr<FrameView>); |
(...skipping 15 matching lines...) Expand all Loading... |
85 | 85 |
86 RenderView* contentRenderer() const; // Root of the render tree for the
document contained in this frame. | 86 RenderView* contentRenderer() const; // Root of the render tree for the
document contained in this frame. |
87 | 87 |
88 Editor& editor() const; | 88 Editor& editor() const; |
89 EventHandler& eventHandler() const; | 89 EventHandler& eventHandler() const; |
90 NewEventHandler& newEventHandler() const; | 90 NewEventHandler& newEventHandler() const; |
91 MojoLoader& mojoLoader() const { return *m_mojoLoader; } | 91 MojoLoader& mojoLoader() const { return *m_mojoLoader; } |
92 FrameSelection& selection() const; | 92 FrameSelection& selection() const; |
93 InputMethodController& inputMethodController() const; | 93 InputMethodController& inputMethodController() const; |
94 FetchContext& fetchContext() const; | 94 FetchContext& fetchContext() const; |
95 ScriptController& script(); | 95 DartController& dart(); |
96 SpellChecker& spellChecker() const; | 96 SpellChecker& spellChecker() const; |
97 FrameConsole& console() const; | 97 FrameConsole& console() const; |
98 | 98 |
99 void didChangeVisibilityState(); | 99 void didChangeVisibilityState(); |
100 | 100 |
101 FrameLoaderClient* loaderClient() const; | 101 FrameLoaderClient* loaderClient() const; |
102 | 102 |
103 // ======== All public functions below this point are candidates to move out
of LocalFrame into another class. ======== | 103 // ======== All public functions below this point are candidates to move out
of LocalFrame into another class. ======== |
104 | 104 |
105 FloatSize resizePageRectsKeepingRatio(const FloatSize& originalSize, con
st FloatSize& expectedSize); | 105 FloatSize resizePageRectsKeepingRatio(const FloatSize& originalSize, con
st FloatSize& expectedSize); |
(...skipping 13 matching lines...) Expand all Loading... |
119 | 119 |
120 private: | 120 private: |
121 LocalFrame(FrameLoaderClient*, FrameHost*); | 121 LocalFrame(FrameLoaderClient*, FrameHost*); |
122 | 122 |
123 HashSet<FrameDestructionObserver*> m_destructionObservers; | 123 HashSet<FrameDestructionObserver*> m_destructionObservers; |
124 mutable FrameLoader m_deprecatedLoader; | 124 mutable FrameLoader m_deprecatedLoader; |
125 OwnPtr<MojoLoader> m_mojoLoader; | 125 OwnPtr<MojoLoader> m_mojoLoader; |
126 | 126 |
127 RefPtr<FrameView> m_view; | 127 RefPtr<FrameView> m_view; |
128 | 128 |
129 OwnPtr<ScriptController> m_script; | 129 OwnPtr<DartController> m_dart; |
130 const OwnPtr<Editor> m_editor; | 130 const OwnPtr<Editor> m_editor; |
131 const OwnPtr<SpellChecker> m_spellChecker; | 131 const OwnPtr<SpellChecker> m_spellChecker; |
132 const OwnPtr<FrameSelection> m_selection; | 132 const OwnPtr<FrameSelection> m_selection; |
133 const OwnPtr<EventHandler> m_eventHandler; | 133 const OwnPtr<EventHandler> m_eventHandler; |
134 const OwnPtr<NewEventHandler> m_newEventHandler; | 134 const OwnPtr<NewEventHandler> m_newEventHandler; |
135 const OwnPtr<FrameConsole> m_console; | 135 const OwnPtr<FrameConsole> m_console; |
136 OwnPtr<InputMethodController> m_inputMethodController; | 136 OwnPtr<InputMethodController> m_inputMethodController; |
137 }; | 137 }; |
138 | 138 |
139 inline FrameView* LocalFrame::view() const | 139 inline FrameView* LocalFrame::view() const |
140 { | 140 { |
141 return m_view.get(); | 141 return m_view.get(); |
142 } | 142 } |
143 | 143 |
144 inline ScriptController& LocalFrame::script() | 144 inline DartController& LocalFrame::dart() |
145 { | 145 { |
146 return *m_script; | 146 return *m_dart; |
147 } | 147 } |
148 | 148 |
149 inline FrameSelection& LocalFrame::selection() const | 149 inline FrameSelection& LocalFrame::selection() const |
150 { | 150 { |
151 return *m_selection; | 151 return *m_selection; |
152 } | 152 } |
153 | 153 |
154 inline Editor& LocalFrame::editor() const | 154 inline Editor& LocalFrame::editor() const |
155 { | 155 { |
156 return *m_editor; | 156 return *m_editor; |
(...skipping 29 matching lines...) Expand all Loading... |
186 DEFINE_TYPE_CASTS(LocalFrame, Frame, localFrame, true, true); | 186 DEFINE_TYPE_CASTS(LocalFrame, Frame, localFrame, true, true); |
187 | 187 |
188 } // namespace blink | 188 } // namespace blink |
189 | 189 |
190 // During refactoring, there are some places where we need to do type conversion
s that | 190 // During refactoring, there are some places where we need to do type conversion
s that |
191 // will not be needed once all instances of LocalFrame and RemoteFrame are sorte
d out. | 191 // will not be needed once all instances of LocalFrame and RemoteFrame are sorte
d out. |
192 // At that time this #define will be removed and all the uses of it will need to
be corrected. | 192 // At that time this #define will be removed and all the uses of it will need to
be corrected. |
193 #define toLocalFrameTemporary toLocalFrame | 193 #define toLocalFrameTemporary toLocalFrame |
194 | 194 |
195 #endif // SKY_ENGINE_CORE_FRAME_LOCALFRAME_H_ | 195 #endif // SKY_ENGINE_CORE_FRAME_LOCALFRAME_H_ |
OLD | NEW |