commit | 5e7c79b25f3c3b69bb90a2e9c45540eed25439d9 | [log] [tgz] |
---|---|---|
author | Reilly Grant <[email protected]> | Tue Apr 09 17:26:20 2019 |
committer | Commit Bot <[email protected]> | Tue Apr 09 17:26:20 2019 |
tree | e3a6e5657b2b22b6721b4b076bf6200dfb5a56f8 | |
parent | b4133a5d0bc7502098a21a73fea4d248ea39cdc5 [diff] [blame] |
Reland "[serial] Implement tab indicator triggered by open()" This is a reland of 0ca38034e8e6daca423130b7643dae169a60692b The tests were flaking because the tab indicator is only removed after the browser process receives the Mojo connection error. To fix this the tests are now unit tests where we can make sure to run the necessary message loop to make sure that this event has been delivered before checking. Original change's description: > [serial] Implement tab indicator triggered by open() > > As long as there is an active connection between a frame in a tab and a > serial port the tab should display an indicator. > > This is accomplished by adding an additional Mojo pipe that is kept open > between the device service and the browser processes for as long as the > render process has a connection to the port. > > Bug: 917204 > Change-Id: I6441070f3473bd6b4a98dae98844a89ee4eb2329 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1546502 > Reviewed-by: Scott Violet <[email protected]> > Reviewed-by: Dominick Ng <[email protected]> > Reviewed-by: Yuri Wiitala <[email protected]> > Commit-Queue: Reilly Grant <[email protected]> > Cr-Commit-Position: refs/heads/master@{#647109} Bug: 917204 Change-Id: I26fbb51845ae6b7ce2fe54bad2cc0a271ce0cbd0 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1555508 Reviewed-by: Dominick Ng <[email protected]> Reviewed-by: Scott Violet <[email protected]> Commit-Queue: Reilly Grant <[email protected]> Cr-Commit-Position: refs/heads/master@{#649154}
diff --git a/content/public/browser/web_contents.h b/content/public/browser/web_contents.h index b33d118..6cf2ca2 100644 --- a/content/public/browser/web_contents.h +++ b/content/public/browser/web_contents.h
@@ -474,6 +474,10 @@ // Device. virtual bool IsConnectedToBluetoothDevice() = 0; + // Indicates whether any frame in the WebContents is connected to a serial + // port. + virtual bool IsConnectedToSerialPort() const = 0; + // Indicates whether a video is in Picture-in-Picture for |this|. virtual bool HasPictureInPictureVideo() = 0;