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

Unified Diff: chrome/browser/ui/views/confirm_bubble_views.cc

Issue 11818044: Replace IDR_WEB_UI_CLOSE* with IDR_CLOSE_DIALOG*, cleanup, etc. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comments. Created 7 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ui/cocoa/hover_close_button.mm ('k') | chrome/browser/ui/views/web_intent_picker_views.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/confirm_bubble_views.cc
diff --git a/chrome/browser/ui/views/confirm_bubble_views.cc b/chrome/browser/ui/views/confirm_bubble_views.cc
index f51a2d916b00a337a5d8980e3ae4e8afdd805d23..2ebba1e3c961e7dcf4775233e36c1bfba1a19a8d 100644
--- a/chrome/browser/ui/views/confirm_bubble_views.cc
+++ b/chrome/browser/ui/views/confirm_bubble_views.cc
@@ -6,7 +6,7 @@
#include "chrome/browser/ui/confirm_bubble.h"
#include "chrome/browser/ui/confirm_bubble_model.h"
-#include "grit/theme_resources.h"
+#include "grit/ui_resources.h"
#include "ui/base/resource/resource_bundle.h"
#include "ui/gfx/image/image.h"
#include "ui/views/controls/button/image_button.h"
@@ -55,7 +55,6 @@ gfx::Rect ConfirmBubbleViews::GetAnchorRect() {
}
void ConfirmBubbleViews::Init() {
- ui::ResourceBundle& bundle = ui::ResourceBundle::GetSharedInstance();
views::GridLayout* layout = new views::GridLayout(this);
SetLayoutManager(layout);
@@ -80,13 +79,17 @@ void ConfirmBubbleViews::Init() {
const string16 title_text = model_->GetTitle();
DCHECK(!title_text.empty());
views::Label* title_label = new views::Label(title_text);
- title_label->SetFont(bundle.GetFont(ui::ResourceBundle::MediumFont));
+ ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance();
+ title_label->SetFont(rb.GetFont(ui::ResourceBundle::MediumFont));
layout->AddView(title_label);
views::ImageButton* close_button = new views::ImageButton(this);
- const gfx::ImageSkia* close_image =
- bundle.GetImageNamed(IDR_WEB_UI_CLOSE).ToImageSkia();
- close_button->SetImage(views::CustomButton::STATE_NORMAL, close_image);
+ close_button->SetImage(views::CustomButton::STATE_NORMAL,
+ rb.GetImageSkiaNamed(IDR_CLOSE_DIALOG));
+ close_button->SetImage(views::CustomButton::STATE_HOVERED,
+ rb.GetImageSkiaNamed(IDR_CLOSE_DIALOG_H));
+ close_button->SetImage(views::CustomButton::STATE_PRESSED,
+ rb.GetImageSkiaNamed(IDR_CLOSE_DIALOG_P));
close_button->set_tag(ConfirmBubbleModel::BUTTON_NONE);
layout->AddView(close_button);
layout->AddPaddingRow(0, views::kRelatedControlVerticalSpacing);
« no previous file with comments | « chrome/browser/ui/cocoa/hover_close_button.mm ('k') | chrome/browser/ui/views/web_intent_picker_views.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698