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

Unified Diff: chrome/browser/cocoa/autoseparating_menu.m

Issue 159727: Get rid of non-functional elements from the themes prefs; add switcher.... (Closed) Base URL: svn://chrome-svn/chrome/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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/cocoa/autoseparating_menu.h ('k') | chrome/browser/cocoa/preferences_window_controller.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/cocoa/autoseparating_menu.m
===================================================================
--- chrome/browser/cocoa/autoseparating_menu.m (revision 0)
+++ chrome/browser/cocoa/autoseparating_menu.m (revision 0)
@@ -0,0 +1,26 @@
+// Copyright (c) 2009 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#import "chrome/browser/cocoa/autoseparating_menu.h"
+
+@implementation AutoseparatingMenu
+
+- (NSMenuItem *)insertItemWithTitle:(NSString *)aString
+ action:(SEL)aSelector
+ keyEquivalent:(NSString *)keyEquiv
+ atIndex:(NSInteger)index {
+ if ([aString isEqualToString:@"-"]) {
+ NSMenuItem* separator = [NSMenuItem separatorItem];
+ [self insertItem:separator
+ atIndex:index];
+ return separator;
+ } else {
+ return [super insertItemWithTitle:aString
+ action:aSelector
+ keyEquivalent:keyEquiv
+ atIndex:index];
+ }
+}
+
+@end
Property changes on: chrome/browser/cocoa/autoseparating_menu.m
___________________________________________________________________
Name: svn:eol-style
+ LF
« no previous file with comments | « chrome/browser/cocoa/autoseparating_menu.h ('k') | chrome/browser/cocoa/preferences_window_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698