use webPreferences to disable devtools

This commit is contained in:
minggo 2016-09-05 18:25:57 +08:00
parent 0d7e7be748
commit 1f1180f857
3 changed files with 0 additions and 8 deletions

View file

@ -83,10 +83,6 @@ Window::Window(v8::Isolate* isolate, v8::Local<v8::Object> wrapper,
v8::Local<v8::Value> transparent;
if (options.Get("transparent", &transparent))
web_preferences.Set("transparent", transparent);
// Disable WebContents.OpenDevTools() ?
if (options.Get(options::kDisableDevTools, &value))
web_preferences.Set(options::kDisableDevTools, value);
// Creates the WebContents used by BrowserWindow.
auto web_contents = WebContents::Create(isolate, web_preferences);