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

Side by Side Diff: chrome/browser/ui/content_settings/content_setting_image_model.cc

Issue 12089015: Fix post commit comments for CL 11896028. Only nits. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « chrome/browser/ui/content_settings/content_setting_bubble_model.cc ('k') | 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 #include "chrome/browser/ui/content_settings/content_setting_image_model.h" 5 #include "chrome/browser/ui/content_settings/content_setting_image_model.h"
6 6
7 #include "chrome/browser/content_settings/host_content_settings_map.h" 7 #include "chrome/browser/content_settings/host_content_settings_map.h"
8 #include "chrome/browser/content_settings/tab_specific_content_settings.h" 8 #include "chrome/browser/content_settings/tab_specific_content_settings.h"
9 #include "chrome/browser/prerender/prerender_manager.h" 9 #include "chrome/browser/prerender/prerender_manager.h"
10 #include "chrome/browser/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 if (!content_settings) 189 if (!content_settings)
190 return; 190 return;
191 191
192 bool blocked = 192 bool blocked =
193 content_settings->IsContentBlocked(CONTENT_SETTINGS_TYPE_MEDIASTREAM); 193 content_settings->IsContentBlocked(CONTENT_SETTINGS_TYPE_MEDIASTREAM);
194 if (!blocked && 194 if (!blocked &&
195 !content_settings->IsContentAccessed(get_content_settings_type())) 195 !content_settings->IsContentAccessed(get_content_settings_type()))
196 return; 196 return;
197 197
198 set_tooltip( 198 set_tooltip(
199 l10n_util::GetStringUTF8(blocked ? IDS_MEDIASTREAM_BLOCKED_TOOLTIP 199 l10n_util::GetStringUTF8(blocked ?
200 : IDS_MEDIASTREAM_ALLOWED_TOOLTIP)); 200 IDS_MEDIASTREAM_BLOCKED_TOOLTIP : IDS_MEDIASTREAM_ALLOWED_TOOLTIP));
201 set_icon(blocked ? IDR_BLOCKED_MEDIA : IDR_ASK_MEDIA); 201 set_icon(blocked ? IDR_BLOCKED_MEDIA : IDR_ASK_MEDIA);
202 set_visible(true); 202 set_visible(true);
203 } 203 }
204 204
205 ContentSettingRPHImageModel::ContentSettingRPHImageModel() 205 ContentSettingRPHImageModel::ContentSettingRPHImageModel()
206 : ContentSettingImageModel( 206 : ContentSettingImageModel(
207 CONTENT_SETTINGS_TYPE_PROTOCOL_HANDLERS) { 207 CONTENT_SETTINGS_TYPE_PROTOCOL_HANDLERS) {
208 set_icon(IDR_REGISTER_PROTOCOL_HANDLER_LOCATIONBAR_ICON); 208 set_icon(IDR_REGISTER_PROTOCOL_HANDLER_LOCATIONBAR_ICON);
209 set_tooltip(l10n_util::GetStringUTF8(IDS_REGISTER_PROTOCOL_HANDLER_TOOLTIP)); 209 set_tooltip(l10n_util::GetStringUTF8(IDS_REGISTER_PROTOCOL_HANDLER_TOOLTIP));
210 } 210 }
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
253 case CONTENT_SETTINGS_TYPE_NOTIFICATIONS: 253 case CONTENT_SETTINGS_TYPE_NOTIFICATIONS:
254 return new ContentSettingNotificationsImageModel(); 254 return new ContentSettingNotificationsImageModel();
255 case CONTENT_SETTINGS_TYPE_PROTOCOL_HANDLERS: 255 case CONTENT_SETTINGS_TYPE_PROTOCOL_HANDLERS:
256 return new ContentSettingRPHImageModel(); 256 return new ContentSettingRPHImageModel();
257 case CONTENT_SETTINGS_TYPE_MEDIASTREAM: 257 case CONTENT_SETTINGS_TYPE_MEDIASTREAM:
258 return new ContentSettingMediaImageModel(); 258 return new ContentSettingMediaImageModel();
259 default: 259 default:
260 return new ContentSettingBlockedImageModel(content_settings_type); 260 return new ContentSettingBlockedImageModel(content_settings_type);
261 } 261 }
262 } 262 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/content_settings/content_setting_bubble_model.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698