refactor: update chrome.scripting extensions api impls (#43289)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
This commit is contained in:
parent
8dc4d3c040
commit
07668c11d3
3 changed files with 200 additions and 229 deletions
|
@ -191,6 +191,15 @@ class ScriptingUpdateContentScriptsFunction : public ExtensionFunction {
|
|||
private:
|
||||
~ScriptingUpdateContentScriptsFunction() override;
|
||||
|
||||
// Returns a UserScript object by updating the `original_script` with the
|
||||
// `new_script` given delta. If the updated script cannot be parsed, populates
|
||||
// `parse_error` and returns nullptr.
|
||||
std::unique_ptr<UserScript> ApplyUpdate(
|
||||
std::set<std::string>* script_ids_to_persist,
|
||||
api::scripting::RegisteredContentScript& new_script,
|
||||
api::scripting::RegisteredContentScript& original_script,
|
||||
std::u16string* parse_error);
|
||||
|
||||
// Called when script files have been checked.
|
||||
void OnContentScriptFilesValidated(
|
||||
std::set<std::string> persistent_script_ids,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue