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

Side by Side Diff: chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.mm

Issue 2044923005: [Mac][Material Design] Fix strange Apps button highlight in dark themes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2743
Patch Set: Created 4 years, 6 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/ui/cocoa/bookmarks/bookmark_bar_controller.h" 5 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #import "base/mac/bundle_locations.h" 9 #import "base/mac/bundle_locations.h"
10 #import "base/mac/foundation_util.h" 10 #import "base/mac/foundation_util.h"
(...skipping 1955 matching lines...) Expand 10 before | Expand all | Expand 10 after
1966 // bookmark bar that is not attached to any bookmark node. 1966 // bookmark bar that is not attached to any bookmark node.
1967 // TODO(jrg): move much of the cell config into the BookmarkButtonCell class. 1967 // TODO(jrg): move much of the cell config into the BookmarkButtonCell class.
1968 - (BookmarkButtonCell*)cellForCustomButtonWithText:(NSString*)text 1968 - (BookmarkButtonCell*)cellForCustomButtonWithText:(NSString*)text
1969 image:(NSImage*)image { 1969 image:(NSImage*)image {
1970 BookmarkButtonCell* cell = 1970 BookmarkButtonCell* cell =
1971 [BookmarkButtonCell buttonCellWithText:text 1971 [BookmarkButtonCell buttonCellWithText:text
1972 image:image 1972 image:image
1973 menuController:contextMenuController_]; 1973 menuController:contextMenuController_];
1974 if (ui::MaterialDesignController::IsModeMaterial()) { 1974 if (ui::MaterialDesignController::IsModeMaterial()) {
1975 [cell setTag:kMaterialStandardButtonTypeWithLimitedClickFeedback]; 1975 [cell setTag:kMaterialStandardButtonTypeWithLimitedClickFeedback];
1976 [cell setHighlightsBy:NSNoCellMask];
1976 } else { 1977 } else {
1977 [cell setTag:kStandardButtonTypeWithLimitedClickFeedback]; 1978 [cell setTag:kStandardButtonTypeWithLimitedClickFeedback];
1978 } 1979 }
1979 1980
1980 // Note: a quirk of setting a cell's text color is that it won't work 1981 // Note: a quirk of setting a cell's text color is that it won't work
1981 // until the cell is associated with a button, so we can't theme the cell yet. 1982 // until the cell is associated with a button, so we can't theme the cell yet.
1982 1983
1983 return cell; 1984 return cell;
1984 } 1985 }
1985 1986
(...skipping 1104 matching lines...) Expand 10 before | Expand all | Expand 10 after
3090 - (id<BookmarkButtonControllerProtocol>)controllerForNode: 3091 - (id<BookmarkButtonControllerProtocol>)controllerForNode:
3091 (const BookmarkNode*)node { 3092 (const BookmarkNode*)node {
3092 // See if it's in the bar, then if it is in the hierarchy of visible 3093 // See if it's in the bar, then if it is in the hierarchy of visible
3093 // folder menus. 3094 // folder menus.
3094 if (bookmarkModel_->bookmark_bar_node() == node) 3095 if (bookmarkModel_->bookmark_bar_node() == node)
3095 return self; 3096 return self;
3096 return [folderController_ controllerForNode:node]; 3097 return [folderController_ controllerForNode:node];
3097 } 3098 }
3098 3099
3099 @end 3100 @end
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698