OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #include "chrome/browser/chrome_browser_main.h" | 5 #include "chrome/browser/chrome_browser_main.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
495 | 495 |
496 void LaunchDevToolsHandlerIfNeeded(const CommandLine& command_line) { | 496 void LaunchDevToolsHandlerIfNeeded(const CommandLine& command_line) { |
497 if (command_line.HasSwitch(::switches::kRemoteDebuggingPort)) { | 497 if (command_line.HasSwitch(::switches::kRemoteDebuggingPort)) { |
498 std::string port_str = | 498 std::string port_str = |
499 command_line.GetSwitchValueASCII(::switches::kRemoteDebuggingPort); | 499 command_line.GetSwitchValueASCII(::switches::kRemoteDebuggingPort); |
500 int port; | 500 int port; |
501 if (base::StringToInt(port_str, &port) && port >= 0 && port < 65535) { | 501 if (base::StringToInt(port_str, &port) && port >= 0 && port < 65535) { |
502 g_browser_process->CreateDevToolsHttpProtocolHandler( | 502 g_browser_process->CreateDevToolsHttpProtocolHandler( |
503 chrome::HOST_DESKTOP_TYPE_NATIVE, | 503 chrome::HOST_DESKTOP_TYPE_NATIVE, |
504 "127.0.0.1", | 504 "127.0.0.1", |
505 port); | 505 static_cast<uint16>(port)); |
506 } else { | 506 } else { |
507 DLOG(WARNING) << "Invalid http debugger port number " << port; | 507 DLOG(WARNING) << "Invalid http debugger port number " << port; |
508 } | 508 } |
509 } | 509 } |
510 } | 510 } |
511 | 511 |
512 // Heap allocated class that listens for first page load, kicks off stat | 512 // Heap allocated class that listens for first page load, kicks off stat |
513 // recording and then deletes itself. | 513 // recording and then deletes itself. |
514 class LoadCompleteListener : public content::NotificationObserver { | 514 class LoadCompleteListener : public content::NotificationObserver { |
515 public: | 515 public: |
(...skipping 1206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1722 chromeos::CrosSettings::Shutdown(); | 1722 chromeos::CrosSettings::Shutdown(); |
1723 #endif | 1723 #endif |
1724 #endif | 1724 #endif |
1725 } | 1725 } |
1726 | 1726 |
1727 // Public members: | 1727 // Public members: |
1728 | 1728 |
1729 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { | 1729 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { |
1730 chrome_extra_parts_.push_back(parts); | 1730 chrome_extra_parts_.push_back(parts); |
1731 } | 1731 } |
OLD | NEW |