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

Side by Side Diff: remoting/host/win/rdp_client.cc

Issue 751513003: Remove implicit conversions from scoped_refptr to T* in remoting/ (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
« no previous file with comments | « no previous file | remoting/host/win/rdp_client_window.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "remoting/host/win/rdp_client.h" 5 #include "remoting/host/win/rdp_client.h"
6 6
7 #include <windows.h> 7 #include <windows.h>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 void RdpClient::Core::Connect(const webrtc::DesktopSize& screen_size, 123 void RdpClient::Core::Connect(const webrtc::DesktopSize& screen_size,
124 const std::string& terminal_id) { 124 const std::string& terminal_id) {
125 if (!ui_task_runner_->BelongsToCurrentThread()) { 125 if (!ui_task_runner_->BelongsToCurrentThread()) {
126 ui_task_runner_->PostTask( 126 ui_task_runner_->PostTask(
127 FROM_HERE, base::Bind(&Core::Connect, this, screen_size, terminal_id)); 127 FROM_HERE, base::Bind(&Core::Connect, this, screen_size, terminal_id));
128 return; 128 return;
129 } 129 }
130 130
131 DCHECK(base::MessageLoopForUI::IsCurrent()); 131 DCHECK(base::MessageLoopForUI::IsCurrent());
132 DCHECK(!rdp_client_window_); 132 DCHECK(!rdp_client_window_);
133 DCHECK(!self_); 133 DCHECK(!self_.get());
134 134
135 // Read the port number used by RDP. 135 // Read the port number used by RDP.
136 DWORD server_port; 136 DWORD server_port;
137 base::win::RegKey key(HKEY_LOCAL_MACHINE, kRdpPortKeyName, KEY_READ); 137 base::win::RegKey key(HKEY_LOCAL_MACHINE, kRdpPortKeyName, KEY_READ);
138 if (!key.Valid() || 138 if (!key.Valid() ||
139 (key.ReadValueDW(kRdpPortValueName, &server_port) != ERROR_SUCCESS) || 139 (key.ReadValueDW(kRdpPortValueName, &server_port) != ERROR_SUCCESS) ||
140 server_port > 65535) { 140 server_port > 65535) {
141 server_port = kDefaultRdpPort; 141 server_port = kDefaultRdpPort;
142 } 142 }
143 143
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 } 227 }
228 228
229 if (event_handler_) { 229 if (event_handler_) {
230 RdpClient::EventHandler* event_handler = event_handler_; 230 RdpClient::EventHandler* event_handler = event_handler_;
231 event_handler_ = NULL; 231 event_handler_ = NULL;
232 event_handler->OnRdpClosed(); 232 event_handler->OnRdpClosed();
233 } 233 }
234 } 234 }
235 235
236 } // namespace remoting 236 } // namespace remoting
OLDNEW
« no previous file with comments | « no previous file | remoting/host/win/rdp_client_window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698