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

Side by Side Diff: chrome/browser/bookmarks/bookmark_context_menu_controller.cc

Issue 155076: Add the menus copy, cut and paste to BookmarkBar and BookmarkMenu.... (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Created 11 years, 5 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 | « no previous file | 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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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/views/bookmark_context_menu.h" 5 #include "chrome/browser/views/bookmark_context_menu.h"
6 6
7 #include "app/l10n_util.h" 7 #include "app/l10n_util.h"
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "chrome/browser/bookmarks/bookmark_editor.h" 9 #include "chrome/browser/bookmarks/bookmark_editor.h"
10 #include "chrome/browser/bookmarks/bookmark_manager.h" 10 #include "chrome/browser/bookmarks/bookmark_manager.h"
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after
246 configuration_ == BOOKMARK_MANAGER_TABLE_OTHER || 246 configuration_ == BOOKMARK_MANAGER_TABLE_OTHER ||
247 configuration_ == BOOKMARK_MANAGER_ORGANIZE_MENU || 247 configuration_ == BOOKMARK_MANAGER_ORGANIZE_MENU ||
248 configuration_ == BOOKMARK_MANAGER_ORGANIZE_MENU_OTHER) { 248 configuration_ == BOOKMARK_MANAGER_ORGANIZE_MENU_OTHER) {
249 delegate_->AddItem(IDS_BOOKMARK_MANAGER_SHOW_IN_FOLDER); 249 delegate_->AddItem(IDS_BOOKMARK_MANAGER_SHOW_IN_FOLDER);
250 } 250 }
251 251
252 if (configuration_ == BOOKMARK_MANAGER_TABLE || 252 if (configuration_ == BOOKMARK_MANAGER_TABLE ||
253 configuration_ == BOOKMARK_MANAGER_TABLE_OTHER || 253 configuration_ == BOOKMARK_MANAGER_TABLE_OTHER ||
254 configuration_ == BOOKMARK_MANAGER_TREE || 254 configuration_ == BOOKMARK_MANAGER_TREE ||
255 configuration_ == BOOKMARK_MANAGER_ORGANIZE_MENU || 255 configuration_ == BOOKMARK_MANAGER_ORGANIZE_MENU ||
256 configuration_ == BOOKMARK_MANAGER_ORGANIZE_MENU_OTHER) { 256 configuration_ == BOOKMARK_MANAGER_ORGANIZE_MENU_OTHER ||
257 configuration_ == BOOKMARK_BAR) {
257 delegate_->AddSeparator(); 258 delegate_->AddSeparator();
258 delegate_->AddItem(IDS_CUT); 259 delegate_->AddItem(IDS_CUT);
259 delegate_->AddItem(IDS_COPY); 260 delegate_->AddItem(IDS_COPY);
260 delegate_->AddItem(IDS_PASTE); 261 delegate_->AddItem(IDS_PASTE);
261 } 262 }
262 263
263 if (configuration_ == BOOKMARK_MANAGER_ORGANIZE_MENU) { 264 if (configuration_ == BOOKMARK_MANAGER_ORGANIZE_MENU) {
264 delegate_->AddSeparator(); 265 delegate_->AddSeparator();
265 delegate_->AddItem(IDS_BOOKMARK_MANAGER_SORT); 266 delegate_->AddItem(IDS_BOOKMARK_MANAGER_SORT);
266 } 267 }
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after
521 return true; 522 return true;
522 } 523 }
523 return false; 524 return false;
524 } 525 }
525 526
526 const BookmarkNode* 527 const BookmarkNode*
527 BookmarkContextMenuController::GetParentForNewNodes() const { 528 BookmarkContextMenuController::GetParentForNewNodes() const {
528 return (selection_.size() == 1 && selection_[0]->is_folder()) ? 529 return (selection_.size() == 1 && selection_[0]->is_folder()) ?
529 selection_[0] : parent_; 530 selection_[0] : parent_;
530 } 531 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698