Commit 0d70de0c authored by Matt Falkenhagen's avatar Matt Falkenhagen Committed by Commit Bot

Clarify BrowserMainParts documentation about platform-specific code.

List specific examples for clarity. In particular, I couldn't find
"platform-specific |Pre/Post...()| methods" and think it's referring
to embedder-provided methods.

Change-Id: I92a33523609076d54d00ee397f2523be068f23a8
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1786887Reviewed-by: default avatarKinuko Yasuda <kinuko@chromium.org>
Commit-Queue: Matt Falkenhagen <falken@chromium.org>
Cr-Commit-Position: refs/heads/master@{#693666}
parent baea927d
......@@ -37,9 +37,11 @@ namespace content {
// running your code at a particular time? Document these things!
// - Split out any platform-specific bits. Please avoid #ifdefs it at all
// possible. You have two choices for platform-specific code: (1) Execute it
// from one of the platform-specific |Pre/Post...()| methods; do this if the
// code is unique to a platform type. Or (2) execute it from one of the
// "parts" (e.g., |EarlyInitialization()|) and provide platform-specific
// from one of the |Pre/Post...()| methods in a embedder's platform-specific
// override (e.g., ChromeBrowserMainPartsWin::PreMainMessageLoopStart()); do
// this if the code is unique to an embedder and platform type. Or (2)
// execute it from one of the "stages" (e.g.,
// |BrowserMainLoop::EarlyInitialization()|) and provide platform-specific
// implementations of your code (in a virtual method); do this if you need to
// provide different implementations across most/all platforms.
// - Unless your new code is just one or two lines, put it into a separate
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment