diff options
author | viettrungluu@chromium.org <viettrungluu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-25 16:50:48 +0000 |
---|---|---|
committer | viettrungluu@chromium.org <viettrungluu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-25 16:50:48 +0000 |
commit | 964b67701e07ea50ca09747237bfeef23f1b2520 (patch) | |
tree | 25eda14f47d1ab88a8ab571585b7a09fb8309c97 /chrome | |
parent | 26b1c610386a165d276383bfafe99e14f4326ccf (diff) | |
download | chromium_src-964b67701e07ea50ca09747237bfeef23f1b2520.zip chromium_src-964b67701e07ea50ca09747237bfeef23f1b2520.tar.gz chromium_src-964b67701e07ea50ca09747237bfeef23f1b2520.tar.bz2 |
Remove wstrings from bookmarks, part 14.
Convert TreeNodeWithValue's methods to string16.
BUG=23581
TEST=builds and passes tests
Review URL: http://codereview.chromium.org/3198014
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@57337 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/browser/bookmarks/bookmark_model_unittest.cc | 4 | ||||
-rw-r--r-- | chrome/browser/views/bookmark_editor_view.cc | 3 | ||||
-rw-r--r-- | chrome/browser/views/bookmark_editor_view.h | 3 |
3 files changed, 6 insertions, 4 deletions
diff --git a/chrome/browser/bookmarks/bookmark_model_unittest.cc b/chrome/browser/bookmarks/bookmark_model_unittest.cc index 5c788e2..37fcb01 100644 --- a/chrome/browser/bookmarks/bookmark_model_unittest.cc +++ b/chrome/browser/bookmarks/bookmark_model_unittest.cc @@ -573,7 +573,7 @@ static void PopulateNodeImpl(const std::vector<std::string>& description, // in debugging. static int next_group_id = 1; TestNode* new_node = - new TestNode(UTF16ToWideHack(base::IntToString16(next_group_id++)), + new TestNode(base::IntToString16(next_group_id++), BookmarkNode::FOLDER); parent->Add(parent->GetChildCount(), new_node); PopulateNodeImpl(description, index, new_node); @@ -588,7 +588,7 @@ static void PopulateNodeImpl(const std::vector<std::string>& description, DCHECK(element.find('[') == std::string::npos); DCHECK(element.find(']') == std::string::npos); parent->Add(parent->GetChildCount(), - new TestNode(UTF8ToWide(element), BookmarkNode::URL)); + new TestNode(UTF8ToUTF16(element), BookmarkNode::URL)); } } } diff --git a/chrome/browser/views/bookmark_editor_view.cc b/chrome/browser/views/bookmark_editor_view.cc index 7428905..61475f2 100644 --- a/chrome/browser/views/bookmark_editor_view.cc +++ b/chrome/browser/views/bookmark_editor_view.cc @@ -450,7 +450,8 @@ void BookmarkEditorView::NewGroup() { BookmarkEditorView::EditorNode* BookmarkEditorView::AddNewGroup( EditorNode* parent) { EditorNode* new_node = new EditorNode(); - new_node->SetTitle(l10n_util::GetString(IDS_BOOMARK_EDITOR_NEW_FOLDER_NAME)); + new_node->SetTitle( + l10n_util::GetStringUTF16(IDS_BOOMARK_EDITOR_NEW_FOLDER_NAME)); new_node->value = 0; // new_node is now owned by parent. tree_model_->Add(parent, parent->GetChildCount(), new_node); diff --git a/chrome/browser/views/bookmark_editor_view.h b/chrome/browser/views/bookmark_editor_view.h index 29c2530..6b11439 100644 --- a/chrome/browser/views/bookmark_editor_view.h +++ b/chrome/browser/views/bookmark_editor_view.h @@ -8,6 +8,7 @@ #include "app/menus/simple_menu_model.h" #include "app/tree_node_model.h" +#include "base/string16.h" #include "chrome/browser/bookmarks/bookmark_editor.h" #include "chrome/browser/bookmarks/bookmark_model_observer.h" #include "views/controls/button/button.h" @@ -59,7 +60,7 @@ class BookmarkEditorView : public BookmarkEditor, : TreeNodeModel<EditorNode>(root) {} virtual void SetTitle(TreeModelNode* node, - const std::wstring& title) { + const string16& title) { if (!title.empty()) TreeNodeModel::SetTitle(node, title); } |