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

Unified Diff: views/accessibility/view_accessibility.cc

Issue 200045: Use Scoped[Bstr,ComPtr,Variant] instead of their ATL equivalents to reduce de... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: views/accessibility/view_accessibility.cc
===================================================================
--- views/accessibility/view_accessibility.cc (revision 25862)
+++ views/accessibility/view_accessibility.cc (working copy)
@@ -326,7 +326,7 @@
GetAccessibleDefaultAction(&temp_action);
}
if (!temp_action.empty()) {
- *def_action = CComBSTR(temp_action.c_str()).Detach();
+ *def_action = SysAllocString(temp_action.c_str());
} else {
return S_FALSE;
}
@@ -350,7 +350,7 @@
view_->GetChildViewAt(var_id.lVal - 1)->GetTooltipText(0, 0, &temp_desc);
}
if (!temp_desc.empty()) {
- *desc = CComBSTR(temp_desc.c_str()).Detach();
+ *desc = SysAllocString(temp_desc.c_str());
} else {
return S_FALSE;
}
@@ -413,7 +413,7 @@
GetAccessibleKeyboardShortcut(&temp_key);
}
if (!temp_key.empty()) {
- *acc_key = CComBSTR(temp_key.c_str()).Detach();
+ *acc_key = SysAllocString(temp_key.c_str());
} else {
return S_FALSE;
}
@@ -440,7 +440,7 @@
}
if (!temp_name.empty()) {
// Return name retrieved.
- *name = CComBSTR(temp_name.c_str()).Detach();
+ *name = SysAllocString(temp_name.c_str());
} else {
// If view has no name, return S_FALSE.
return S_FALSE;

Powered by Google App Engine
This is Rietveld 408576698