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

Side by Side Diff: chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.mm

Issue 490123003: Move bookmark_pref_names.* into bookmarks namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: REBASE Created 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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/location_bar/location_bar_view_mac.h" 5 #import "chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/prefs/pref_service.h" 10 #include "base/prefs/pref_service.h"
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 browser_(browser), 135 browser_(browser),
136 weak_ptr_factory_(this) { 136 weak_ptr_factory_(this) {
137 for (size_t i = 0; i < CONTENT_SETTINGS_NUM_TYPES; ++i) { 137 for (size_t i = 0; i < CONTENT_SETTINGS_NUM_TYPES; ++i) {
138 DCHECK_EQ(i, content_setting_decorations_.size()); 138 DCHECK_EQ(i, content_setting_decorations_.size());
139 ContentSettingsType type = static_cast<ContentSettingsType>(i); 139 ContentSettingsType type = static_cast<ContentSettingsType>(i);
140 content_setting_decorations_.push_back( 140 content_setting_decorations_.push_back(
141 new ContentSettingDecoration(type, this, profile)); 141 new ContentSettingDecoration(type, this, profile));
142 } 142 }
143 143
144 edit_bookmarks_enabled_.Init( 144 edit_bookmarks_enabled_.Init(
145 prefs::kEditBookmarksEnabled, profile->GetPrefs(), 145 bookmarks::prefs::kEditBookmarksEnabled, profile->GetPrefs(),
146 base::Bind(&LocationBarViewMac::OnEditBookmarksEnabledChanged, 146 base::Bind(&LocationBarViewMac::OnEditBookmarksEnabledChanged,
147 base::Unretained(this))); 147 base::Unretained(this)));
148 148
149 browser_->search_model()->AddObserver(this); 149 browser_->search_model()->AddObserver(this);
150 150
151 [[field_ cell] setIsPopupMode: 151 [[field_ cell] setIsPopupMode:
152 !browser->SupportsWindowFeature(Browser::FEATURE_TABSTRIP)]; 152 !browser->SupportsWindowFeature(Browser::FEATURE_TABSTRIP)];
153 153
154 if (chrome::ShouldDisplayOriginChip()) 154 if (chrome::ShouldDisplayOriginChip())
155 origin_chip_decoration_.reset(new OriginChipDecoration( 155 origin_chip_decoration_.reset(new OriginChipDecoration(
(...skipping 602 matching lines...) Expand 10 before | Expand all | Expand 10 after
758 } 758 }
759 759
760 bool LocationBarViewMac::UpdateMicSearchDecorationVisibility() { 760 bool LocationBarViewMac::UpdateMicSearchDecorationVisibility() {
761 bool is_visible = !GetToolbarModel()->input_in_progress() && 761 bool is_visible = !GetToolbarModel()->input_in_progress() &&
762 browser_->search_model()->voice_search_supported(); 762 browser_->search_model()->voice_search_supported();
763 if (mic_search_decoration_->IsVisible() == is_visible) 763 if (mic_search_decoration_->IsVisible() == is_visible)
764 return false; 764 return false;
765 mic_search_decoration_->SetVisible(is_visible); 765 mic_search_decoration_->SetVisible(is_visible);
766 return true; 766 return true;
767 } 767 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/browser_window_controller_unittest.mm ('k') | chrome/browser/ui/toolbar/wrench_menu_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698