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

Side by Side Diff: chrome/browser/chromeos/extensions/file_manager/file_browser_handler_api.h

Issue 1870793002: Convert //chrome/browser/chromeos from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: iwyu fixes Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // File contains the fileBrowserHandlerInternal.selectFile extension function. 5 // File contains the fileBrowserHandlerInternal.selectFile extension function.
6 // The function prompts user to select a file path to be used by the caller. It 6 // The function prompts user to select a file path to be used by the caller. It
7 // will fail if it isn't invoked by a user gesture (e.g. a mouse click or a 7 // will fail if it isn't invoked by a user gesture (e.g. a mouse click or a
8 // keyboard key press). 8 // keyboard key press).
9 // Note that the target file is never actually created by this function, even 9 // Note that the target file is never actually created by this function, even
10 // if the selected path doesn't exist. 10 // if the selected path doesn't exist.
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 // * boolean 'success', which will be equal to |success|. 124 // * boolean 'success', which will be equal to |success|.
125 // * object 'entry', which will be set only when |success| is true, and the 125 // * object 'entry', which will be set only when |success| is true, and the
126 // conversion to |entry_definition| was successful. In such case, it will 126 // conversion to |entry_definition| was successful. In such case, it will
127 // contain information needed to create a FileEntry object for the selected 127 // contain information needed to create a FileEntry object for the selected
128 // file. 128 // file.
129 void Respond(const file_manager::util::EntryDefinition& entry_definition, 129 void Respond(const file_manager::util::EntryDefinition& entry_definition,
130 bool success); 130 bool success);
131 131
132 // Factory used to create FileSelector to be used for prompting user to select 132 // Factory used to create FileSelector to be used for prompting user to select
133 // file. 133 // file.
134 scoped_ptr<file_manager::FileSelectorFactory> file_selector_factory_; 134 std::unique_ptr<file_manager::FileSelectorFactory> file_selector_factory_;
135 // Whether user gesture check is disabled. This should be true only in tests. 135 // Whether user gesture check is disabled. This should be true only in tests.
136 bool user_gesture_check_enabled_; 136 bool user_gesture_check_enabled_;
137 137
138 // List of permissions and paths that have to be granted for the selected 138 // List of permissions and paths that have to be granted for the selected
139 // files. 139 // files.
140 std::vector<std::pair<base::FilePath, int> > permissions_to_grant_; 140 std::vector<std::pair<base::FilePath, int> > permissions_to_grant_;
141 141
142 DECLARE_EXTENSION_FUNCTION("fileBrowserHandlerInternal.selectFile", 142 DECLARE_EXTENSION_FUNCTION("fileBrowserHandlerInternal.selectFile",
143 FILEBROWSERHANDLERINTERNAL_SELECTFILE) 143 FILEBROWSERHANDLERINTERNAL_SELECTFILE)
144 }; 144 };
145 145
146 #endif // CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_MANAGER_FILE_BROWSER_HANDLER_ API_H_ 146 #endif // CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_MANAGER_FILE_BROWSER_HANDLER_ API_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698