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

Unified Diff: chrome/browser/ui/webui/options2/certificate_manager_handler2.cc

Issue 10667026: Start consolidating cross-port file selection code into ui/base/dialogs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/webui/options2/certificate_manager_handler2.cc
diff --git a/chrome/browser/ui/webui/options2/certificate_manager_handler2.cc b/chrome/browser/ui/webui/options2/certificate_manager_handler2.cc
index 5fb114ca7187709da3afeed0954149a5604b29a0..fe0c85b91ec5e5b386223694ff79a4efd22456ec 100644
--- a/chrome/browser/ui/webui/options2/certificate_manager_handler2.cc
+++ b/chrome/browser/ui/webui/options2/certificate_manager_handler2.cc
@@ -13,6 +13,7 @@
#include "base/values.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/certificate_viewer.h"
+#include "chrome/browser/chrome_select_file_policy.h"
#include "chrome/browser/ui/certificate_dialogs.h"
#include "chrome/browser/ui/crypto_module_password_dialog.h"
#include "content/public/browser/browser_thread.h"
@@ -567,7 +568,9 @@ void CertificateManagerHandler::ExportPersonal(const ListValue* args) {
select_file_dialog_->SelectFile(
SelectFileDialog::SELECT_SAVEAS_FILE, string16(),
FilePath(), &file_type_info, 1, FILE_PATH_LITERAL("p12"),
- web_ui()->GetWebContents(), GetParentWindow(),
+ ChromeSelectFilePolicy::DisplayInfobarCallback(
+ web_ui()->GetWebContents()),
+ GetParentWindow(),
reinterpret_cast<void*>(EXPORT_PERSONAL_FILE_SELECTED));
}
@@ -656,7 +659,9 @@ void CertificateManagerHandler::StartImportPersonal(const ListValue* args) {
select_file_dialog_->SelectFile(
SelectFileDialog::SELECT_OPEN_FILE, string16(),
FilePath(), &file_type_info, 1, FILE_PATH_LITERAL("p12"),
- web_ui()->GetWebContents(), GetParentWindow(),
+ ChromeSelectFilePolicy::DisplayInfobarCallback(
+ web_ui()->GetWebContents()),
+ GetParentWindow(),
reinterpret_cast<void*>(IMPORT_PERSONAL_FILE_SELECTED));
}

Powered by Google App Engine
This is Rietveld 408576698