summaryrefslogtreecommitdiffstats
path: root/chrome/browser/tab_contents
diff options
context:
space:
mode:
authoravi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-04-06 18:08:34 +0000
committeravi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-04-06 18:08:34 +0000
commit561abe688fc5ebcec902ea6cc2ccb4122441595e (patch)
tree5d5b001676b82c824d22619f0cc3a92b22648ab2 /chrome/browser/tab_contents
parent5ce729688e2b16ebc97decb032175ba230855c1d (diff)
downloadchromium_src-561abe688fc5ebcec902ea6cc2ccb4122441595e.zip
chromium_src-561abe688fc5ebcec902ea6cc2ccb4122441595e.tar.gz
chromium_src-561abe688fc5ebcec902ea6cc2ccb4122441595e.tar.bz2
First pass of refactoring dialogs.
Review URL: http://codereview.chromium.org/60110 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13168 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/tab_contents')
-rw-r--r--chrome/browser/tab_contents/web_contents.cc12
-rw-r--r--chrome/browser/tab_contents/web_contents.h8
2 files changed, 10 insertions, 10 deletions
diff --git a/chrome/browser/tab_contents/web_contents.cc b/chrome/browser/tab_contents/web_contents.cc
index 3ac939a..db87eb9 100644
--- a/chrome/browser/tab_contents/web_contents.cc
+++ b/chrome/browser/tab_contents/web_contents.cc
@@ -1142,8 +1142,8 @@ void WebContents::GetHistoryListCount(int* back_list_count,
}
void WebContents::RunFileChooser(bool multiple_files,
- const std::wstring& title,
- const std::wstring& default_file,
+ const string16& title,
+ const FilePath& default_file,
const std::wstring& filter) {
if (!select_file_dialog_.get())
select_file_dialog_ = SelectFileDialog::Create(this);
@@ -1151,7 +1151,7 @@ void WebContents::RunFileChooser(bool multiple_files,
multiple_files ? SelectFileDialog::SELECT_OPEN_MULTI_FILE :
SelectFileDialog::SELECT_OPEN_FILE;
select_file_dialog_->SelectFile(dialog_type, title, default_file,
- filter, 0, std::wstring(),
+ filter, 0, FILE_PATH_LITERAL(""),
view_->GetTopLevelNativeWindow(), NULL);
}
@@ -1566,12 +1566,12 @@ bool WebContents::CanTerminate() const {
return !delegate()->IsExternalTabContainer();
}
-void WebContents::FileSelected(const std::wstring& path,
+void WebContents::FileSelected(const FilePath& path,
int index, void* params) {
render_view_host()->FileSelected(path);
}
-void WebContents::MultiFilesSelected(const std::vector<std::wstring>& files,
+void WebContents::MultiFilesSelected(const std::vector<FilePath>& files,
void* params) {
render_view_host()->MultiFilesSelected(files);
}
@@ -1579,7 +1579,7 @@ void WebContents::MultiFilesSelected(const std::vector<std::wstring>& files,
void WebContents::FileSelectionCanceled(void* params) {
// If the user cancels choosing a file to upload we pass back an
// empty vector.
- render_view_host()->MultiFilesSelected(std::vector<std::wstring>());
+ render_view_host()->MultiFilesSelected(std::vector<FilePath>());
}
void WebContents::BeforeUnloadFiredFromRenderManager(
diff --git a/chrome/browser/tab_contents/web_contents.h b/chrome/browser/tab_contents/web_contents.h
index ae40d89..7663712 100644
--- a/chrome/browser/tab_contents/web_contents.h
+++ b/chrome/browser/tab_contents/web_contents.h
@@ -369,8 +369,8 @@ class WebContents : public TabContents,
virtual void GetHistoryListCount(int* back_list_count,
int* forward_list_count);
virtual void RunFileChooser(bool multiple_files,
- const std::wstring& title,
- const std::wstring& default_file,
+ const string16& title,
+ const FilePath& default_file,
const std::wstring& filter);
virtual void RunJavaScriptMessage(const std::wstring& message,
const std::wstring& default_prompt,
@@ -432,8 +432,8 @@ class WebContents : public TabContents,
// SelectFileDialog::Listener ------------------------------------------------
- virtual void FileSelected(const std::wstring& path, int index, void* params);
- virtual void MultiFilesSelected(const std::vector<std::wstring>& files,
+ virtual void FileSelected(const FilePath& path, int index, void* params);
+ virtual void MultiFilesSelected(const std::vector<FilePath>& files,
void* params);
virtual void FileSelectionCanceled(void* params);