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

Side by Side Diff: chrome/browser/cocoa/autocomplete_text_field_editor.mm

Issue 481012: Mac: implement DnD of URLs onto Omnibox. (Closed)
Patch Set: Stuff. Created 11 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 unified diff | Download patch
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 #import "chrome/browser/cocoa/autocomplete_text_field_editor.h" 5 #import "chrome/browser/cocoa/autocomplete_text_field_editor.h"
6 6
7 #include "app/l10n_util_mac.h" 7 #include "app/l10n_util_mac.h"
8 #include "base/string_util.h" 8 #include "base/string_util.h"
9 #include "grit/generated_resources.h" 9 #include "grit/generated_resources.h"
10 #include "base/sys_string_conversions.h" 10 #include "base/sys_string_conversions.h"
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 // NSTextField and NSTextView synchronize their contents. That is 70 // NSTextField and NSTextView synchronize their contents. That is
71 // probably unavoidable because in most cases having rich text in the 71 // probably unavoidable because in most cases having rich text in the
72 // field you probably would expect it to update the font panel. 72 // field you probably would expect it to update the font panel.
73 - (void)updateFontPanel { 73 - (void)updateFontPanel {
74 } 74 }
75 75
76 // No ruler bar, so don't update any of that state, either. 76 // No ruler bar, so don't update any of that state, either.
77 - (void)updateRuler { 77 - (void)updateRuler {
78 } 78 }
79 79
80 // Let the |AutocompleteTextField| handle drops.
81 - (void)updateDragTypeRegistration {
82 }
83
80 - (NSMenu*)menuForEvent:(NSEvent*)event { 84 - (NSMenu*)menuForEvent:(NSEvent*)event {
81 NSMenu* menu = [[[NSMenu alloc] initWithTitle:@"TITLE"] autorelease]; 85 NSMenu* menu = [[[NSMenu alloc] initWithTitle:@"TITLE"] autorelease];
82 [menu addItemWithTitle:l10n_util::GetNSStringWithFixup(IDS_CUT) 86 [menu addItemWithTitle:l10n_util::GetNSStringWithFixup(IDS_CUT)
83 action:@selector(cut:) 87 action:@selector(cut:)
84 keyEquivalent:@""]; 88 keyEquivalent:@""];
85 [menu addItemWithTitle:l10n_util::GetNSStringWithFixup(IDS_COPY) 89 [menu addItemWithTitle:l10n_util::GetNSStringWithFixup(IDS_COPY)
86 action:@selector(copy:) 90 action:@selector(copy:)
87 keyEquivalent:@""]; 91 keyEquivalent:@""];
88 [menu addItemWithTitle:l10n_util::GetNSStringWithFixup(IDS_PASTE) 92 [menu addItemWithTitle:l10n_util::GetNSStringWithFixup(IDS_PASTE)
89 action:@selector(paste:) 93 action:@selector(paste:)
(...skipping 26 matching lines...) Expand all
116 action:@selector(commandDispatch:) 120 action:@selector(commandDispatch:)
117 keyEquivalent:@""]; 121 keyEquivalent:@""];
118 [item setTag:IDC_EDIT_SEARCH_ENGINES]; 122 [item setTag:IDC_EDIT_SEARCH_ENGINES];
119 } 123 }
120 } 124 }
121 125
122 return menu; 126 return menu;
123 } 127 }
124 128
125 @end 129 @end
OLDNEW
« no previous file with comments | « chrome/browser/cocoa/autocomplete_text_field.mm ('k') | chrome/browser/cocoa/browser_window_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698