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

Issue 8302016: Make GTK and Aura parts orthogonal to OS parts (Closed)

Created:
9 years, 2 months ago by stevenjb
Modified:
9 years, 1 month ago
CC:
chromium-reviews, stevenjb, nkostylev+watch_chromium.org, jam, dpranke-watch+content_chromium.org, joi+watch-content_chromium.org, darin-cc_chromium.org, davemoore+watch_chromium.org, tfarina, willchan no longer on Chromium, sky
Visibility:
Public.

Description

Make GTK and Aura parts orthogonal to OS parts This CL moves GTK and Aura "Parts" out of the primary BrowserMainParts tree and into orthogonal parts that can be added independently. This was done in a way that will facilitate adding additional parts if (when) we need them. The motivation for this was to a) eliminate the existing typedef in chrome_browser_main_chromeos.h b) reduce the number of #ifdefs required in the setup / parts code For an outline of the new parts see: https://docs.google.com/drawings/d/1-gIMl-81c4SvcMrT1xaxnDGibDe7VQfMkFT1bMnIvrg/edit?hl=en_US Please consider this a proposal; I am entirely open to feedback. BUG=none TEST=Chrome compiles and passes tests on all platfroms. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=107383

Patch Set 1 #

Patch Set 2 : Fix comments and remove incrrectly changed files #

Patch Set 3 : Rebase #

Total comments: 1

Patch Set 4 : Extract BrowserParts from BrowserMainParts #

Patch Set 5 : . #

Total comments: 4

Patch Set 6 : Rebase #

Patch Set 7 : Fix nits #

Patch Set 8 : Rename aura and gtk main -> parts #

Patch Set 9 : . #

Patch Set 10 : Fix compile errors #

Total comments: 4

Patch Set 11 : Refactor BrowserMainParts and elim BrowserParts #

Patch Set 12 : Fix compiler errors #

Patch Set 13 : . #

Patch Set 14 : . #

Total comments: 40

Patch Set 15 : Moved BrowserMainLoop into its own file, changed PreMainMessageLoopStart to return void #

Total comments: 15

Patch Set 16 : Feedback + fix compile errors #

Total comments: 1

Patch Set 17 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+697 lines, -985 lines) Patch
M chrome/app/breakpad_win.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/chrome_browser_main.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 5 chunks +30 lines, -11 lines 0 comments Download
M chrome/browser/chrome_browser_main.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 16 chunks +41 lines, -30 lines 0 comments Download
M chrome/browser/chrome_browser_main_aura.h View 1 2 3 4 5 6 7 1 chunk +0 lines, -21 lines 0 comments Download
M chrome/browser/chrome_browser_main_aura.cc View 1 2 3 4 5 6 7 1 chunk +0 lines, -25 lines 0 comments Download
M chrome/browser/chrome_browser_main_gtk.h View 1 2 3 4 5 6 7 1 chunk +0 lines, -25 lines 0 comments Download
M chrome/browser/chrome_browser_main_gtk.cc View 1 2 3 4 5 6 7 1 chunk +0 lines, -83 lines 0 comments Download
A chrome/browser/chrome_browser_main_linux.h View 1 2 3 4 5 6 7 8 9 10 1 chunk +22 lines, -0 lines 0 comments Download
A chrome/browser/chrome_browser_main_linux.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +29 lines, -0 lines 0 comments Download
M chrome/browser/chrome_browser_main_mac.h View 1 2 3 4 5 6 7 8 9 10 1 chunk +4 lines, -0 lines 0 comments Download
M chrome/browser/chrome_browser_main_mac.mm View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 2 chunks +5 lines, -15 lines 0 comments Download
M chrome/browser/chrome_browser_main_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 3 chunks +41 lines, -28 lines 0 comments Download
M chrome/browser/chrome_browser_main_win.h View 1 2 3 4 5 6 7 8 9 10 1 chunk +28 lines, -22 lines 0 comments Download
M chrome/browser/chrome_browser_main_win.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 6 chunks +31 lines, -38 lines 0 comments Download
M chrome/browser/chrome_browser_main_x11.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +0 lines, -11 lines 0 comments Download
A chrome/browser/chrome_browser_parts_aura.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +31 lines, -0 lines 0 comments Download
A chrome/browser/chrome_browser_parts_aura.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +28 lines, -0 lines 0 comments Download
A chrome/browser/chrome_browser_parts_gtk.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +33 lines, -0 lines 0 comments Download
A + chrome/browser/chrome_browser_parts_gtk.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 3 chunks +13 lines, -13 lines 0 comments Download
M chrome/browser/chrome_content_browser_client.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +3 lines, -2 lines 0 comments Download
M chrome/browser/chrome_content_browser_client.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 4 chunks +39 lines, -20 lines 0 comments Download
M chrome/browser/chromeos/chrome_browser_main_chromeos.h View 1 2 3 4 5 12 13 14 15 2 chunks +3 lines, -10 lines 0 comments Download
M chrome/browser/chromeos/chrome_browser_main_chromeos.cc View 1 2 3 4 5 12 13 14 15 4 chunks +4 lines, -4 lines 0 comments Download
M chrome/chrome_browser.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 2 chunks +6 lines, -4 lines 0 comments Download
M content/browser/browser_context.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -1 line 0 comments Download
M content/browser/browser_main.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +0 lines, -112 lines 0 comments Download
M content/browser/browser_main.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 4 chunks +13 lines, -328 lines 0 comments Download
A content/browser/browser_main_loop.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +75 lines, -0 lines 0 comments Download
A + content/browser/browser_main_loop.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 11 chunks +88 lines, -161 lines 0 comments Download
M content/browser/mock_content_browser_client.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +3 lines, -2 lines 0 comments Download
M content/browser/mock_content_browser_client.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +3 lines, -3 lines 0 comments Download
M content/content_browser.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 2 chunks +3 lines, -0 lines 0 comments Download
A content/public/browser/browser_main_parts.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +87 lines, -0 lines 0 comments Download
M content/public/browser/content_browser_client.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 2 chunks +6 lines, -6 lines 0 comments Download
M content/shell/shell_browser_main.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 2 chunks +11 lines, -2 lines 0 comments Download
M content/shell/shell_browser_main.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 2 chunks +6 lines, -1 line 0 comments Download
M content/shell/shell_content_browser_client.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 2 chunks +4 lines, -3 lines 0 comments Download
M content/shell/shell_content_browser_client.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +4 lines, -3 lines 0 comments Download

Messages

Total messages: 19 (0 generated)
stevenjb
First draft of the Parts cleanup. Some additional cleanup (migrating some global functions to pure ...
9 years, 2 months ago (2011-10-15 01:31:09 UTC) #1
tfarina
http://codereview.chromium.org/8302016/diff/2001/chrome/browser/chromeos/chrome_browser_main_chromeos.h File chrome/browser/chromeos/chrome_browser_main_chromeos.h (right): http://codereview.chromium.org/8302016/diff/2001/chrome/browser/chromeos/chrome_browser_main_chromeos.h#newcode25 chrome/browser/chromeos/chrome_browser_main_chromeos.h:25: DISALLOW_COPY_AND_ASSIGN(ChromeBrowserMainPartsChromeos); Can we move this to the end of ...
9 years, 2 months ago (2011-10-15 22:17:29 UTC) #2
DaveMoore
vtl should review. Also, is there some way to unify the OS parts and the ...
9 years, 2 months ago (2011-10-17 17:44:21 UTC) #3
stevenjb
OK, I think this is better. I'd look at browser_main.h/cc first, then chrome_content_browser_client.cc. Everything else ...
9 years, 2 months ago (2011-10-17 23:53:08 UTC) #4
DaveMoore
http://codereview.chromium.org/8302016/diff/10001/chrome/browser/chrome_browser_main.h File chrome/browser/chrome_browser_main.h (right): http://codereview.chromium.org/8302016/diff/10001/chrome/browser/chrome_browser_main.h#newcode54 chrome/browser/chrome_browser_main.h:54: // New virtual methods Nit: this comment probably doesn't ...
9 years, 2 months ago (2011-10-19 21:31:18 UTC) #5
stevenjb
Broadening the review list for this CL. Please take a look if you can.
9 years, 2 months ago (2011-10-20 00:35:50 UTC) #6
Emmanuel Saint-loubert-Bié
Looks great, and less #ifdef too!! Thanks Steven.
9 years, 2 months ago (2011-10-20 00:44:21 UTC) #7
sky
Trung is a better reviewer than I am for this. -Scott
9 years, 2 months ago (2011-10-20 16:36:23 UTC) #8
jam
http://codereview.chromium.org/8302016/diff/18025/chrome/browser/chrome_browser_main.h File chrome/browser/chrome_browser_main.h (right): http://codereview.chromium.org/8302016/diff/18025/chrome/browser/chrome_browser_main.h#newcode62 chrome/browser/chrome_browser_main.h:62: virtual void PrepareRestartOnCrashEnviroment() = 0; the last three methods ...
9 years, 2 months ago (2011-10-20 18:01:18 UTC) #9
stevenjb
PTAL This re-factoring should be much improved after input from John. I would start with ...
9 years, 2 months ago (2011-10-21 22:25:49 UTC) #10
stevenjb
Ping. If we're happy with this direction I'd like to get it in sooner than ...
9 years, 2 months ago (2011-10-24 19:26:00 UTC) #11
Emmanuel Saint-loubert-Bié
Hi Steven I am very happy with this direction and CL and hope that we ...
9 years, 2 months ago (2011-10-24 19:27:41 UTC) #12
jam
(didn't review all the chrome platform specific implementations yet, figured I'd send this first) in ...
9 years, 2 months ago (2011-10-24 19:36:00 UTC) #13
stevenjb
PTAL http://codereview.chromium.org/8302016/diff/26036/chrome/browser/chrome_browser_main.cc File chrome/browser/chrome_browser_main.cc (right): http://codereview.chromium.org/8302016/diff/26036/chrome/browser/chrome_browser_main.cc#newcode688 chrome/browser/chrome_browser_main.cc:688: : content::BrowserMainParts(), On 2011/10/24 19:36:00, John Abd-El-Malek wrote: ...
9 years, 2 months ago (2011-10-25 02:51:03 UTC) #14
jam
http://codereview.chromium.org/8302016/diff/34001/chrome/browser/chrome_content_browser_client.h File chrome/browser/chrome_content_browser_client.h (right): http://codereview.chromium.org/8302016/diff/34001/chrome/browser/chrome_content_browser_client.h#newcode15 chrome/browser/chrome_content_browser_client.h:15: class BrowserMainParts; nit: not needed, since this is already ...
9 years, 2 months ago (2011-10-25 06:11:28 UTC) #15
stevenjb
http://codereview.chromium.org/8302016/diff/34001/content/browser/browser_main_loop.h File content/browser/browser_main_loop.h (right): http://codereview.chromium.org/8302016/diff/34001/content/browser/browser_main_loop.h#newcode22 content/browser/browser_main_loop.h:22: class BrowserMainLoop { On 2011/10/25 06:11:28, John Abd-El-Malek wrote: ...
9 years, 1 month ago (2011-10-25 16:24:34 UTC) #16
jam
http://codereview.chromium.org/8302016/diff/34001/content/browser/browser_main_loop.h File content/browser/browser_main_loop.h (right): http://codereview.chromium.org/8302016/diff/34001/content/browser/browser_main_loop.h#newcode22 content/browser/browser_main_loop.h:22: class BrowserMainLoop { On 2011/10/25 16:24:34, Steven Bennetts wrote: ...
9 years, 1 month ago (2011-10-25 16:33:58 UTC) #17
stevenjb
http://codereview.chromium.org/8302016/diff/34001/chrome/browser/chrome_content_browser_client.h File chrome/browser/chrome_content_browser_client.h (right): http://codereview.chromium.org/8302016/diff/34001/chrome/browser/chrome_content_browser_client.h#newcode15 chrome/browser/chrome_content_browser_client.h:15: class BrowserMainParts; On 2011/10/25 06:11:28, John Abd-El-Malek wrote: > ...
9 years, 1 month ago (2011-10-25 19:21:17 UTC) #18
jam
9 years, 1 month ago (2011-10-25 19:43:32 UTC) #19
lgtm

http://codereview.chromium.org/8302016/diff/34001/content/public/browser/cont...
File content/public/browser/content_browser_client.h (right):

http://codereview.chromium.org/8302016/diff/34001/content/public/browser/cont...
content/public/browser/content_browser_client.h:91:
std::vector<BrowserMainParts*>& parts_list) = 0;
On 2011/10/25 19:21:18, Steven Bennetts wrote:
> On 2011/10/25 06:11:28, John Abd-El-Malek wrote:
> > I didn't notice last time that you're passing a non-const reference (against
> > style guide). please make this a pointer to the vector.
> > 
> > nit: parts instead of parts_list
> 
> Done. Also, it's parts_list everywhere except the member variable in
> BrowserMainLoop, so I changed that.

nit: parts_list isn't that accurate since it's not a list container anymore.. i
think parts is just as descriptive since anyone looking at it can see that it's
a container, but up to you.

http://codereview.chromium.org/8302016/diff/40002/content/browser/browser_mai...
File content/browser/browser_main_loop.h (right):

http://codereview.chromium.org/8302016/diff/40002/content/browser/browser_mai...
content/browser/browser_main_loop.h:42: // BrowserMainLoop implementation
nit: remove

Powered by Google App Engine
This is Rietveld 408576698