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

Unified Diff: chrome/browser/notifications/notification_exceptions_table_model.cc

Issue 6044007: Remove wstring from TableModel.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 10 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
Index: chrome/browser/notifications/notification_exceptions_table_model.cc
===================================================================
--- chrome/browser/notifications/notification_exceptions_table_model.cc (revision 70272)
+++ chrome/browser/notifications/notification_exceptions_table_model.cc (working copy)
@@ -7,8 +7,6 @@
#include "app/l10n_util.h"
#include "app/table_model_observer.h"
#include "base/auto_reset.h"
-// TODO(avi): remove when conversions not needed any more
-#include "base/utf_string_conversions.h"
#include "chrome/common/content_settings.h"
#include "chrome/common/content_settings_helper.h"
#include "chrome/common/content_settings_types.h"
@@ -72,28 +70,26 @@
return static_cast<int>(entries_.size());
}
-std::wstring NotificationExceptionsTableModel::GetText(int row,
- int column_id) {
+string16 NotificationExceptionsTableModel::GetText(int row,
+ int column_id) {
const Entry& entry = entries_[row];
if (column_id == IDS_EXCEPTIONS_HOSTNAME_HEADER) {
- return content_settings_helper::OriginToWString(entry.origin);
+ return content_settings_helper::OriginToString16(entry.origin);
}
if (column_id == IDS_EXCEPTIONS_ACTION_HEADER) {
switch (entry.setting) {
case CONTENT_SETTING_ALLOW:
- return UTF16ToWideHack(
- l10n_util::GetStringUTF16(IDS_EXCEPTIONS_ALLOW_BUTTON));
+ return l10n_util::GetStringUTF16(IDS_EXCEPTIONS_ALLOW_BUTTON);
case CONTENT_SETTING_BLOCK:
- return UTF16ToWideHack(
- l10n_util::GetStringUTF16(IDS_EXCEPTIONS_BLOCK_BUTTON));
+ return l10n_util::GetStringUTF16(IDS_EXCEPTIONS_BLOCK_BUTTON);
default:
break;
}
}
NOTREACHED();
- return std::wstring();
+ return string16();
}
void NotificationExceptionsTableModel::SetObserver(

Powered by Google App Engine
This is Rietveld 408576698