| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2014 Google Inc. All rights reserved. | 2 * Copyright (C) 2014 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 20 matching lines...) Expand all Loading... |
| 31 #include "config.h" | 31 #include "config.h" |
| 32 | 32 |
| 33 #include "public/web/WebLeakDetector.h" | 33 #include "public/web/WebLeakDetector.h" |
| 34 | 34 |
| 35 #include "bindings/v8/V8Binding.h" | 35 #include "bindings/v8/V8Binding.h" |
| 36 #include "core/fetch/MemoryCache.h" | 36 #include "core/fetch/MemoryCache.h" |
| 37 #include "core/fetch/ResourceFetcher.h" | 37 #include "core/fetch/ResourceFetcher.h" |
| 38 #include "core/frame/DOMWindow.h" | 38 #include "core/frame/DOMWindow.h" |
| 39 #include "core/inspector/InspectorCounters.h" | 39 #include "core/inspector/InspectorCounters.h" |
| 40 #include "public/web/WebDocument.h" | 40 #include "public/web/WebDocument.h" |
| 41 #include "public/web/WebFrame.h" | 41 #include "public/web/WebLocalFrame.h" |
| 42 | 42 |
| 43 #include <v8.h> | 43 #include <v8.h> |
| 44 | 44 |
| 45 using namespace WebCore; | 45 using namespace WebCore; |
| 46 | 46 |
| 47 namespace { | 47 namespace { |
| 48 | 48 |
| 49 void cleanUpDOMObjects(blink::WebFrame* frame) | 49 void cleanUpDOMObjects(blink::WebFrame* frame) |
| 50 { | 50 { |
| 51 v8::HandleScope handleScope(v8::Isolate::GetCurrent()); | 51 v8::HandleScope handleScope(v8::Isolate::GetCurrent()); |
| (...skipping 26 matching lines...) Expand all Loading... |
| 78 namespace blink { | 78 namespace blink { |
| 79 | 79 |
| 80 void WebLeakDetector::collectGarbargeAndGetDOMCounts(WebLocalFrame* frame, unsig
ned* numberOfLiveDocuments, unsigned* numberOfLiveNodes) | 80 void WebLeakDetector::collectGarbargeAndGetDOMCounts(WebLocalFrame* frame, unsig
ned* numberOfLiveDocuments, unsigned* numberOfLiveNodes) |
| 81 { | 81 { |
| 82 // FIXME: Count other DOM objects using WTF::dumpRefCountedInstanceCounts. | 82 // FIXME: Count other DOM objects using WTF::dumpRefCountedInstanceCounts. |
| 83 cleanUpDOMObjects(frame); | 83 cleanUpDOMObjects(frame); |
| 84 numberOfDOMObjects(frame, numberOfLiveDocuments, numberOfLiveNodes); | 84 numberOfDOMObjects(frame, numberOfLiveDocuments, numberOfLiveNodes); |
| 85 } | 85 } |
| 86 | 86 |
| 87 } // namespace blink | 87 } // namespace blink |
| OLD | NEW |