OLD | NEW |
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/views/collected_cookies_views.h" | 5 #include "chrome/browser/ui/views/collected_cookies_views.h" |
6 | 6 |
7 #include "chrome/browser/browsing_data_appcache_helper.h" | 7 #include "chrome/browser/browsing_data_appcache_helper.h" |
8 #include "chrome/browser/browsing_data_cookie_helper.h" | 8 #include "chrome/browser/browsing_data_cookie_helper.h" |
9 #include "chrome/browser/browsing_data_database_helper.h" | 9 #include "chrome/browser/browsing_data_database_helper.h" |
10 #include "chrome/browser/browsing_data_file_system_helper.h" | 10 #include "chrome/browser/browsing_data_file_system_helper.h" |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
78 SkColor border_color = SK_ColorGRAY; | 78 SkColor border_color = SK_ColorGRAY; |
79 #else | 79 #else |
80 SkColor border_color = color_utils::GetSysSkColor(COLOR_3DSHADOW); | 80 SkColor border_color = color_utils::GetSysSkColor(COLOR_3DSHADOW); |
81 #endif | 81 #endif |
82 views::Border* border = views::Border::CreateSolidBorder( | 82 views::Border* border = views::Border::CreateSolidBorder( |
83 kInfobarBorderSize, border_color); | 83 kInfobarBorderSize, border_color); |
84 content_->set_border(border); | 84 content_->set_border(border); |
85 | 85 |
86 ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance(); | 86 ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance(); |
87 info_image_ = new views::ImageView(); | 87 info_image_ = new views::ImageView(); |
88 info_image_->SetImage(rb.GetBitmapNamed(IDR_INFO)); | 88 info_image_->SetImage(rb.GetImageSkiaNamed(IDR_INFO)); |
89 label_ = new views::Label(); | 89 label_ = new views::Label(); |
90 } | 90 } |
91 virtual ~InfobarView() {} | 91 virtual ~InfobarView() {} |
92 | 92 |
93 // Update the visibility of the infobar. If |is_visible| is true, a rule for | 93 // Update the visibility of the infobar. If |is_visible| is true, a rule for |
94 // |setting| on |domain_name| was created. | 94 // |setting| on |domain_name| was created. |
95 void UpdateVisibility(bool is_visible, | 95 void UpdateVisibility(bool is_visible, |
96 ContentSetting setting, | 96 ContentSetting setting, |
97 const string16& domain_name) { | 97 const string16& domain_name) { |
98 if (!is_visible) { | 98 if (!is_visible) { |
(...skipping 422 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
521 /////////////////////////////////////////////////////////////////////////////// | 521 /////////////////////////////////////////////////////////////////////////////// |
522 // CollectedCookiesViews, content::NotificationObserver implementation: | 522 // CollectedCookiesViews, content::NotificationObserver implementation: |
523 | 523 |
524 void CollectedCookiesViews::Observe( | 524 void CollectedCookiesViews::Observe( |
525 int type, | 525 int type, |
526 const content::NotificationSource& source, | 526 const content::NotificationSource& source, |
527 const content::NotificationDetails& details) { | 527 const content::NotificationDetails& details) { |
528 DCHECK(type == chrome::NOTIFICATION_COLLECTED_COOKIES_SHOWN); | 528 DCHECK(type == chrome::NOTIFICATION_COLLECTED_COOKIES_SHOWN); |
529 window_->CloseConstrainedWindow(); | 529 window_->CloseConstrainedWindow(); |
530 } | 530 } |
OLD | NEW |