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

Side by Side Diff: third_party/WebKit/Source/core/frame/FrameHost.h

Issue 2214263003: CustomElements: taking CustomElementReactionStack out of frameHost (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 24 matching lines...) Expand all
35 #include "platform/heap/Handle.h" 35 #include "platform/heap/Handle.h"
36 #include "wtf/Allocator.h" 36 #include "wtf/Allocator.h"
37 #include "wtf/Noncopyable.h" 37 #include "wtf/Noncopyable.h"
38 #include "wtf/text/AtomicString.h" 38 #include "wtf/text/AtomicString.h"
39 #include <memory> 39 #include <memory>
40 40
41 namespace blink { 41 namespace blink {
42 42
43 class ChromeClient; 43 class ChromeClient;
44 class ConsoleMessageStorage; 44 class ConsoleMessageStorage;
45 class CustomElementReactionStack;
46 class Deprecation; 45 class Deprecation;
47 class EventHandlerRegistry; 46 class EventHandlerRegistry;
48 class OverscrollController; 47 class OverscrollController;
49 class Page; 48 class Page;
50 struct PageScaleConstraints; 49 struct PageScaleConstraints;
51 class PageScaleConstraintsSet; 50 class PageScaleConstraintsSet;
52 class Settings; 51 class Settings;
53 class TopControls; 52 class TopControls;
54 class UseCounter; 53 class UseCounter;
55 class Visitor; 54 class Visitor;
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 109
111 EventHandlerRegistry& eventHandlerRegistry(); 110 EventHandlerRegistry& eventHandlerRegistry();
112 const EventHandlerRegistry& eventHandlerRegistry() const; 111 const EventHandlerRegistry& eventHandlerRegistry() const;
113 112
114 const AtomicString& overrideEncoding() const { return m_overrideEncoding; } 113 const AtomicString& overrideEncoding() const { return m_overrideEncoding; }
115 void setOverrideEncoding(const AtomicString& encoding) { m_overrideEncoding = encoding; } 114 void setOverrideEncoding(const AtomicString& encoding) { m_overrideEncoding = encoding; }
116 115
117 ConsoleMessageStorage& consoleMessageStorage(); 116 ConsoleMessageStorage& consoleMessageStorage();
118 const ConsoleMessageStorage& consoleMessageStorage() const; 117 const ConsoleMessageStorage& consoleMessageStorage() const;
119 118
120 CustomElementReactionStack& customElementReactionStack();
121 const CustomElementReactionStack& customElementReactionStack() const;
122
123 DECLARE_TRACE(); 119 DECLARE_TRACE();
124 120
125 // Don't allow more than a certain number of frames in a page. 121 // Don't allow more than a certain number of frames in a page.
126 // This seems like a reasonable upper bound, and otherwise mutually 122 // This seems like a reasonable upper bound, and otherwise mutually
127 // recursive frameset pages can quickly bring the program to its knees 123 // recursive frameset pages can quickly bring the program to its knees
128 // with exponential growth in the number of frames. 124 // with exponential growth in the number of frames.
129 static const int maxNumberOfFrames = 1000; 125 static const int maxNumberOfFrames = 1000;
130 void incrementSubframeCount() { ++m_subframeCount; } 126 void incrementSubframeCount() { ++m_subframeCount; }
131 void decrementSubframeCount() { ASSERT(m_subframeCount); --m_subframeCount; } 127 void decrementSubframeCount() { ASSERT(m_subframeCount); --m_subframeCount; }
132 int subframeCount() const; 128 int subframeCount() const;
133 129
134 void setDefaultPageScaleLimits(float minScale, float maxScale); 130 void setDefaultPageScaleLimits(float minScale, float maxScale);
135 void setUserAgentPageScaleConstraints(const PageScaleConstraints& newConstra ints); 131 void setUserAgentPageScaleConstraints(const PageScaleConstraints& newConstra ints);
136 132
137 private: 133 private:
138 explicit FrameHost(Page&); 134 explicit FrameHost(Page&);
139 135
140 const Member<Page> m_page; 136 const Member<Page> m_page;
141 const Member<TopControls> m_topControls; 137 const Member<TopControls> m_topControls;
142 const std::unique_ptr<PageScaleConstraintsSet> m_pageScaleConstraintsSet; 138 const std::unique_ptr<PageScaleConstraintsSet> m_pageScaleConstraintsSet;
143 const Member<VisualViewport> m_visualViewport; 139 const Member<VisualViewport> m_visualViewport;
144 const Member<OverscrollController> m_overscrollController; 140 const Member<OverscrollController> m_overscrollController;
145 const Member<EventHandlerRegistry> m_eventHandlerRegistry; 141 const Member<EventHandlerRegistry> m_eventHandlerRegistry;
146 const Member<ConsoleMessageStorage> m_consoleMessageStorage; 142 const Member<ConsoleMessageStorage> m_consoleMessageStorage;
147 const Member<CustomElementReactionStack> m_customElementReactionStack;
148 143
149 AtomicString m_overrideEncoding; 144 AtomicString m_overrideEncoding;
150 int m_subframeCount; 145 int m_subframeCount;
151 }; 146 };
152 147
153 } // namespace blink 148 } // namespace blink
154 149
155 #endif // FrameHost_h 150 #endif // FrameHost_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698