Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(328)

Side by Side Diff: third_party/WebKit/Source/core/dom/ModuleScript.cpp

Issue 2819733002: Implement ModuleScript::RunScript() (Closed)
Patch Set: Rebase Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 "core/dom/ModuleScript.h" 5 #include "core/dom/ModuleScript.h"
6 6
7 #include "bindings/core/v8/ScriptState.h" 7 #include "bindings/core/v8/ScriptState.h"
8 #include "bindings/core/v8/ScriptValue.h" 8 #include "bindings/core/v8/ScriptValue.h"
9 #include "v8/include/v8.h" 9 #include "v8/include/v8.h"
10 10
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 } 51 }
52 52
53 bool ModuleScript::CheckMIMETypeBeforeRunScript(Document* context_document, 53 bool ModuleScript::CheckMIMETypeBeforeRunScript(Document* context_document,
54 const SecurityOrigin*) const { 54 const SecurityOrigin*) const {
55 // We don't check MIME type here because we check the MIME type in 55 // We don't check MIME type here because we check the MIME type in
56 // ModuleScriptLoader::WasModuleLoadSuccessful(). 56 // ModuleScriptLoader::WasModuleLoadSuccessful().
57 return true; 57 return true;
58 } 58 }
59 59
60 void ModuleScript::RunScript(LocalFrame* frame, const SecurityOrigin*) const { 60 void ModuleScript::RunScript(LocalFrame* frame, const SecurityOrigin*) const {
61 // TODO(hiroshige): Implement this once Modulator::ExecuteModule() is landed. 61 settings_object_->ExecuteModule(this);
62 NOTREACHED();
63 } 62 }
64 63
65 String ModuleScript::InlineSourceTextForCSP() const { 64 String ModuleScript::InlineSourceTextForCSP() const {
66 // Currently we don't support inline module scripts. 65 // Currently we don't support inline module scripts.
67 // TODO(hiroshige): Implement this. 66 // TODO(hiroshige): Implement this.
68 NOTREACHED(); 67 NOTREACHED();
69 return String(); 68 return String();
70 } 69 }
71 70
72 } // namespace blink 71 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698