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

Unified Diff: sandbox/win/src/window.cc

Issue 109843003: Replace wstring with string16 in sandbox (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sandbox/win/src/window.h ('k') | sandbox/win/tests/common/controller.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sandbox/win/src/window.cc
diff --git a/sandbox/win/src/window.cc b/sandbox/win/src/window.cc
index d8de967272661360a9309ee6bf571c4bfed4b47d..d21858a42a4a2cb24ecc0becbca41e22a992cf79 100644
--- a/sandbox/win/src/window.cc
+++ b/sandbox/win/src/window.cc
@@ -53,7 +53,7 @@ ResultCode CreateAltWindowStation(HWINSTA* winsta) {
}
ResultCode CreateAltDesktop(HWINSTA winsta, HDESK* desktop) {
- std::wstring desktop_name = L"sbox_alternate_desktop_";
+ base::string16 desktop_name = L"sbox_alternate_desktop_";
// Append the current PID to the desktop name.
wchar_t buffer[16];
@@ -100,14 +100,14 @@ ResultCode CreateAltDesktop(HWINSTA winsta, HDESK* desktop) {
return SBOX_ERROR_CANNOT_CREATE_DESKTOP;
}
-std::wstring GetWindowObjectName(HANDLE handle) {
+base::string16 GetWindowObjectName(HANDLE handle) {
// Get the size of the name.
DWORD size = 0;
::GetUserObjectInformation(handle, UOI_NAME, NULL, 0, &size);
if (!size) {
NOTREACHED();
- return std::wstring();
+ return base::string16();
}
// Create the buffer that will hold the name.
@@ -117,19 +117,19 @@ std::wstring GetWindowObjectName(HANDLE handle) {
if (!::GetUserObjectInformation(handle, UOI_NAME, name_buffer.get(), size,
&size)) {
NOTREACHED();
- return std::wstring();
+ return base::string16();
}
- return std::wstring(name_buffer.get());
+ return base::string16(name_buffer.get());
}
-std::wstring GetFullDesktopName(HWINSTA winsta, HDESK desktop) {
+base::string16 GetFullDesktopName(HWINSTA winsta, HDESK desktop) {
if (!desktop) {
NOTREACHED();
- return std::wstring();
+ return base::string16();
}
- std::wstring name;
+ base::string16 name;
if (winsta) {
name = GetWindowObjectName(winsta);
name += L'\\';
« no previous file with comments | « sandbox/win/src/window.h ('k') | sandbox/win/tests/common/controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698