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

Unified Diff: chrome/browser/cocoa/autocomplete_text_field_editor.h

Issue 211030: [Mac] Expose AutocompleteEditViewMac to Cocoa code. (Closed)
Patch Set: Rohit's comments Created 11 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/cocoa/autocomplete_text_field_editor.h
diff --git a/chrome/browser/cocoa/autocomplete_text_field_editor.h b/chrome/browser/cocoa/autocomplete_text_field_editor.h
index 6640f69506aad86341442b542a06b429ae27c734..0821e0886c087773e47d186ff8691a5e080f2961 100644
--- a/chrome/browser/cocoa/autocomplete_text_field_editor.h
+++ b/chrome/browser/cocoa/autocomplete_text_field_editor.h
@@ -4,6 +4,8 @@
#import <Cocoa/Cocoa.h>
+class AutocompleteTextFieldObserver;
+
// AutocompleteTextFieldEditor customized the AutocompletTextField
// field editor (helper text-view used in editing). It intercepts UI
// events for forwarding to the core Omnibox code. It also undoes
@@ -11,18 +13,10 @@
// is styled but should not appear that way when copied to the
// pasteboard).
-// AutocompleteTextFieldEditorDelegateMethods are meant to be similar
-// to NSTextView delegate methods, adding additional intercepts
-// relevant to the Omnibox implementation.
+// TODO(shess): Move delegate stuff to AutocompleteTextFieldObserver.
@protocol AutocompleteTextFieldEditorDelegateMethods
-// Delegate -paste: implementation to the field being edited. If the
-// delegate returns YES, or does not implement the method, NSTextView
-// is called to handle the paste. The delegate can block the paste
-// (or handle it internally) by returning NO.
-- (BOOL)textShouldPaste:(NSText*)fieldEditor;
-
// Returns nil if paste actions are not supported.
- (NSString*)textPasteActionString:(NSText*)fieldEditor;
- (void)textDidPasteAndGo:(NSText*)fieldEditor;
@@ -39,8 +33,8 @@
// Same as above, note that this calls through to performCopy.
- (void)performCut:(NSPasteboard*)pb;
-// Called by -paste: to decide whether to forward to superclass.
-// Exposed for unit testing.
-- (BOOL)shouldPaste;
+@end
+@interface AutocompleteTextFieldEditor(PrivateTestMethods)
+- (AutocompleteTextFieldObserver*)observer;
@end
« no previous file with comments | « chrome/browser/cocoa/autocomplete_text_field.mm ('k') | chrome/browser/cocoa/autocomplete_text_field_editor.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698