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

Side by Side Diff: chrome/browser/content_setting_bubble_model.cc

Issue 6670011: Options: Remove the GTK and Views native options code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Created 9 years, 9 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 | « no previous file | chrome/browser/notifications/notification_options_menu_model.cc » ('j') | 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/content_setting_bubble_model.h" 5 #include "chrome/browser/content_setting_bubble_model.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/utf_string_conversions.h" 8 #include "base/utf_string_conversions.h"
9 #include "chrome/browser/blocked_content_container.h" 9 #include "chrome/browser/blocked_content_container.h"
10 #include "chrome/browser/content_settings/host_content_settings_map.h" 10 #include "chrome/browser/content_settings/host_content_settings_map.h"
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 0, // Notifications do not have a bubble. 113 0, // Notifications do not have a bubble.
114 0, // Prerender does not have a bubble. 114 0, // Prerender does not have a bubble.
115 }; 115 };
116 COMPILE_ASSERT(arraysize(kLinkIDs) == CONTENT_SETTINGS_NUM_TYPES, 116 COMPILE_ASSERT(arraysize(kLinkIDs) == CONTENT_SETTINGS_NUM_TYPES,
117 Need_a_setting_for_every_content_settings_type); 117 Need_a_setting_for_every_content_settings_type);
118 set_manage_link(l10n_util::GetStringUTF8(kLinkIDs[content_type()])); 118 set_manage_link(l10n_util::GetStringUTF8(kLinkIDs[content_type()]));
119 } 119 }
120 120
121 virtual void OnManageLinkClicked() { 121 virtual void OnManageLinkClicked() {
122 if (tab_contents()) 122 if (tab_contents())
123 tab_contents()->delegate()->ShowContentSettingsWindow(content_type()); 123 tab_contents()->delegate()->ShowContentSettingsPage(content_type());
124 } 124 }
125 }; 125 };
126 126
127 class ContentSettingTitleLinkAndCustomModel 127 class ContentSettingTitleLinkAndCustomModel
128 : public ContentSettingTitleAndLinkModel { 128 : public ContentSettingTitleAndLinkModel {
129 public: 129 public:
130 ContentSettingTitleLinkAndCustomModel(TabContents* tab_contents, 130 ContentSettingTitleLinkAndCustomModel(TabContents* tab_contents,
131 Profile* profile, 131 Profile* profile,
132 ContentSettingsType content_type) 132 ContentSettingsType content_type)
133 : ContentSettingTitleAndLinkModel(tab_contents, profile, content_type) { 133 : ContentSettingTitleAndLinkModel(tab_contents, profile, content_type) {
(...skipping 391 matching lines...) Expand 10 before | Expand all | Expand 10 after
525 bubble_content_.resource_identifiers.insert(resource_identifier); 525 bubble_content_.resource_identifiers.insert(resource_identifier);
526 } 526 }
527 527
528 void ContentSettingBubbleModel::Observe(NotificationType type, 528 void ContentSettingBubbleModel::Observe(NotificationType type,
529 const NotificationSource& source, 529 const NotificationSource& source,
530 const NotificationDetails& details) { 530 const NotificationDetails& details) {
531 DCHECK(type == NotificationType::TAB_CONTENTS_DESTROYED); 531 DCHECK(type == NotificationType::TAB_CONTENTS_DESTROYED);
532 DCHECK(source == Source<TabContents>(tab_contents_)); 532 DCHECK(source == Source<TabContents>(tab_contents_));
533 tab_contents_ = NULL; 533 tab_contents_ = NULL;
534 } 534 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/notifications/notification_options_menu_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698