In the cobalt browser, when I press the F1 key, the browser automatically pop up a DevTools window. There are the following information in this window: Cobalt.Lifetime, DevTools.Server, Event.Duration.MainWebModule.keyDown etc. We want to disable this F1 key behaviour. Can anyone tell us how to change the cobalt source code to disable this F1 key behaviour?
Asked
Active
Viewed 66 times
1 Answers
2
The debug console will automatically be disabled when you do a production build of Cobalt (i.e. "gold"), however it is enabled for debug, devel and QA builds.
However, if you really want to completely disable it, even in development builds, you can find the code for handling "F1" key presses here: https://cobalt.googlesource.com/cobalt/+/master/src/cobalt/browser/browser_module.cc#1109

Andrew Top
- 2,517
- 1
- 17
- 10
-
Like Andrew mentioned, please avoid making changes to the Cobalt code unless it's really necessary. In this case, F1 key would not affect users anyways. – Daniel Juyung Seo Mar 28 '18 at 17:04