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

Side by Side Diff: chrome/browser/ui/views/bookmarks/bookmark_menu_delegate.cc

Issue 7744055: bookmarks: Fix an obvious typo in IDS_BOOMARK_*. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/ui/views/bookmarks/bookmark_editor_view.cc ('k') | 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "chrome/browser/ui/views/bookmarks/bookmark_menu_delegate.h" 5 #include "chrome/browser/ui/views/bookmarks/bookmark_menu_delegate.h"
6 6
7 #include "base/utf_string_conversions.h" 7 #include "base/utf_string_conversions.h"
8 #include "chrome/browser/bookmarks/bookmark_model.h" 8 #include "chrome/browser/bookmarks/bookmark_model.h"
9 #include "chrome/browser/bookmarks/bookmark_node_data.h" 9 #include "chrome/browser/bookmarks/bookmark_node_data.h"
10 #include "chrome/browser/bookmarks/bookmark_utils.h" 10 #include "chrome/browser/bookmarks/bookmark_utils.h"
(...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after
392 392
393 void BookmarkMenuDelegate::BuildOtherFolderMenu( 393 void BookmarkMenuDelegate::BuildOtherFolderMenu(
394 MenuItemView* menu, int* next_menu_id) { 394 MenuItemView* menu, int* next_menu_id) {
395 const BookmarkNode* other_folder = profile_->GetBookmarkModel()->other_node(); 395 const BookmarkNode* other_folder = profile_->GetBookmarkModel()->other_node();
396 int id = *next_menu_id; 396 int id = *next_menu_id;
397 (*next_menu_id)++; 397 (*next_menu_id)++;
398 SkBitmap* folder_icon = ResourceBundle::GetSharedInstance(). 398 SkBitmap* folder_icon = ResourceBundle::GetSharedInstance().
399 GetBitmapNamed(IDR_BOOKMARK_BAR_FOLDER); 399 GetBitmapNamed(IDR_BOOKMARK_BAR_FOLDER);
400 MenuItemView* submenu = menu->AppendSubMenuWithIcon( 400 MenuItemView* submenu = menu->AppendSubMenuWithIcon(
401 id, UTF16ToWide( 401 id, UTF16ToWide(
402 l10n_util::GetStringUTF16(IDS_BOOMARK_BAR_OTHER_BOOKMARKED)), 402 l10n_util::GetStringUTF16(IDS_BOOKMARK_BAR_OTHER_BOOKMARKED)),
403 *folder_icon); 403 *folder_icon);
404 BuildMenu(other_folder, 0, submenu, next_menu_id); 404 BuildMenu(other_folder, 0, submenu, next_menu_id);
405 menu_id_to_node_map_[id] = other_folder; 405 menu_id_to_node_map_[id] = other_folder;
406 } 406 }
407 407
408 void BookmarkMenuDelegate::BuildMenu(const BookmarkNode* parent, 408 void BookmarkMenuDelegate::BuildMenu(const BookmarkNode* parent,
409 int start_child_index, 409 int start_child_index,
410 MenuItemView* menu, 410 MenuItemView* menu,
411 int* next_menu_id) { 411 int* next_menu_id) {
412 DCHECK(parent->empty() || start_child_index < parent->child_count()); 412 DCHECK(parent->empty() || start_child_index < parent->child_count());
(...skipping 27 matching lines...) Expand all
440 MenuItemView* BookmarkMenuDelegate::GetMenuByID(int id) { 440 MenuItemView* BookmarkMenuDelegate::GetMenuByID(int id) {
441 for (NodeToMenuMap::const_iterator i = node_to_menu_map_.begin(); 441 for (NodeToMenuMap::const_iterator i = node_to_menu_map_.begin();
442 i != node_to_menu_map_.end(); ++i) { 442 i != node_to_menu_map_.end(); ++i) {
443 MenuItemView* menu = i->second->GetMenuItemByID(id); 443 MenuItemView* menu = i->second->GetMenuItemByID(id);
444 if (menu) 444 if (menu)
445 return menu; 445 return menu;
446 } 446 }
447 447
448 return parent_menu_item_ ? parent_menu_item_->GetMenuItemByID(id) : NULL; 448 return parent_menu_item_ ? parent_menu_item_->GetMenuItemByID(id) : NULL;
449 } 449 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/bookmarks/bookmark_editor_view.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698