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

Unified Diff: chrome/browser/ui/cocoa/browser_window_cocoa.mm

Issue 1091703002: Eliminate faux-RTTI code from BrowserView. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Revert to patch set 2 Created 5 years, 8 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
« no previous file with comments | « chrome/browser/ui/cocoa/browser_window_cocoa.h ('k') | chrome/browser/ui/views/frame/browser_view.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/browser_window_cocoa.mm
diff --git a/chrome/browser/ui/cocoa/browser_window_cocoa.mm b/chrome/browser/ui/cocoa/browser_window_cocoa.mm
index 609411aa1dae070396b96706dc90905d96097552..5a70b3940eb34aa55558cbb459fa827e4839395a 100644
--- a/chrome/browser/ui/cocoa/browser_window_cocoa.mm
+++ b/chrome/browser/ui/cocoa/browser_window_cocoa.mm
@@ -733,16 +733,13 @@ void BrowserWindowCocoa::HandleKeyboardEvent(
[BrowserWindowUtils handleKeyboardEvent:event.os_event inWindow:window()];
}
-void BrowserWindowCocoa::Cut() {
- [NSApp sendAction:@selector(cut:) to:nil from:nil];
-}
-
-void BrowserWindowCocoa::Copy() {
- [NSApp sendAction:@selector(copy:) to:nil from:nil];
-}
-
-void BrowserWindowCocoa::Paste() {
- [NSApp sendAction:@selector(paste:) to:nil from:nil];
+void BrowserWindowCocoa::CutCopyPaste(int command_id) {
+ if (command_id == IDC_CUT)
+ [NSApp sendAction:@selector(cut:) to:nil from:nil];
+ else if (command_id == IDC_COPY)
+ [NSApp sendAction:@selector(copy:) to:nil from:nil];
+ else
+ [NSApp sendAction:@selector(paste:) to:nil from:nil];
}
WindowOpenDisposition BrowserWindowCocoa::GetDispositionForPopupBounds(
« no previous file with comments | « chrome/browser/ui/cocoa/browser_window_cocoa.h ('k') | chrome/browser/ui/views/frame/browser_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698