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

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

Issue 11195006: Removing "Failed to open the desktop receiving user input" message. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 months 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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) 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 "remoting/host/win/desktop.h" 5 #include "remoting/host/win/desktop.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 10
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 << "Failed to open the desktop '" << desktop_name << "'"; 76 << "Failed to open the desktop '" << desktop_name << "'";
77 return scoped_ptr<Desktop>(); 77 return scoped_ptr<Desktop>();
78 } 78 }
79 79
80 return scoped_ptr<Desktop>(new Desktop(desktop, true)); 80 return scoped_ptr<Desktop>(new Desktop(desktop, true));
81 } 81 }
82 82
83 scoped_ptr<Desktop> Desktop::GetInputDesktop() { 83 scoped_ptr<Desktop> Desktop::GetInputDesktop() {
84 HDESK desktop = OpenInputDesktop( 84 HDESK desktop = OpenInputDesktop(
85 0, FALSE, GENERIC_READ | GENERIC_WRITE | GENERIC_EXECUTE); 85 0, FALSE, GENERIC_READ | GENERIC_WRITE | GENERIC_EXECUTE);
86 if (desktop == NULL) { 86 if (desktop == NULL)
87 LOG_GETLASTERROR(ERROR)
88 << "Failed to open the desktop receiving user input";
89 return scoped_ptr<Desktop>(); 87 return scoped_ptr<Desktop>();
90 }
91 88
92 return scoped_ptr<Desktop>(new Desktop(desktop, true)); 89 return scoped_ptr<Desktop>(new Desktop(desktop, true));
93 } 90 }
94 91
95 scoped_ptr<Desktop> Desktop::GetThreadDesktop() { 92 scoped_ptr<Desktop> Desktop::GetThreadDesktop() {
96 HDESK desktop = ::GetThreadDesktop(GetCurrentThreadId()); 93 HDESK desktop = ::GetThreadDesktop(GetCurrentThreadId());
97 if (desktop == NULL) { 94 if (desktop == NULL) {
98 LOG_GETLASTERROR(ERROR) 95 LOG_GETLASTERROR(ERROR)
99 << "Failed to retrieve the handle of the desktop assigned to " 96 << "Failed to retrieve the handle of the desktop assigned to "
100 "the current thread"; 97 "the current thread";
101 return scoped_ptr<Desktop>(); 98 return scoped_ptr<Desktop>();
102 } 99 }
103 100
104 return scoped_ptr<Desktop>(new Desktop(desktop, false)); 101 return scoped_ptr<Desktop>(new Desktop(desktop, false));
105 } 102 }
106 103
107 } // namespace remoting 104 } // namespace remoting
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698