| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "bindings/core/v8/V8DOMActivityLogger.h" | 5 #include "bindings/core/v8/V8DOMActivityLogger.h" |
| 6 | 6 |
| 7 #include "bindings/core/v8/V8Binding.h" | 7 #include "bindings/core/v8/V8Binding.h" |
| 8 #include "platform/weborigin/KURL.h" | 8 #include "platform/weborigin/KURL.h" |
| 9 #include "wtf/HashMap.h" | 9 #include "wtf/HashMap.h" |
| 10 #include "wtf/MainThread.h" | |
| 11 #include "wtf/text/StringHash.h" | 10 #include "wtf/text/StringHash.h" |
| 12 | 11 |
| 13 namespace blink { | 12 namespace blink { |
| 14 | 13 |
| 15 typedef HashMap<String, OwnPtr<V8DOMActivityLogger>> DOMActivityLoggerMapForMain
World; | 14 typedef HashMap<String, OwnPtr<V8DOMActivityLogger>> DOMActivityLoggerMapForMain
World; |
| 16 typedef HashMap<int, OwnPtr<V8DOMActivityLogger>, WTF::IntHash<int>, WTF::Unsign
edWithZeroKeyHashTraits<int>> DOMActivityLoggerMapForIsolatedWorld; | 15 typedef HashMap<int, OwnPtr<V8DOMActivityLogger>, WTF::IntHash<int>, WTF::Unsign
edWithZeroKeyHashTraits<int>> DOMActivityLoggerMapForIsolatedWorld; |
| 17 | 16 |
| 18 static DOMActivityLoggerMapForMainWorld& domActivityLoggersForMainWorld() | 17 static DOMActivityLoggerMapForMainWorld& domActivityLoggersForMainWorld() |
| 19 { | 18 { |
| 20 ASSERT(isMainThread()); | 19 ASSERT(isMainThread()); |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 102 return 0; | 101 return 0; |
| 103 | 102 |
| 104 V8PerContextData* contextData = scriptState->perContextData(); | 103 V8PerContextData* contextData = scriptState->perContextData(); |
| 105 if (!contextData) | 104 if (!contextData) |
| 106 return 0; | 105 return 0; |
| 107 | 106 |
| 108 return contextData->activityLogger(); | 107 return contextData->activityLogger(); |
| 109 } | 108 } |
| 110 | 109 |
| 111 } // namespace blink | 110 } // namespace blink |
| OLD | NEW |