| 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 #ifndef CONTENT_RENDERER_MOJO_CONTEXT_STATE_H_ | 5 #ifndef CONTENT_RENDERER_MOJO_CONTEXT_STATE_H_ |
| 6 #define CONTENT_RENDERER_MOJO_CONTEXT_STATE_H_ | 6 #define CONTENT_RENDERER_MOJO_CONTEXT_STATE_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> | 10 #include <string> |
| 11 #include <vector> |
| 11 | 12 |
| 12 #include "base/macros.h" | 13 #include "base/macros.h" |
| 13 #include "base/memory/scoped_vector.h" | |
| 14 #include "gin/modules/module_registry_observer.h" | 14 #include "gin/modules/module_registry_observer.h" |
| 15 #include "v8/include/v8.h" | 15 #include "v8/include/v8.h" |
| 16 | 16 |
| 17 namespace blink { | 17 namespace blink { |
| 18 class WebFrame; | 18 class WebFrame; |
| 19 class WebURLResponse; | 19 class WebURLResponse; |
| 20 } | 20 } |
| 21 | 21 |
| 22 namespace content { | 22 namespace content { |
| 23 | 23 |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 63 // Frame script is executed in. Also used to download resources. | 63 // Frame script is executed in. Also used to download resources. |
| 64 blink::WebFrame* frame_; | 64 blink::WebFrame* frame_; |
| 65 | 65 |
| 66 // See description above getter. | 66 // See description above getter. |
| 67 bool module_added_; | 67 bool module_added_; |
| 68 | 68 |
| 69 // Executes the script from gin. | 69 // Executes the script from gin. |
| 70 std::unique_ptr<MojoMainRunner> runner_; | 70 std::unique_ptr<MojoMainRunner> runner_; |
| 71 | 71 |
| 72 // Set of fetchers we're waiting on to download script. | 72 // Set of fetchers we're waiting on to download script. |
| 73 ScopedVector<ResourceFetcher> module_fetchers_; | 73 std::vector<std::unique_ptr<ResourceFetcher>> module_fetchers_; |
| 74 | 74 |
| 75 // Set of modules we've fetched script from. | 75 // Set of modules we've fetched script from. |
| 76 std::set<std::string> fetched_modules_; | 76 std::set<std::string> fetched_modules_; |
| 77 | 77 |
| 78 // The prefix to use for all module requests. | 78 // The prefix to use for all module requests. |
| 79 const std::string module_prefix_; | 79 const std::string module_prefix_; |
| 80 | 80 |
| 81 DISALLOW_COPY_AND_ASSIGN(MojoContextState); | 81 DISALLOW_COPY_AND_ASSIGN(MojoContextState); |
| 82 }; | 82 }; |
| 83 | 83 |
| 84 } // namespace content | 84 } // namespace content |
| 85 | 85 |
| 86 #endif // CONTENT_RENDERER_MOJO_CONTEXT_STATE_H_ | 86 #endif // CONTENT_RENDERER_MOJO_CONTEXT_STATE_H_ |
| OLD | NEW |