| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "chrome/renderer/extensions/render_view_observer_natives.h" | 5 #include "chrome/renderer/extensions/render_view_observer_natives.h" |
| 6 | 6 |
| 7 #include "chrome/common/extensions/api/extension_api.h" | |
| 8 #include "chrome/renderer/extensions/dispatcher.h" | 7 #include "chrome/renderer/extensions/dispatcher.h" |
| 9 #include "content/public/renderer/render_view.h" | 8 #include "content/public/renderer/render_view.h" |
| 10 #include "content/public/renderer/render_view_observer.h" | 9 #include "content/public/renderer/render_view_observer.h" |
| 10 #include "extensions/common/extension_api.h" |
| 11 #include "third_party/WebKit/public/web/WebFrame.h" | 11 #include "third_party/WebKit/public/web/WebFrame.h" |
| 12 #include "third_party/WebKit/public/web/WebScopedMicrotaskSuppression.h" | 12 #include "third_party/WebKit/public/web/WebScopedMicrotaskSuppression.h" |
| 13 | 13 |
| 14 namespace extensions { | 14 namespace extensions { |
| 15 | 15 |
| 16 namespace { | 16 namespace { |
| 17 | 17 |
| 18 // Deletes itself when done. | 18 // Deletes itself when done. |
| 19 class LoadWatcher : public content::RenderViewObserver { | 19 class LoadWatcher : public content::RenderViewObserver { |
| 20 public: | 20 public: |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 72 LOG(WARNING) << "No render view found to register LoadWatcher."; | 72 LOG(WARNING) << "No render view found to register LoadWatcher."; |
| 73 return; | 73 return; |
| 74 } | 74 } |
| 75 | 75 |
| 76 new LoadWatcher(context(), view, args[1].As<v8::Function>()); | 76 new LoadWatcher(context(), view, args[1].As<v8::Function>()); |
| 77 | 77 |
| 78 args.GetReturnValue().Set(true); | 78 args.GetReturnValue().Set(true); |
| 79 } | 79 } |
| 80 | 80 |
| 81 } // namespace extensions | 81 } // namespace extensions |
| OLD | NEW |