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

Issue 440423003: Clean content_settings_pattern_parser.* from unnecessary dependencies. (Closed)

Created:
6 years, 4 months ago by vasilii
Modified:
6 years, 3 months ago
CC:
chromium-apps-reviews_chromium.org, chromium-reviews, dbeam+watch-options_chromium.org, extensions-reviews_chromium.org, feature-media-reviews_chromium.org, mcasas+watch_chromium.org, miu+watch_chromium.org, posciak+watch_chromium.org, stuartmorgan+watch_chromium.org, wjia+watch_chromium.org
Project:
chromium
Visibility:
Public.

Description

Clean content_settings_pattern_parser.* from unnecessary dependencies on extensions/ and net/. BUG=387079 Committed: https://crrev.com/94a1f29d656ac654ac0248e00f2d47fe2da7d446 Cr-Commit-Position: refs/heads/master@{#292906}

Patch Set 1 #

Total comments: 14

Patch Set 2 : Removed the clients #

Total comments: 3

Patch Set 3 : compilation #

Patch Set 4 : Implement global variable #

Patch Set 5 : WIn compilation #

Patch Set 6 : Fix unit tests on linux #

Patch Set 7 : Fix CrOS tests #

Total comments: 10

Patch Set 8 : try global init #

Patch Set 9 : no DCHECK #

Total comments: 16

Patch Set 10 : @vabr's comments addressed #

Total comments: 4

Patch Set 11 : @vabr and @bauerb comments addressed #

Total comments: 11

Patch Set 12 : answered @blundell comments #

Patch Set 13 : Remove embedder_variables.* #

Total comments: 4

Patch Set 14 : Reorder methods in the correct order #

Total comments: 4

Patch Set 15 : @jochen comments #

Patch Set 16 : rm content_settings_initializer #

Unified diffs Side-by-side diffs Delta from patch set Stats (+192 lines, -182 lines) Patch
M chrome/app/DEPS View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +1 line, -0 lines 0 comments Download
M chrome/app/chrome_main_delegate.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 3 chunks +5 lines, -0 lines 0 comments Download
M chrome/browser/content_settings/content_settings_mock_observer.h View 1 2 3 2 chunks +2 lines, -1 line 0 comments Download
M chrome/browser/content_settings/content_settings_policy_provider.cc View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/extensions/api/content_settings/content_settings_unittest.cc View 1 2 3 6 7 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/notifications/desktop_notification_profile_util.h View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M chrome/chrome_common.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/common/content_settings_pattern.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 7 chunks +11 lines, -77 lines 0 comments Download
M chrome/common/content_settings_pattern.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 12 chunks +84 lines, -56 lines 0 comments Download
M chrome/common/content_settings_pattern_parser.h View 1 2 3 2 chunks +0 lines, -17 lines 0 comments Download
M chrome/common/content_settings_pattern_parser.cc View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +15 lines, -26 lines 0 comments Download
A chrome/common/content_settings_pattern_serializer.h View 1 2 3 4 5 6 7 8 9 1 chunk +30 lines, -0 lines 0 comments Download
A chrome/common/content_settings_pattern_serializer.cc View 1 2 3 1 chunk +26 lines, -0 lines 0 comments Download
M chrome/common/render_messages.cc View 1 2 3 1 chunk +4 lines, -2 lines 0 comments Download
M chrome/test/base/chrome_test_suite.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 2 chunks +5 lines, -0 lines 0 comments Download
M components/content_settings.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -0 lines 0 comments Download
M components/content_settings/core/common/content_settings_types.h View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 55 (2 generated)
vasilii
Hi guys, please review this componentisation effort. Markus: content_settings* rdevlin.cronin@ : c/b/extensions/ stevenjb@chromium.org: chrome/browser/notifications/message_center_settings_controller.cc bauerb@chromium.org: ...
6 years, 4 months ago (2014-08-06 14:43:44 UTC) #1
vabr (Chromium)
Hi Vasilii, Currently not LGTM, because we cannot have the client living in common. If ...
6 years, 4 months ago (2014-08-06 15:14:01 UTC) #2
vasilii
Colin, is there way to have an interface in components/ and the implementation available in ...
6 years, 4 months ago (2014-08-06 15:31:21 UTC) #3
Joao da Silva
policy_browsertest.cc lgtm
6 years, 4 months ago (2014-08-06 16:21:11 UTC) #4
blundell
Hi Vasilii, Thanks for this work! +1 to vabr's comment: the client here is going ...
6 years, 4 months ago (2014-08-07 07:06:34 UTC) #5
Devlin
Once the layering is figured out, extensions lgtm. (Please ping if anything significant changes.)
6 years, 4 months ago (2014-08-07 16:03:13 UTC) #6
Bernhard Bauer
https://codereview.chromium.org/440423003/diff/1/chrome/common/content_settings_pattern_parser.cc File chrome/common/content_settings_pattern_parser.cc (right): https://codereview.chromium.org/440423003/diff/1/chrome/common/content_settings_pattern_parser.cc#newcode13 chrome/common/content_settings_pattern_parser.cc:13: const char* kDomainWildcard = "[*.]"; If you're touching this ...
6 years, 4 months ago (2014-08-11 08:43:51 UTC) #7
vasilii
Guys, please review again. https://codereview.chromium.org/440423003/diff/1/chrome/browser/content_settings/content_settings_details.h File chrome/browser/content_settings/content_settings_details.h (right): https://codereview.chromium.org/440423003/diff/1/chrome/browser/content_settings/content_settings_details.h#newcode42 chrome/browser/content_settings/content_settings_details.h:42: return primary_pattern_.ToString(&client).empty() && On 2014/08/06 ...
6 years, 4 months ago (2014-08-11 13:57:18 UTC) #8
Bernhard Bauer
https://codereview.chromium.org/440423003/diff/1/chrome/common/content_settings_pattern_parser.cc File chrome/common/content_settings_pattern_parser.cc (right): https://codereview.chromium.org/440423003/diff/1/chrome/common/content_settings_pattern_parser.cc#newcode13 chrome/common/content_settings_pattern_parser.cc:13: const char* kDomainWildcard = "[*.]"; On 2014/08/11 13:57:18, vasilii ...
6 years, 4 months ago (2014-08-11 14:06:44 UTC) #9
blundell
Hi Vasilii, Could you add some more context to the CL description listing the dependencies ...
6 years, 4 months ago (2014-08-11 14:10:30 UTC) #10
vasilii
I changed the CL description. https://codereview.chromium.org/440423003/diff/1/chrome/common/content_settings_pattern_parser.cc File chrome/common/content_settings_pattern_parser.cc (right): https://codereview.chromium.org/440423003/diff/1/chrome/common/content_settings_pattern_parser.cc#newcode13 chrome/common/content_settings_pattern_parser.cc:13: const char* kDomainWildcard = ...
6 years, 4 months ago (2014-08-11 16:37:47 UTC) #11
Bernhard Bauer
https://codereview.chromium.org/440423003/diff/20001/chrome/common/content_settings_pattern.h File chrome/common/content_settings_pattern.h (right): https://codereview.chromium.org/440423003/diff/20001/chrome/common/content_settings_pattern.h#newcode153 chrome/common/content_settings_pattern.h:153: const char* extension_scheme, On 2014/08/11 16:37:47, vasilii wrote: > ...
6 years, 4 months ago (2014-08-11 16:47:15 UTC) #12
vasilii
The layering violation will exist regardless of the solution we choose. If we don't want ...
6 years, 4 months ago (2014-08-12 09:29:08 UTC) #13
Bernhard Bauer
On 2014/08/12 09:29:08, vasilii wrote: > The layering violation will exist regardless of the solution ...
6 years, 4 months ago (2014-08-12 10:06:46 UTC) #14
blundell
Assuming that we're componentizing most/all of the code that this CL is touching in //chrome/browser/content_settings, ...
6 years, 4 months ago (2014-08-12 11:32:25 UTC) #15
jochen (gone - plz use gerrit)
we should probably (similar to what we do for e.g. GURL) add a static method ...
6 years, 4 months ago (2014-08-13 12:46:51 UTC) #16
vasilii
Bernhard and Vaclav, do you agree with the implemented solution suggested by Jochen?
6 years, 4 months ago (2014-08-18 12:29:49 UTC) #17
Bernhard Bauer
https://codereview.chromium.org/440423003/diff/120001/chrome/common/content_settings_pattern_parser_unittest.cc File chrome/common/content_settings_pattern_parser_unittest.cc (right): https://codereview.chromium.org/440423003/diff/120001/chrome/common/content_settings_pattern_parser_unittest.cc#newcode31 chrome/common/content_settings_pattern_parser_unittest.cc:31: InitContentSettingsComponent(); I would add this to ChromeTestSuite::Initialize() instead of ...
6 years, 4 months ago (2014-08-18 15:55:13 UTC) #18
vasilii
https://codereview.chromium.org/440423003/diff/120001/chrome/common/content_settings_pattern_parser_unittest.cc File chrome/common/content_settings_pattern_parser_unittest.cc (right): https://codereview.chromium.org/440423003/diff/120001/chrome/common/content_settings_pattern_parser_unittest.cc#newcode31 chrome/common/content_settings_pattern_parser_unittest.cc:31: InitContentSettingsComponent(); On 2014/08/18 15:55:13, Bernhard Bauer wrote: > I ...
6 years, 4 months ago (2014-08-20 08:44:06 UTC) #19
vabr (Chromium)
Thanks Vasilii, LGTM with comments. I'm glad you got rid of the client at this ...
6 years, 4 months ago (2014-08-20 09:52:23 UTC) #20
vasilii
Markus, we are curious can we handle file theme and extension theme in the same ...
6 years, 4 months ago (2014-08-21 14:58:02 UTC) #21
Bernhard Bauer
https://codereview.chromium.org/440423003/diff/120001/components/content_settings/core/common/embedder_variables.cc File components/content_settings/core/common/embedder_variables.cc (right): https://codereview.chromium.org/440423003/diff/120001/components/content_settings/core/common/embedder_variables.cc#newcode14 components/content_settings/core/common/embedder_variables.cc:14: extension_scheme = scheme; On 2014/08/20 08:44:06, vasilii wrote: > ...
6 years, 4 months ago (2014-08-21 15:05:54 UTC) #22
vabr (Chromium)
Thanks, Vasilii. Still LGTM. Cheers, Vaclav https://codereview.chromium.org/440423003/diff/160001/chrome/common/content_settings_pattern_parser.cc File chrome/common/content_settings_pattern_parser.cc (right): https://codereview.chromium.org/440423003/diff/160001/chrome/common/content_settings_pattern_parser.cc#newcode209 chrome/common/content_settings_pattern_parser.cc:209: if (content_settings::IsNonPortScheme(parts.scheme)) { ...
6 years, 4 months ago (2014-08-21 15:31:41 UTC) #23
markusheintz_
On 2014/08/21 15:31:41, vabr (Chromium) wrote: > Thanks, Vasilii. > Still LGTM. > Cheers, > ...
6 years, 4 months ago (2014-08-22 12:35:34 UTC) #24
vasilii
https://codereview.chromium.org/440423003/diff/120001/components/content_settings/core/common/embedder_variables.cc File components/content_settings/core/common/embedder_variables.cc (right): https://codereview.chromium.org/440423003/diff/120001/components/content_settings/core/common/embedder_variables.cc#newcode14 components/content_settings/core/common/embedder_variables.cc:14: extension_scheme = scheme; On 2014/08/21 15:05:54, Bernhard Bauer wrote: ...
6 years, 4 months ago (2014-08-22 13:02:46 UTC) #25
Bernhard Bauer
lgtm
6 years, 4 months ago (2014-08-22 13:10:11 UTC) #26
vasilii
jam@chromium.org: Please review changes in chrome/app/chrome_main_delegate.cc chrome/browser/notifications/desktop_notification_profile_util.h chrome/common/render_messages.cc chrome/test/base/chrome_test_suite.cc
6 years, 4 months ago (2014-08-22 13:16:58 UTC) #27
jam
On 2014/08/22 13:16:58, vasilii wrote: > mailto:jam@chromium.org: Please review changes in > > chrome/app/chrome_main_delegate.cc > ...
6 years, 4 months ago (2014-08-25 01:56:47 UTC) #28
vasilii
James, please review chrome/app/chrome_main_delegate.cc chrome/browser/notifications/desktop_notification_profile_util.h chrome/common/render_messages.cc chrome/test/base/chrome_test_suite.cc
6 years, 4 months ago (2014-08-25 09:39:33 UTC) #29
James Hawkins
I'm on vacation, so the earliest I can get to this is Wednesday.
6 years, 4 months ago (2014-08-25 17:51:24 UTC) #30
vasilii
Wednesday is fine. Colin, please review too.
6 years, 3 months ago (2014-08-26 08:06:36 UTC) #31
blundell
https://codereview.chromium.org/440423003/diff/200001/chrome/common/content_settings_component.h File chrome/common/content_settings_component.h (right): https://codereview.chromium.org/440423003/diff/200001/chrome/common/content_settings_component.h#newcode5 chrome/common/content_settings_component.h:5: #ifndef CHROME_COMMON_CONTENT_SETTINGS_COMPONENT_H_ I would call this content_settings_initializer.*. https://codereview.chromium.org/440423003/diff/200001/chrome/common/content_settings_pattern.cc File ...
6 years, 3 months ago (2014-08-26 09:16:58 UTC) #32
vasilii
https://codereview.chromium.org/440423003/diff/200001/chrome/common/content_settings_component.h File chrome/common/content_settings_component.h (right): https://codereview.chromium.org/440423003/diff/200001/chrome/common/content_settings_component.h#newcode5 chrome/common/content_settings_component.h:5: #ifndef CHROME_COMMON_CONTENT_SETTINGS_COMPONENT_H_ On 2014/08/26 09:16:57, blundell wrote: > I ...
6 years, 3 months ago (2014-08-26 12:18:19 UTC) #33
blundell
https://codereview.chromium.org/440423003/diff/200001/components/content_settings/core/common/embedder_variables.h File components/content_settings/core/common/embedder_variables.h (right): https://codereview.chromium.org/440423003/diff/200001/components/content_settings/core/common/embedder_variables.h#newcode21 components/content_settings/core/common/embedder_variables.h:21: bool IsNonWildcardDomainNonPortScheme(const std::string& scheme); On 2014/08/26 12:18:18, vasilii wrote: ...
6 years, 3 months ago (2014-08-26 12:21:38 UTC) #34
Bernhard Bauer
https://codereview.chromium.org/440423003/diff/200001/components/content_settings/core/common/embedder_variables.h File components/content_settings/core/common/embedder_variables.h (right): https://codereview.chromium.org/440423003/diff/200001/components/content_settings/core/common/embedder_variables.h#newcode16 components/content_settings/core/common/embedder_variables.h:16: // |scheme| can't be NULL, and the pointed string ...
6 years, 3 months ago (2014-08-26 12:32:08 UTC) #35
vasilii
On 2014/08/26 12:21:38, blundell wrote: > https://codereview.chromium.org/440423003/diff/200001/components/content_settings/core/common/embedder_variables.h > File components/content_settings/core/common/embedder_variables.h (right): > > https://codereview.chromium.org/440423003/diff/200001/components/content_settings/core/common/embedder_variables.h#newcode21 > ...
6 years, 3 months ago (2014-08-26 12:43:19 UTC) #36
blundell
On 2014/08/26 12:43:19, vasilii wrote: > On 2014/08/26 12:21:38, blundell wrote: > > > https://codereview.chromium.org/440423003/diff/200001/components/content_settings/core/common/embedder_variables.h ...
6 years, 3 months ago (2014-08-26 13:24:48 UTC) #37
vasilii
https://codereview.chromium.org/440423003/diff/200001/components/content_settings/core/common/embedder_variables.h File components/content_settings/core/common/embedder_variables.h (right): https://codereview.chromium.org/440423003/diff/200001/components/content_settings/core/common/embedder_variables.h#newcode21 components/content_settings/core/common/embedder_variables.h:21: bool IsNonWildcardDomainNonPortScheme(const std::string& scheme); On 2014/08/26 12:21:38, blundell wrote: ...
6 years, 3 months ago (2014-08-27 11:39:32 UTC) #38
blundell
lgtm, thanks! https://codereview.chromium.org/440423003/diff/240001/chrome/common/content_settings_pattern.h File chrome/common/content_settings_pattern.h (right): https://codereview.chromium.org/440423003/diff/240001/chrome/common/content_settings_pattern.h#newcode182 chrome/common/content_settings_pattern.h:182: // Chrome terminates. s/Chrome/app https://codereview.chromium.org/440423003/diff/240001/chrome/common/content_settings_pattern.h#newcode183 chrome/common/content_settings_pattern.h:183: static ...
6 years, 3 months ago (2014-08-27 12:32:19 UTC) #39
vasilii
https://codereview.chromium.org/440423003/diff/240001/chrome/common/content_settings_pattern.h File chrome/common/content_settings_pattern.h (right): https://codereview.chromium.org/440423003/diff/240001/chrome/common/content_settings_pattern.h#newcode182 chrome/common/content_settings_pattern.h:182: // Chrome terminates. On 2014/08/27 12:32:19, blundell wrote: > ...
6 years, 3 months ago (2014-08-27 12:54:33 UTC) #40
vasilii
James?
6 years, 3 months ago (2014-08-29 09:19:04 UTC) #41
vasilii
James, do you have time to review? chrome/app/chrome_main_delegate.cc chrome/browser/notifications/desktop_notification_profile_util.h chrome/common/render_messages.cc chrome/test/base/chrome_test_suite.cc
6 years, 3 months ago (2014-09-01 08:34:17 UTC) #42
Bernhard Bauer
On 2014/09/01 08:34:17, vasilii wrote: > James, do you have time to review? (Today is ...
6 years, 3 months ago (2014-09-01 08:41:26 UTC) #43
jochen (gone - plz use gerrit)
https://codereview.chromium.org/440423003/diff/260001/chrome/browser/notifications/desktop_notification_profile_util.h File chrome/browser/notifications/desktop_notification_profile_util.h (right): https://codereview.chromium.org/440423003/diff/260001/chrome/browser/notifications/desktop_notification_profile_util.h#newcode8 chrome/browser/notifications/desktop_notification_profile_util.h:8: #include "base/macros.h" why do you include base/macros.h everywhere? this ...
6 years, 3 months ago (2014-09-02 08:15:50 UTC) #45
vasilii
https://codereview.chromium.org/440423003/diff/260001/chrome/browser/notifications/desktop_notification_profile_util.h File chrome/browser/notifications/desktop_notification_profile_util.h (right): https://codereview.chromium.org/440423003/diff/260001/chrome/browser/notifications/desktop_notification_profile_util.h#newcode8 chrome/browser/notifications/desktop_notification_profile_util.h:8: #include "base/macros.h" On 2014/09/02 08:15:50, jochen wrote: > why ...
6 years, 3 months ago (2014-09-02 08:50:37 UTC) #46
blundell
On 2014/09/02 08:50:37, vasilii wrote: > https://codereview.chromium.org/440423003/diff/260001/chrome/browser/notifications/desktop_notification_profile_util.h > File chrome/browser/notifications/desktop_notification_profile_util.h (right): > > https://codereview.chromium.org/440423003/diff/260001/chrome/browser/notifications/desktop_notification_profile_util.h#newcode8 > ...
6 years, 3 months ago (2014-09-02 08:53:18 UTC) #47
jochen (gone - plz use gerrit)
On 2014/09/02 at 08:53:18, blundell wrote: > On 2014/09/02 08:50:37, vasilii wrote: > > https://codereview.chromium.org/440423003/diff/260001/chrome/browser/notifications/desktop_notification_profile_util.h ...
6 years, 3 months ago (2014-09-02 08:54:53 UTC) #48
vasilii
On 2014/09/02 08:54:53, jochen wrote: > On 2014/09/02 at 08:53:18, blundell wrote: > > On ...
6 years, 3 months ago (2014-09-02 09:10:26 UTC) #49
jochen (gone - plz use gerrit)
lgtm
6 years, 3 months ago (2014-09-02 09:17:11 UTC) #50
vasilii
Hooray!
6 years, 3 months ago (2014-09-02 09:18:10 UTC) #51
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/vasilii@chromium.org/440423003/300001
6 years, 3 months ago (2014-09-02 09:18:37 UTC) #53
commit-bot: I haz the power
Committed patchset #16 (id:300001) as 77e83962ccd5d993c4f6c025af45b2562dc396b6
6 years, 3 months ago (2014-09-02 10:05:11 UTC) #54
commit-bot: I haz the power
6 years, 3 months ago (2014-09-10 03:17:55 UTC) #55
Message was sent while issue was closed.
Patchset 16 (id:??) landed as
https://crrev.com/94a1f29d656ac654ac0248e00f2d47fe2da7d446
Cr-Commit-Position: refs/heads/master@{#292906}

Powered by Google App Engine
This is Rietveld 408576698