Commit ac0aeaba authored by Joel Hockey's avatar Joel Hockey Committed by Commit Bot

Show terminal progress when starting the container

TerminalPrivateApi registers as a CrostiniRestarterObserver
and prints out information about each stage of startup.

Terminals currently rely on having a unique ID which
is passed from chrome to the JS code in the callback to
openTerminalProcess.  This ID allows terminals to know
which instance the onProcessOutput is meant for.

Since this ID is not set for the startup text,
terminal JS code will generate a random ID and pass it
as a startup_id param in openTerminalProcess.  This
will be used to send startup text, but this switch
is not passed on to vsh process creation.

Bug: 1016680
Change-Id: Ibd0417f18f05f505b68f8f3f23ad23cb584dac0b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1876292
Auto-Submit: Joel Hockey <joelhockey@chromium.org>
Reviewed-by: default avatarBen Wells <benwells@chromium.org>
Reviewed-by: default avatarJulian Watson <juwa@google.com>
Commit-Queue: Joel Hockey <joelhockey@chromium.org>
Cr-Commit-Position: refs/heads/master@{#708979}
parent 4bb83aad
......@@ -33,8 +33,9 @@ class TerminalPrivateOpenTerminalProcessFunction : public ExtensionFunction {
using OpenProcessCallback =
base::Callback<void(bool success, const std::string& terminal_id)>;
std::string UserIdHash();
void OpenProcess(const std::vector<std::string> arguments);
void OpenProcess(const std::string& user_id_hash,
int tab_id,
const std::vector<std::string>& arguments);
void OpenOnRegistryTaskRunner(const ProcessOutputCallback& output_callback,
const OpenProcessCallback& callback,
const std::vector<std::string>& arguments,
......
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