Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(634)

Side by Side Diff: remoting/host/remoting_me2me_host.cc

Issue 819203002: Make callers of CommandLine use it via the base:: namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 // This file implements a standalone host process for Me2Me. 5 // This file implements a standalone host process for Me2Me.
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/at_exit.h" 9 #include "base/at_exit.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 876 matching lines...) Expand 10 before | Expand all | Expand 10 after
887 } 887 }
888 888
889 // For non-Gmail Google accounts, the owner base JID differs from the email. 889 // For non-Gmail Google accounts, the owner base JID differs from the email.
890 // host_owner_ contains the base JID (used for authenticating clients), while 890 // host_owner_ contains the base JID (used for authenticating clients), while
891 // host_owner_email contains the account's email (used for UI and logs). 891 // host_owner_email contains the account's email (used for UI and logs).
892 if (!config.GetString(kHostOwnerEmailConfigPath, &host_owner_email_)) { 892 if (!config.GetString(kHostOwnerEmailConfigPath, &host_owner_email_)) {
893 host_owner_email_ = host_owner_; 893 host_owner_email_ = host_owner_;
894 } 894 }
895 895
896 // Allow offering of VP9 encoding to be overridden by the command-line. 896 // Allow offering of VP9 encoding to be overridden by the command-line.
897 if (CommandLine::ForCurrentProcess()->HasSwitch(kEnableVp9SwitchName)) { 897 if (base::CommandLine::ForCurrentProcess()->HasSwitch(kEnableVp9SwitchName)) {
898 enable_vp9_ = true; 898 enable_vp9_ = true;
899 } else { 899 } else {
900 config.GetBoolean(kEnableVp9ConfigPath, &enable_vp9_); 900 config.GetBoolean(kEnableVp9ConfigPath, &enable_vp9_);
901 } 901 }
902 902
903 // Allow the command-line to override the size of the frame recorder buffer. 903 // Allow the command-line to override the size of the frame recorder buffer.
904 int frame_recorder_buffer_kb = 0; 904 int frame_recorder_buffer_kb = 0;
905 if (CommandLine::ForCurrentProcess()->HasSwitch( 905 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
906 kFrameRecorderBufferKbName)) { 906 kFrameRecorderBufferKbName)) {
907 std::string switch_value = 907 std::string switch_value =
908 CommandLine::ForCurrentProcess()->GetSwitchValueASCII( 908 base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
909 kFrameRecorderBufferKbName); 909 kFrameRecorderBufferKbName);
910 base::StringToInt(switch_value, &frame_recorder_buffer_kb); 910 base::StringToInt(switch_value, &frame_recorder_buffer_kb);
911 } else { 911 } else {
912 config.GetInteger(kFrameRecorderBufferKbConfigPath, 912 config.GetInteger(kFrameRecorderBufferKbConfigPath,
913 &frame_recorder_buffer_kb); 913 &frame_recorder_buffer_kb);
914 } 914 }
915 if (frame_recorder_buffer_kb > 0) { 915 if (frame_recorder_buffer_kb > 0) {
916 frame_recorder_buffer_size_ = 1024LL * frame_recorder_buffer_kb; 916 frame_recorder_buffer_size_ = 1024LL * frame_recorder_buffer_kb;
917 } 917 }
918 918
(...skipping 584 matching lines...) Expand 10 before | Expand all | Expand 10 after
1503 base::TimeDelta::FromSeconds(kShutdownTimeoutSeconds)); 1503 base::TimeDelta::FromSeconds(kShutdownTimeoutSeconds));
1504 new HostProcess(context.Pass(), &exit_code, &shutdown_watchdog); 1504 new HostProcess(context.Pass(), &exit_code, &shutdown_watchdog);
1505 1505
1506 // Run the main (also UI) message loop until the host no longer needs it. 1506 // Run the main (also UI) message loop until the host no longer needs it.
1507 message_loop.Run(); 1507 message_loop.Run();
1508 1508
1509 return exit_code; 1509 return exit_code;
1510 } 1510 }
1511 1511
1512 } // namespace remoting 1512 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/host/desktop_session_win.cc ('k') | remoting/host/win/unprivileged_process_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698