diff options
author | treib <treib@chromium.org> | 2015-05-20 05:56:07 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-05-20 12:56:03 +0000 |
commit | c11923254ee7e930b2cd3431d94a6937982906f9 (patch) | |
tree | 8f36f6fc40434cbdb109cf78a53a41d3638eeacb /sync | |
parent | ef99191240af78a81c19f34cf39c5097208246b7 (diff) | |
download | chromium_src-c11923254ee7e930b2cd3431d94a6937982906f9.zip chromium_src-c11923254ee7e930b2cd3431d94a6937982906f9.tar.gz chromium_src-c11923254ee7e930b2cd3431d94a6937982906f9.tar.bz2 |
Extensions: Store disable reasons in Sync
This will allow us (in a follow-up CL) to *not* grant permissions to extensions that come in via Sync disabled due to a permission increase.
BUG=484214
Review URL: https://codereview.chromium.org/1136543003
Cr-Commit-Position: refs/heads/master@{#330727}
Diffstat (limited to 'sync')
-rw-r--r-- | sync/protocol/extension_specifics.proto | 5 | ||||
-rw-r--r-- | sync/protocol/proto_value_conversions.cc | 3 |
2 files changed, 7 insertions, 1 deletions
diff --git a/sync/protocol/extension_specifics.proto b/sync/protocol/extension_specifics.proto index 8e724a3..a854e01 100644 --- a/sync/protocol/extension_specifics.proto +++ b/sync/protocol/extension_specifics.proto @@ -48,5 +48,10 @@ message ExtensionSpecifics { // optional and may be absent. We need this for the time being because we need // to know if a user has not set an explicit preference. optional bool all_urls_enabled = 9; + + // Bitmask of the set of reasons why the extension is disabled (see + // Extension::DisableReason). Only relevant when enabled == false. Note that + // old clients (<M45) won't set this, even when enabled is false. + optional int32 disable_reasons = 10; } diff --git a/sync/protocol/proto_value_conversions.cc b/sync/protocol/proto_value_conversions.cc index 3ce9528..758729b 100644 --- a/sync/protocol/proto_value_conversions.cc +++ b/sync/protocol/proto_value_conversions.cc @@ -456,10 +456,11 @@ scoped_ptr<base::DictionaryValue> ExtensionSpecificsToValue( SET_STR(update_url); SET_BOOL(enabled); SET_BOOL(incognito_enabled); + SET_STR(name); SET_BOOL(remote_install); SET_BOOL(installed_by_custodian); SET_BOOL(all_urls_enabled); - SET_STR(name); + SET_INT32(disable_reasons); return value; } |