mandoline: Allow running the aura/views UI on android.
[chromium-blink-merge.git] / chrome / app / chrome_watcher_command_line_win.h
blob4b4596a7bb954416a8bf2d84070a6afb671c3ee7
1 // Copyright (c) 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_APP_CHROME_WATCHER_COMMAND_LINE_WIN_H_
6 #define CHROME_APP_CHROME_WATCHER_COMMAND_LINE_WIN_H_
8 #include <windows.h>
10 #include "base/win/scoped_handle.h"
12 namespace base {
13 class CommandLine;
14 class FilePath;
15 } // namespace base
17 // Generates a CommandLine that will launch |chrome_exe| in Chrome Watcher mode
18 // to observe |parent_process|. The watcher process will signal
19 // |on_initialized_event| when its initialization is complete.
20 base::CommandLine GenerateChromeWatcherCommandLine(
21 const base::FilePath& chrome_exe,
22 HANDLE parent_process,
23 HANDLE on_initialized_event);
25 // Interprets the Command Line used to launch a Chrome Watcher process and
26 // extracts the parent process and initialization event HANDLEs. Verifies that
27 // the handles are usable in this process before returning them. Returns true if
28 // both handles are successfully parsed and false otherwise. If only one of the
29 // handles can be parsed, it will be closed.
30 bool InterpretChromeWatcherCommandLine(
31 const base::CommandLine& command_line,
32 base::win::ScopedHandle* parent_process,
33 base::win::ScopedHandle* on_initialized_event);
35 #endif // CHROME_APP_CHROME_WATCHER_COMMAND_LINE_WIN_H_