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

Unified Diff: ui/aura/remote_root_window_host_win.h

Issue 14282002: Added support for displaying the select folder picker in Chrome ASH on Windows 8. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 7 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 | « no previous file | ui/aura/remote_root_window_host_win.cc » ('j') | ui/aura/remote_root_window_host_win.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/remote_root_window_host_win.h
===================================================================
--- ui/aura/remote_root_window_host_win.h (revision 194196)
+++ ui/aura/remote_root_window_host_win.h (working copy)
@@ -38,6 +38,9 @@
typedef base::Callback<void(const base::FilePath&, int, void*)>
SaveFileCompletion;
+typedef base::Callback<void(const base::FilePath&, int, void*)>
+ SelectFolderCompletion;
+
// Handles the open file operation for Metro Chrome Ash. The callback passed in
// is invoked when we receive the opened file name from the metro viewer.
AURA_EXPORT void HandleOpenFile(
@@ -65,6 +68,10 @@
const string16& default_extension,
const SaveFileCompletion& callback);
+// Handles the select folder for Metro Chrome Ash. The callback passed in
+// is invoked when we receive the folder name from the metro viewer.
+AURA_EXPORT void HandleSelectFolder(const string16& title,
+ const SelectFolderCompletion& callback);
// RootWindowHost implementaton that receives events from a different
// process. In the case of Windows this is the Windows 8 (aka Metro)
@@ -103,6 +110,9 @@
const string16& default_extension,
const SaveFileCompletion& callback);
+ void HandleSelectFolder(const string16& title,
+ const SelectFolderCompletion& callback);
+
private:
explicit RemoteRootWindowHostWin(const gfx::Rect& bounds);
virtual ~RemoteRootWindowHostWin();
@@ -136,7 +146,7 @@
void OnFileOpenDone(bool success, string16 filename);
void OnMultiFileOpenDone(bool success,
const std::vector<base::FilePath>& files);
-
+ void OnSelectFolderDone(bool success, const string16& folder);
// RootWindowHost overrides:
virtual void SetDelegate(RootWindowHostDelegate* delegate) OVERRIDE;
virtual RootWindow* GetRootWindow() OVERRIDE;
@@ -185,10 +195,11 @@
scoped_ptr<ui::ViewProp> prop_;
// Saved callbacks which inform the caller about the result of the open file/
- // save file operations.
+ // save file/select operations.
OpenFileCompletion file_open_completion_callback_;
OpenMultipleFilesCompletion multi_file_open_completion_callback_;
SaveFileCompletion file_saveas_completion_callback_;
+ SelectFolderCompletion select_folder_completion_callback_;
DISALLOW_COPY_AND_ASSIGN(RemoteRootWindowHostWin);
};
« no previous file with comments | « no previous file | ui/aura/remote_root_window_host_win.cc » ('j') | ui/aura/remote_root_window_host_win.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698