Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef InspectorResourceContentLoader_h | |
| 6 #define InspectorResourceContentLoader_h | |
| 7 | |
| 8 #include "core/fetch/RawResource.h" | |
| 9 #include "core/fetch/StyleSheetResourceClient.h" | |
| 10 #include "wtf/HashMap.h" | |
| 11 #include "wtf/Noncopyable.h" | |
| 12 #include "wtf/Vector.h" | |
| 13 | |
| 14 namespace WebCore { | |
| 15 | |
| 16 class Page; | |
| 17 class RawResourceClient; | |
| 18 class StyleSheetResourceClient; | |
| 19 class VoidCallback; | |
| 20 | |
| 21 class InspectorResourceContentLoader FINAL : private RawResourceClient, private StyleSheetResourceClient { | |
| 22 WTF_MAKE_NONCOPYABLE(InspectorResourceContentLoader); | |
| 23 WTF_MAKE_FAST_ALLOCATED; | |
| 24 public: | |
| 25 InspectorResourceContentLoader(Page*, PassOwnPtr<VoidCallback>); | |
| 26 virtual ~InspectorResourceContentLoader(); | |
| 27 bool hasFinished(); | |
| 28 | |
| 29 private: | |
| 30 virtual void notifyFinished(Resource*) OVERRIDE; | |
| 31 virtual void setCSSStyleSheet(const String& /* href */, const KURL& /* baseU RL */, const String& /* charset */, const CSSStyleSheetResource*); | |
| 32 void resourceFinished(Resource*); | |
| 33 void worked(); | |
| 34 void removeAsClientFromResource(Resource*); | |
| 35 | |
| 36 OwnPtr<VoidCallback> m_callback; | |
| 37 int m_pendingResourcesCount; | |
|
pfeldman
2014/05/20 19:50:49
m_pendingResourceCount
| |
| 38 HashSet<Resource*> m_pendingResources; | |
| 39 Vector<ResourcePtr<Resource> > m_resources; | |
| 40 }; | |
| 41 | |
| 42 } // namespace WebCore | |
| 43 | |
| 44 | |
| 45 #endif // !defined(InspectorResourceContentLoader_h) | |
| OLD | NEW |