OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // This file provides the embedder's side of random webkit glue functions. | 5 // This file provides the embedder's side of random webkit glue functions. |
6 | 6 |
7 #include "build/build_config.h" | 7 #include "build/build_config.h" |
8 | 8 |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #if defined(OS_WIN) | 11 #if defined(OS_WIN) |
12 #include <windows.h> | 12 #include <windows.h> |
13 #endif | 13 #endif |
14 | 14 |
15 #include "app/clipboard/clipboard.h" | 15 #include "app/clipboard/clipboard.h" |
16 #include "app/clipboard/scoped_clipboard_writer.h" | 16 #include "app/clipboard/scoped_clipboard_writer.h" |
17 #include "app/resource_bundle.h" | 17 #include "app/resource_bundle.h" |
| 18 #include "base/command_line.h" |
18 #include "base/file_version_info.h" | 19 #include "base/file_version_info.h" |
19 #include "base/ref_counted.h" | 20 #include "base/ref_counted.h" |
20 #include "base/string_util.h" | 21 #include "base/string_util.h" |
21 #include "chrome/app/chrome_version_info.h" | 22 #include "chrome/app/chrome_version_info.h" |
22 #include "chrome/common/chrome_switches.h" | 23 #include "chrome/common/chrome_switches.h" |
23 #include "chrome/common/render_messages.h" | 24 #include "chrome/common/render_messages.h" |
24 #include "chrome/common/socket_stream_dispatcher.h" | 25 #include "chrome/common/socket_stream_dispatcher.h" |
25 #include "chrome/common/url_constants.h" | 26 #include "chrome/common/url_constants.h" |
26 #include "chrome/plugin/npobject_util.h" | 27 #include "chrome/plugin/npobject_util.h" |
27 #include "chrome/renderer/net/renderer_net_predictor.h" | 28 #include "chrome/renderer/net/renderer_net_predictor.h" |
(...skipping 246 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
274 | 275 |
275 std::string GetProductVersion() { | 276 std::string GetProductVersion() { |
276 scoped_ptr<FileVersionInfo> version_info( | 277 scoped_ptr<FileVersionInfo> version_info( |
277 chrome_app::GetChromeVersionInfo()); | 278 chrome_app::GetChromeVersionInfo()); |
278 std::string product("Chrome/"); | 279 std::string product("Chrome/"); |
279 product += version_info.get() ? WideToASCII(version_info->product_version()) | 280 product += version_info.get() ? WideToASCII(version_info->product_version()) |
280 : "0.0.0.0"; | 281 : "0.0.0.0"; |
281 return product; | 282 return product; |
282 } | 283 } |
283 | 284 |
| 285 bool IsSingleProcess() { |
| 286 return CommandLine::ForCurrentProcess()->HasSwitch(switches::kSingleProcess); |
| 287 } |
| 288 |
284 } // namespace webkit_glue | 289 } // namespace webkit_glue |
OLD | NEW |