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

Unified Diff: chrome/browser/ui/browser.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: Attempt to fix win 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
« no previous file with comments | « chrome/browser/file_select_helper.cc ('k') | chrome/browser/ui/certificate_dialogs.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/browser.cc
diff --git a/chrome/browser/ui/browser.cc b/chrome/browser/ui/browser.cc
index 9678a3495effbcae8cec167e49fa20d499fb5a08..8d8ae0f28e8e667cdbce58548640830c9e4f76c6 100644
--- a/chrome/browser/ui/browser.cc
+++ b/chrome/browser/ui/browser.cc
@@ -107,6 +107,7 @@
#include "chrome/browser/ui/browser_ui_prefs.h"
#include "chrome/browser/ui/browser_window.h"
#include "chrome/browser/ui/chrome_pages.h"
+#include "chrome/browser/ui/chrome_select_file_policy.h"
#include "chrome/browser/ui/constrained_window_tab_helper.h"
#include "chrome/browser/ui/extensions/shell_window.h"
#include "chrome/browser/ui/find_bar/find_bar.h"
@@ -955,8 +956,8 @@ void Browser::OverrideEncoding(int encoding_id) {
void Browser::OpenFile() {
content::RecordAction(UserMetricsAction("OpenFile"));
- if (!select_file_dialog_.get())
- select_file_dialog_ = SelectFileDialog::Create(this);
+ select_file_dialog_ = SelectFileDialog::Create(
+ this, new ChromeSelectFilePolicy(GetActiveWebContents()));
const FilePath directory = profile_->last_selected_directory();
@@ -965,7 +966,6 @@ void Browser::OpenFile() {
select_file_dialog_->SelectFile(SelectFileDialog::SELECT_OPEN_FILE,
string16(), directory,
NULL, 0, FILE_PATH_LITERAL(""),
- GetActiveWebContents(),
parent_window, NULL);
}
« no previous file with comments | « chrome/browser/file_select_helper.cc ('k') | chrome/browser/ui/certificate_dialogs.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698