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

Side by Side Diff: chrome/browser/ui/views/download/download_item_view.cc

Issue 7070001: Change "Save" to "Keep" in dangerous download confirmation prompt. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: update again Created 9 years, 6 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
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/ui/views/download/download_item_view.h" 5 #include "chrome/browser/ui/views/download/download_item_view.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/file_path.h" 10 #include "base/file_path.h"
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 body_hover_animation_.reset(new ui::SlideAnimation(this)); 211 body_hover_animation_.reset(new ui::SlideAnimation(this));
212 drop_hover_animation_.reset(new ui::SlideAnimation(this)); 212 drop_hover_animation_.reset(new ui::SlideAnimation(this));
213 213
214 if (download->safety_state() == DownloadItem::DANGEROUS) { 214 if (download->safety_state() == DownloadItem::DANGEROUS) {
215 tooltip_text_.clear(); 215 tooltip_text_.clear();
216 body_state_ = DANGEROUS; 216 body_state_ = DANGEROUS;
217 drop_down_state_ = DANGEROUS; 217 drop_down_state_ = DANGEROUS;
218 save_button_ = new views::NativeButton(this, 218 save_button_ = new views::NativeButton(this,
219 UTF16ToWide(l10n_util::GetStringUTF16( 219 UTF16ToWide(l10n_util::GetStringUTF16(
220 download->is_extension_install() ? 220 download->is_extension_install() ?
221 IDS_CONTINUE_EXTENSION_DOWNLOAD : IDS_SAVE_DOWNLOAD))); 221 IDS_CONTINUE_EXTENSION_DOWNLOAD : IDS_CONFIRM_DOWNLOAD)));
222 save_button_->set_ignore_minimum_size(true); 222 save_button_->set_ignore_minimum_size(true);
223 discard_button_ = new views::NativeButton( 223 discard_button_ = new views::NativeButton(
224 this, UTF16ToWide(l10n_util::GetStringUTF16(IDS_DISCARD_DOWNLOAD))); 224 this, UTF16ToWide(l10n_util::GetStringUTF16(IDS_DISCARD_DOWNLOAD)));
225 discard_button_->set_ignore_minimum_size(true); 225 discard_button_->set_ignore_minimum_size(true);
226 AddChildView(save_button_); 226 AddChildView(save_button_);
227 AddChildView(discard_button_); 227 AddChildView(discard_button_);
228 228
229 // Ensure the file name is not too long. 229 // Ensure the file name is not too long.
230 230
231 // Extract the file extension (if any). 231 // Extract the file extension (if any).
(...skipping 880 matching lines...) Expand 10 before | Expand all | Expand 10 after
1112 // If the name has changed, notify assistive technology that the name 1112 // If the name has changed, notify assistive technology that the name
1113 // has changed so they can announce it immediately. 1113 // has changed so they can announce it immediately.
1114 if (new_name != accessible_name_) { 1114 if (new_name != accessible_name_) {
1115 accessible_name_ = new_name; 1115 accessible_name_ = new_name;
1116 if (GetWidget()) { 1116 if (GetWidget()) {
1117 GetWidget()->NotifyAccessibilityEvent( 1117 GetWidget()->NotifyAccessibilityEvent(
1118 this, ui::AccessibilityTypes::EVENT_NAME_CHANGED, true); 1118 this, ui::AccessibilityTypes::EVENT_NAME_CHANGED, true);
1119 } 1119 }
1120 } 1120 }
1121 } 1121 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/gtk/download/download_item_gtk.cc ('k') | chrome/browser/ui/webui/downloads_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698