From 24bbe5dabf36b3a7a3937821d91db6caa9ebad60 Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Mon, 7 Sep 2015 15:55:08 +0800 Subject: [PATCH 1/3] No need to define WebContentsPreferences::From --- atom/browser/api/atom_api_web_view_manager.cc | 4 +++- atom/browser/web_contents_preferences.cc | 18 +++++------------- atom/browser/web_contents_preferences.h | 3 --- 3 files changed, 8 insertions(+), 17 deletions(-) diff --git a/atom/browser/api/atom_api_web_view_manager.cc b/atom/browser/api/atom_api_web_view_manager.cc index 83287ac8b2f1..e57c5ffb6bb4 100644 --- a/atom/browser/api/atom_api_web_view_manager.cc +++ b/atom/browser/api/atom_api_web_view_manager.cc @@ -10,6 +10,8 @@ #include "content/public/browser/browser_context.h" #include "native_mate/dictionary.h" +using atom::WebContentsPreferences; + namespace mate { template<> @@ -48,7 +50,7 @@ void AddGuest(int guest_instance_id, manager->AddGuest(guest_instance_id, element_instance_id, embedder, guest_web_contents); - atom::WebContentsPreferences::From(guest_web_contents)->Merge(options); + WebContentsPreferences::FromWebContents(guest_web_contents)->Merge(options); } void RemoveGuest(content::WebContents* embedder, int guest_instance_id) { diff --git a/atom/browser/web_contents_preferences.cc b/atom/browser/web_contents_preferences.cc index 19ea826a5ff7..db55eddf7e2d 100644 --- a/atom/browser/web_contents_preferences.cc +++ b/atom/browser/web_contents_preferences.cc @@ -16,13 +16,12 @@ #include "ui/gfx/switches.h" #endif +DEFINE_WEB_CONTENTS_USER_DATA_KEY(atom::WebContentsPreferences); + namespace atom { namespace { -// Pointer as WebContents's user data key. -const char* kWebPreferencesKey = "WebContentsPreferences"; - // Array of available web runtime features. const char* kWebRuntimeFeatures[] = { switches::kExperimentalFeatures, @@ -40,7 +39,7 @@ WebContentsPreferences::WebContentsPreferences( content::WebContents* web_contents, base::DictionaryValue* web_preferences) { web_preferences_.Swap(web_preferences); - web_contents->SetUserData(kWebPreferencesKey, this); + web_contents->SetUserData(UserDataKey(), this); } WebContentsPreferences::~WebContentsPreferences() { @@ -50,17 +49,10 @@ void WebContentsPreferences::Merge(const base::DictionaryValue& extend) { web_preferences_.MergeDictionary(&extend); } -// static -WebContentsPreferences* WebContentsPreferences::From( - content::WebContents* web_contents) { - return static_cast( - web_contents->GetUserData(kWebPreferencesKey)); -} - // static void WebContentsPreferences::AppendExtraCommandLineSwitches( content::WebContents* web_contents, base::CommandLine* command_line) { - WebContentsPreferences* self = From(web_contents); + WebContentsPreferences* self = FromWebContents(web_contents); if (!self) return; @@ -130,7 +122,7 @@ void WebContentsPreferences::AppendExtraCommandLineSwitches( // static void WebContentsPreferences::OverrideWebkitPrefs( content::WebContents* web_contents, content::WebPreferences* prefs) { - WebContentsPreferences* self = From(web_contents); + WebContentsPreferences* self = FromWebContents(web_contents); if (!self) return; diff --git a/atom/browser/web_contents_preferences.h b/atom/browser/web_contents_preferences.h index 310456725aaf..83b485f449bc 100644 --- a/atom/browser/web_contents_preferences.h +++ b/atom/browser/web_contents_preferences.h @@ -22,9 +22,6 @@ namespace atom { class WebContentsPreferences : public content::WebContentsUserData { public: - // Get the preferences of |web_contents|. - static WebContentsPreferences* From(content::WebContents* web_contents); - // Append command paramters according to |web_contents|'s preferences. static void AppendExtraCommandLineSwitches( content::WebContents* web_contents, base::CommandLine* command_line); From 46b2b91a27846ee619997c60d8d313d829b48314 Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Mon, 7 Sep 2015 16:12:31 +0800 Subject: [PATCH 2/3] Don't use Node's internal APIs --- atom/browser/api/atom_api_power_monitor.cc | 7 +++---- atom/browser/api/atom_api_screen.cc | 8 +++++--- atom/browser/api/atom_api_tray.cc | 3 ++- atom/browser/api/atom_api_web_contents.cc | 10 ++++++---- atom/browser/api/atom_api_web_contents.h | 4 ++-- atom/browser/api/atom_api_window.cc | 4 ++-- atom/renderer/api/atom_api_renderer_ipc.cc | 8 ++++---- vendor/node | 2 +- 8 files changed, 25 insertions(+), 21 deletions(-) diff --git a/atom/browser/api/atom_api_power_monitor.cc b/atom/browser/api/atom_api_power_monitor.cc index 093df2a1d4ef..31b35e10cea8 100644 --- a/atom/browser/api/atom_api_power_monitor.cc +++ b/atom/browser/api/atom_api_power_monitor.cc @@ -5,12 +5,11 @@ #include "atom/browser/api/atom_api_power_monitor.h" #include "atom/browser/browser.h" +#include "atom/common/node_includes.h" #include "base/power_monitor/power_monitor.h" #include "base/power_monitor/power_monitor_device_source.h" #include "native_mate/dictionary.h" -#include "atom/common/node_includes.h" - namespace atom { namespace api { @@ -41,9 +40,9 @@ void PowerMonitor::OnResume() { // static v8::Local PowerMonitor::Create(v8::Isolate* isolate) { if (!Browser::Get()->is_ready()) { - node::ThrowError( + isolate->ThrowException(v8::Exception::Error(mate::StringToV8( isolate, - "Cannot initialize \"power-monitor\" module before app is ready"); + "Cannot initialize \"power-monitor\" module before app is ready"))); return v8::Null(isolate); } diff --git a/atom/browser/api/atom_api_screen.cc b/atom/browser/api/atom_api_screen.cc index 9f81cf6eeff7..b73bda9ced84 100644 --- a/atom/browser/api/atom_api_screen.cc +++ b/atom/browser/api/atom_api_screen.cc @@ -113,14 +113,16 @@ mate::ObjectTemplateBuilder Screen::GetObjectTemplateBuilder( // static v8::Local Screen::Create(v8::Isolate* isolate) { if (!Browser::Get()->is_ready()) { - node::ThrowError(isolate, - "Cannot initialize \"screen\" module before app is ready"); + isolate->ThrowException(v8::Exception::Error(mate::StringToV8( + isolate, + "Cannot initialize \"screen\" module before app is ready"))); return v8::Null(isolate); } gfx::Screen* screen = gfx::Screen::GetNativeScreen(); if (!screen) { - node::ThrowError(isolate, "Failed to get screen information"); + isolate->ThrowException(v8::Exception::Error(mate::StringToV8( + isolate, "Failed to get screen information"))); return v8::Null(isolate); } diff --git a/atom/browser/api/atom_api_tray.cc b/atom/browser/api/atom_api_tray.cc index 1382f015a63b..90bcbcf3e2a7 100644 --- a/atom/browser/api/atom_api_tray.cc +++ b/atom/browser/api/atom_api_tray.cc @@ -35,7 +35,8 @@ Tray::~Tray() { // static mate::Wrappable* Tray::New(v8::Isolate* isolate, const gfx::Image& image) { if (!Browser::Get()->is_ready()) { - node::ThrowError(isolate, "Cannot create Tray before app is ready"); + isolate->ThrowException(v8::Exception::Error(mate::StringToV8( + isolate, "Cannot create Tray before app is ready"))); return nullptr; } return new Tray(image); diff --git a/atom/browser/api/atom_api_web_contents.cc b/atom/browser/api/atom_api_web_contents.cc index d22f7aab61fd..9cb52a1ec74d 100644 --- a/atom/browser/api/atom_api_web_contents.cc +++ b/atom/browser/api/atom_api_web_contents.cc @@ -717,17 +717,19 @@ void WebContents::PrintToPDF(const base::DictionaryValue& setting, PrintToPDF(setting, callback); } -void WebContents::AddWorkSpace(const base::FilePath& path) { +void WebContents::AddWorkSpace(mate::Arguments* args, + const base::FilePath& path) { if (path.empty()) { - node::ThrowError(isolate(), "path cannot be empty"); + args->ThrowError("path cannot be empty"); return; } DevToolsAddFileSystem(path); } -void WebContents::RemoveWorkSpace(const base::FilePath& path) { +void WebContents::RemoveWorkSpace(mate::Arguments* args, + const base::FilePath& path) { if (path.empty()) { - node::ThrowError(isolate(), "path cannot be empty"); + args->ThrowError("path cannot be empty"); return; } DevToolsRemoveFileSystem(path); diff --git a/atom/browser/api/atom_api_web_contents.h b/atom/browser/api/atom_api_web_contents.h index e2e405b73853..3c6bde9c24aa 100644 --- a/atom/browser/api/atom_api_web_contents.h +++ b/atom/browser/api/atom_api_web_contents.h @@ -87,8 +87,8 @@ class WebContents : public mate::TrackableObject, const PrintToPDFCallback& callback); // DevTools workspace api. - void AddWorkSpace(const base::FilePath& path); - void RemoveWorkSpace(const base::FilePath& path); + void AddWorkSpace(mate::Arguments* args, const base::FilePath& path); + void RemoveWorkSpace(mate::Arguments* args, const base::FilePath& path); // Editing commands. void Undo(); diff --git a/atom/browser/api/atom_api_window.cc b/atom/browser/api/atom_api_window.cc index e171fa7698f0..4acd101f3c98 100644 --- a/atom/browser/api/atom_api_window.cc +++ b/atom/browser/api/atom_api_window.cc @@ -209,8 +209,8 @@ void Window::OnExecuteWindowsCommand(const std::string& command_name) { mate::Wrappable* Window::New(v8::Isolate* isolate, const mate::Dictionary& options) { if (!Browser::Get()->is_ready()) { - node::ThrowError(isolate, - "Cannot create BrowserWindow before app is ready"); + isolate->ThrowException(v8::Exception::Error(mate::StringToV8( + isolate, "Cannot create BrowserWindow before app is ready"))); return nullptr; } return new Window(isolate, options); diff --git a/atom/renderer/api/atom_api_renderer_ipc.cc b/atom/renderer/api/atom_api_renderer_ipc.cc index d222f8f73b85..bd0b62656c1d 100644 --- a/atom/renderer/api/atom_api_renderer_ipc.cc +++ b/atom/renderer/api/atom_api_renderer_ipc.cc @@ -30,7 +30,7 @@ RenderView* GetCurrentRenderView() { return RenderView::FromWebView(view); } -void Send(v8::Isolate* isolate, +void Send(mate::Arguments* args, const base::string16& channel, const base::ListValue& arguments) { RenderView* render_view = GetCurrentRenderView(); @@ -41,10 +41,10 @@ void Send(v8::Isolate* isolate, render_view->GetRoutingID(), channel, arguments)); if (!success) - node::ThrowError(isolate, "Unable to send AtomViewHostMsg_Message"); + args->ThrowError("Unable to send AtomViewHostMsg_Message"); } -base::string16 SendSync(v8::Isolate* isolate, +base::string16 SendSync(mate::Arguments* args, const base::string16& channel, const base::ListValue& arguments) { base::string16 json; @@ -60,7 +60,7 @@ base::string16 SendSync(v8::Isolate* isolate, bool success = render_view->Send(message); if (!success) - node::ThrowError(isolate, "Unable to send AtomViewHostMsg_Message_Sync"); + args->ThrowError("Unable to send AtomViewHostMsg_Message_Sync"); return json; } diff --git a/vendor/node b/vendor/node index 5a8258dfabe7..c8962e460f3b 160000 --- a/vendor/node +++ b/vendor/node @@ -1 +1 @@ -Subproject commit 5a8258dfabe7ce3e1489b13d3459ef1d6260d6a5 +Subproject commit c8962e460f3bf03d405489a8380a5571730f5f8d From e365cb6b1c78fb0f9c78ff4f4c20766cca7bcf7a Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Mon, 7 Sep 2015 16:29:54 +0800 Subject: [PATCH 3/3] No longer needs to define node_includes.h at last --- atom/browser/api/atom_api_app.cc | 3 +-- atom/browser/api/atom_api_auto_updater.cc | 3 +-- atom/browser/api/atom_api_content_tracing.cc | 3 +-- atom/browser/api/atom_api_cookies.cc | 2 -- atom/browser/api/atom_api_power_save_blocker.cc | 2 +- atom/browser/api/atom_api_protocol.cc | 3 +-- atom/browser/api/atom_api_session.cc | 3 +-- atom/browser/api/atom_api_tray.cc | 3 +-- atom/browser/atom_browser_main_parts.cc | 3 +-- atom/common/api/atom_api_asar.cc | 3 +-- atom/common/api/atom_api_shell.cc | 3 +-- atom/common/api/atom_api_v8_util.cc | 3 +-- atom/common/api/event_emitter_caller.cc | 3 +-- atom/common/node_bindings.cc | 3 +-- atom/common/node_includes.h | 2 ++ atom/renderer/api/atom_api_renderer_ipc.cc | 3 +-- atom/renderer/atom_render_view_observer.cc | 3 +-- 17 files changed, 17 insertions(+), 31 deletions(-) diff --git a/atom/browser/api/atom_api_app.cc b/atom/browser/api/atom_api_app.cc index c25b3be5f4d6..e2d265c5da39 100644 --- a/atom/browser/api/atom_api_app.cc +++ b/atom/browser/api/atom_api_app.cc @@ -19,6 +19,7 @@ #include "atom/browser/api/atom_api_web_contents.h" #include "atom/common/native_mate_converters/callback.h" #include "atom/common/native_mate_converters/file_path_converter.h" +#include "atom/common/node_includes.h" #include "base/command_line.h" #include "base/environment.h" #include "base/files/file_path.h" @@ -34,8 +35,6 @@ #include "base/strings/utf_string_conversions.h" #endif -#include "atom/common/node_includes.h" - using atom::Browser; namespace mate { diff --git a/atom/browser/api/atom_api_auto_updater.cc b/atom/browser/api/atom_api_auto_updater.cc index 1691ac103e96..250aa3e45f64 100644 --- a/atom/browser/api/atom_api_auto_updater.cc +++ b/atom/browser/api/atom_api_auto_updater.cc @@ -7,11 +7,10 @@ #include "base/time/time.h" #include "atom/browser/auto_updater.h" #include "atom/browser/browser.h" +#include "atom/common/node_includes.h" #include "native_mate/dictionary.h" #include "native_mate/object_template_builder.h" -#include "atom/common/node_includes.h" - namespace atom { namespace api { diff --git a/atom/browser/api/atom_api_content_tracing.cc b/atom/browser/api/atom_api_content_tracing.cc index e4bf33c7b5c5..f29946d1f462 100644 --- a/atom/browser/api/atom_api_content_tracing.cc +++ b/atom/browser/api/atom_api_content_tracing.cc @@ -7,13 +7,12 @@ #include "atom/common/native_mate_converters/callback.h" #include "atom/common/native_mate_converters/file_path_converter.h" +#include "atom/common/node_includes.h" #include "base/bind.h" #include "base/files/file_util.h" #include "content/public/browser/tracing_controller.h" #include "native_mate/dictionary.h" -#include "atom/common/node_includes.h" - using content::TracingController; namespace mate { diff --git a/atom/browser/api/atom_api_cookies.cc b/atom/browser/api/atom_api_cookies.cc index bf56a8dc13bd..4f989eff7275 100644 --- a/atom/browser/api/atom_api_cookies.cc +++ b/atom/browser/api/atom_api_cookies.cc @@ -20,8 +20,6 @@ #include "net/url_request/url_request_context.h" #include "net/url_request/url_request_context_getter.h" -#include "atom/common/node_includes.h" - using atom::api::Cookies; using content::BrowserThread; diff --git a/atom/browser/api/atom_api_power_save_blocker.cc b/atom/browser/api/atom_api_power_save_blocker.cc index c75901cb1e31..58983e6c846a 100644 --- a/atom/browser/api/atom_api_power_save_blocker.cc +++ b/atom/browser/api/atom_api_power_save_blocker.cc @@ -6,9 +6,9 @@ #include +#include "atom/common/node_includes.h" #include "content/public/browser/power_save_blocker.h" #include "native_mate/dictionary.h" -#include "atom/common/node_includes.h" namespace mate { diff --git a/atom/browser/api/atom_api_protocol.cc b/atom/browser/api/atom_api_protocol.cc index f77f3229ed0a..661ab1b5cbdd 100644 --- a/atom/browser/api/atom_api_protocol.cc +++ b/atom/browser/api/atom_api_protocol.cc @@ -12,9 +12,8 @@ #include "atom/browser/net/url_request_fetch_job.h" #include "atom/browser/net/url_request_string_job.h" #include "atom/common/native_mate_converters/callback.h" -#include "native_mate/dictionary.h" - #include "atom/common/node_includes.h" +#include "native_mate/dictionary.h" using content::BrowserThread; diff --git a/atom/browser/api/atom_api_session.cc b/atom/browser/api/atom_api_session.cc index 7d31626c1413..f07ab8b78045 100644 --- a/atom/browser/api/atom_api_session.cc +++ b/atom/browser/api/atom_api_session.cc @@ -13,6 +13,7 @@ #include "atom/common/native_mate_converters/callback.h" #include "atom/common/native_mate_converters/gurl_converter.h" #include "atom/common/native_mate_converters/file_path_converter.h" +#include "atom/common/node_includes.h" #include "base/files/file_path.h" #include "base/prefs/pref_service.h" #include "base/strings/string_util.h" @@ -29,8 +30,6 @@ #include "net/url_request/url_request_context.h" #include "net/url_request/url_request_context_getter.h" -#include "atom/common/node_includes.h" - using content::BrowserThread; using content::StoragePartition; diff --git a/atom/browser/api/atom_api_tray.cc b/atom/browser/api/atom_api_tray.cc index 90bcbcf3e2a7..0f5829e19c14 100644 --- a/atom/browser/api/atom_api_tray.cc +++ b/atom/browser/api/atom_api_tray.cc @@ -12,13 +12,12 @@ #include "atom/common/native_mate_converters/gfx_converter.h" #include "atom/common/native_mate_converters/image_converter.h" #include "atom/common/native_mate_converters/string16_converter.h" +#include "atom/common/node_includes.h" #include "native_mate/constructor.h" #include "native_mate/dictionary.h" #include "ui/events/event_constants.h" #include "ui/gfx/image/image.h" -#include "atom/common/node_includes.h" - namespace atom { namespace api { diff --git a/atom/browser/atom_browser_main_parts.cc b/atom/browser/atom_browser_main_parts.cc index 31a490464143..61b98dfc40ec 100644 --- a/atom/browser/atom_browser_main_parts.cc +++ b/atom/browser/atom_browser_main_parts.cc @@ -13,6 +13,7 @@ #include "atom/browser/node_debugger.h" #include "atom/common/api/atom_bindings.h" #include "atom/common/node_bindings.h" +#include "atom/common/node_includes.h" #include "base/command_line.h" #include "base/thread_task_runner_handle.h" #include "chrome/browser/browser_process.h" @@ -22,8 +23,6 @@ #include "chrome/browser/ui/libgtk2ui/gtk2_util.h" #endif -#include "atom/common/node_includes.h" - namespace atom { // static diff --git a/atom/common/api/atom_api_asar.cc b/atom/common/api/atom_api_asar.cc index 24e9ce9b0668..4ea7d8c5c362 100644 --- a/atom/common/api/atom_api_asar.cc +++ b/atom/common/api/atom_api_asar.cc @@ -10,13 +10,12 @@ #include "atom/common/asar/archive.h" #include "atom/common/native_mate_converters/callback.h" #include "atom/common/native_mate_converters/file_path_converter.h" +#include "atom/common/node_includes.h" #include "native_mate/arguments.h" #include "native_mate/dictionary.h" #include "native_mate/object_template_builder.h" #include "native_mate/wrappable.h" -#include "atom/common/node_includes.h" - namespace { class Archive : public mate::Wrappable { diff --git a/atom/common/api/atom_api_shell.cc b/atom/common/api/atom_api_shell.cc index 013c5f5c6c84..a4599ee0c359 100644 --- a/atom/common/api/atom_api_shell.cc +++ b/atom/common/api/atom_api_shell.cc @@ -7,9 +7,8 @@ #include "atom/common/platform_util.h" #include "atom/common/native_mate_converters/file_path_converter.h" #include "atom/common/native_mate_converters/gurl_converter.h" -#include "native_mate/dictionary.h" - #include "atom/common/node_includes.h" +#include "native_mate/dictionary.h" namespace { diff --git a/atom/common/api/atom_api_v8_util.cc b/atom/common/api/atom_api_v8_util.cc index 21f23a97b456..bba3399a8dbd 100644 --- a/atom/common/api/atom_api_v8_util.cc +++ b/atom/common/api/atom_api_v8_util.cc @@ -3,11 +3,10 @@ // found in the LICENSE file. #include "atom/common/api/object_life_monitor.h" +#include "atom/common/node_includes.h" #include "native_mate/dictionary.h" #include "v8/include/v8-profiler.h" -#include "atom/common/node_includes.h" - namespace { v8::Local CreateObjectWithName(v8::Isolate* isolate, diff --git a/atom/common/api/event_emitter_caller.cc b/atom/common/api/event_emitter_caller.cc index 6b0a07ad414a..94eb9ce9e79a 100644 --- a/atom/common/api/event_emitter_caller.cc +++ b/atom/common/api/event_emitter_caller.cc @@ -5,11 +5,10 @@ #include "atom/common/api/event_emitter_caller.h" #include "atom/common/api/locker.h" +#include "atom/common/node_includes.h" #include "base/memory/scoped_ptr.h" #include "third_party/WebKit/public/web/WebScopedMicrotaskSuppression.h" -#include "atom/common/node_includes.h" - namespace mate { namespace internal { diff --git a/atom/common/node_bindings.cc b/atom/common/node_bindings.cc index 09666a470b6c..5aec200550ad 100644 --- a/atom/common/node_bindings.cc +++ b/atom/common/node_bindings.cc @@ -11,6 +11,7 @@ #include "atom/common/api/locker.h" #include "atom/common/atom_command_line.h" #include "atom/common/native_mate_converters/file_path_converter.h" +#include "atom/common/node_includes.h" #include "base/command_line.h" #include "base/base_paths.h" #include "base/files/file_path.h" @@ -21,8 +22,6 @@ #include "native_mate/dictionary.h" #include "third_party/WebKit/public/web/WebScopedMicrotaskSuppression.h" -#include "atom/common/node_includes.h" - using content::BrowserThread; // Force all builtin modules to be referenced so they can actually run their diff --git a/atom/common/node_includes.h b/atom/common/node_includes.h index 0c4189b2fac3..3876d8622913 100644 --- a/atom/common/node_includes.h +++ b/atom/common/node_includes.h @@ -5,6 +5,8 @@ #ifndef ATOM_COMMON_NODE_INCLUDES_H_ #define ATOM_COMMON_NODE_INCLUDES_H_ +#include "base/logging.h" + // Include common headers for using node APIs. #define BUILDING_NODE_EXTENSION diff --git a/atom/renderer/api/atom_api_renderer_ipc.cc b/atom/renderer/api/atom_api_renderer_ipc.cc index bd0b62656c1d..061293e80d03 100644 --- a/atom/renderer/api/atom_api_renderer_ipc.cc +++ b/atom/renderer/api/atom_api_renderer_ipc.cc @@ -5,13 +5,12 @@ #include "atom/common/api/api_messages.h" #include "atom/common/native_mate_converters/string16_converter.h" #include "atom/common/native_mate_converters/value_converter.h" +#include "atom/common/node_includes.h" #include "content/public/renderer/render_view.h" #include "native_mate/dictionary.h" #include "third_party/WebKit/public/web/WebLocalFrame.h" #include "third_party/WebKit/public/web/WebView.h" -#include "atom/common/node_includes.h" - using content::RenderView; using blink::WebLocalFrame; using blink::WebView; diff --git a/atom/renderer/atom_render_view_observer.cc b/atom/renderer/atom_render_view_observer.cc index 1f199ea445c6..456ca5ba4b24 100644 --- a/atom/renderer/atom_render_view_observer.cc +++ b/atom/renderer/atom_render_view_observer.cc @@ -13,6 +13,7 @@ #include "atom/common/api/api_messages.h" #include "atom/common/api/event_emitter_caller.h" #include "atom/common/native_mate_converters/value_converter.h" +#include "atom/common/node_includes.h" #include "atom/common/options_switches.h" #include "atom/renderer/atom_renderer_client.h" #include "base/command_line.h" @@ -31,8 +32,6 @@ #include "third_party/WebKit/public/web/WebView.h" #include "ui/base/resource/resource_bundle.h" -#include "atom/common/node_includes.h" - namespace atom { namespace {