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

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

Issue 10068025: views: Initialize message_box_title_ in the initalizer list. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: peter review Created 8 years, 8 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/views/simple_message_box_views.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/simple_message_box_views.cc
diff --git a/chrome/browser/ui/views/simple_message_box_views.cc b/chrome/browser/ui/views/simple_message_box_views.cc
index a67e6539f148b1f363af1b155c346506f36abd3e..4b47a61d5a36d764edb5a372aa6e7f58cc703938 100644
--- a/chrome/browser/ui/views/simple_message_box_views.cc
+++ b/chrome/browser/ui/views/simple_message_box_views.cc
@@ -80,7 +80,7 @@ bool SimpleMessageBoxViews::ShowYesNoBox(gfx::NativeWindow parent_window,
// SimpleMessageBoxViews, private:
int SimpleMessageBoxViews::GetDialogButtons() const {
- if (type_ == DIALOG_ERROR)
+ if (dialog_type_ == DIALOG_ERROR)
return ui::DIALOG_BUTTON_OK;
return ui::DIALOG_BUTTON_OK | ui::DIALOG_BUTTON_CANCEL;
}
@@ -102,7 +102,7 @@ bool SimpleMessageBoxViews::Accept() {
}
string16 SimpleMessageBoxViews::GetWindowTitle() const {
- return message_box_title_;
+ return window_title_;
}
void SimpleMessageBoxViews::DeleteDelegate() {
@@ -126,16 +126,14 @@ const views::Widget* SimpleMessageBoxViews::GetWidget() const {
}
SimpleMessageBoxViews::SimpleMessageBoxViews(gfx::NativeWindow parent_window,
- DialogType type,
+ DialogType dialog_type,
const string16& title,
const string16& message)
- : type_(type),
- disposition_(DISPOSITION_UNKNOWN) {
- message_box_title_ = title;
- message_box_view_ = new views::MessageBoxView(
- views::MessageBoxView::NO_OPTIONS,
- message,
- string16());
+ : dialog_type_(dialog_type),
+ disposition_(DISPOSITION_UNKNOWN),
+ window_title_(title),
+ message_box_view_(new views::MessageBoxView(
+ views::MessageBoxView::NO_OPTIONS, message, string16())) {
views::Widget::CreateWindowWithParent(this, parent_window)->Show();
// Add reference to be released in DeleteDelegate().
« no previous file with comments | « chrome/browser/ui/views/simple_message_box_views.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698