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

Unified Diff: chrome/browser/cocoa/bookmark_editor_controller.mm

Issue 353024: Mac: Enable OK Button when editing a bookmark text to be blank... (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 11 years, 1 month 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/bookmark_editor_controller.mm
===================================================================
--- chrome/browser/cocoa/bookmark_editor_controller.mm (revision 31008)
+++ chrome/browser/cocoa/bookmark_editor_controller.mm (working copy)
@@ -328,10 +328,8 @@
// (Yes, setting ourself as a delegate automatically registers us for
// the notification.)
- (void)controlTextDidChange:(NSNotification*)aNotification {
- // Name must not be empty, but it can be whitespace.
- NSString* name = [nameField_ stringValue];
GURL newURL = [self GURLFromUrlField];
- [okButton_ setEnabled:([name length] != 0 && newURL.is_valid()) ? YES : NO];
+ [okButton_ setEnabled:(newURL.is_valid()) ? YES : NO];
}
// The ok: action is connected to the OK button in the Edit Bookmark window

Powered by Google App Engine
This is Rietveld 408576698