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

Side by Side Diff: chrome/browser/chromeos/extensions/file_handler_util.h

Issue 10375021: Move Extension into extensions namespace (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Take 6 Created 8 years, 7 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 #ifndef CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_HANDLER_UTIL_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_HANDLER_UTIL_H_
6 #define CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_HANDLER_UTIL_H_ 6 #define CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_HANDLER_UTIL_H_
7 #pragma once 7 #pragma once
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 GURL target_file_url; 92 GURL target_file_url;
93 FilePath virtual_path; 93 FilePath virtual_path;
94 FilePath absolute_path; 94 FilePath absolute_path;
95 bool is_directory; 95 bool is_directory;
96 }; 96 };
97 97
98 typedef std::vector<FileDefinition> FileDefinitionList; 98 typedef std::vector<FileDefinition> FileDefinitionList;
99 class ExecuteTasksFileSystemCallbackDispatcher; 99 class ExecuteTasksFileSystemCallbackDispatcher;
100 void RequestFileEntryOnFileThread( 100 void RequestFileEntryOnFileThread(
101 const GURL& handler_base_url, 101 const GURL& handler_base_url,
102 const scoped_refptr<const Extension>& handler, 102 const scoped_refptr<const extensions::Extension>& handler,
103 int handler_pid, 103 int handler_pid,
104 const std::vector<GURL>& file_urls); 104 const std::vector<GURL>& file_urls);
105 105
106 void ExecuteFailedOnUIThread(); 106 void ExecuteFailedOnUIThread();
107 void ExecuteFileActionsOnUIThread(const std::string& file_system_name, 107 void ExecuteFileActionsOnUIThread(const std::string& file_system_name,
108 const GURL& file_system_root, 108 const GURL& file_system_root,
109 const FileDefinitionList& file_list, 109 const FileDefinitionList& file_list,
110 int handler_id); 110 int handler_id);
111 void SetupPermissionsAndDispatchEvent(const std::string& file_system_name, 111 void SetupPermissionsAndDispatchEvent(const std::string& file_system_name,
112 const GURL& file_system_root, 112 const GURL& file_system_root,
113 const FileDefinitionList& file_list, 113 const FileDefinitionList& file_list,
114 int handler_pid_in, 114 int handler_pid_in,
115 ExtensionHost* host); 115 ExtensionHost* host);
116 116
117 // Populates |handler_host_permissions| with file path-permissions pairs that 117 // Populates |handler_host_permissions| with file path-permissions pairs that
118 // will be given to the handler extension host process. 118 // will be given to the handler extension host process.
119 void InitHandlerHostFileAccessPermissions( 119 void InitHandlerHostFileAccessPermissions(
120 const FileDefinitionList& file_list, 120 const FileDefinitionList& file_list,
121 const Extension* handler_extension, 121 const extensions::Extension* handler_extension,
122 const std::string& action_id); 122 const std::string& action_id);
123 // Registers file permissions from |handler_host_permissions_| with 123 // Registers file permissions from |handler_host_permissions_| with
124 // ChildProcessSecurityPolicy for process with id |handler_pid|. 124 // ChildProcessSecurityPolicy for process with id |handler_pid|.
125 void SetupHandlerHostFileAccessPermissions(int handler_pid); 125 void SetupHandlerHostFileAccessPermissions(int handler_pid);
126 126
127 Profile* profile_; 127 Profile* profile_;
128 const GURL source_url_; 128 const GURL source_url_;
129 const std::string extension_id_; 129 const std::string extension_id_;
130 const std::string action_id_; 130 const std::string action_id_;
131 131
132 // (File path, permission for file path) pairs for the handler. 132 // (File path, permission for file path) pairs for the handler.
133 std::vector<std::pair<FilePath, int> > handler_host_permissions_; 133 std::vector<std::pair<FilePath, int> > handler_host_permissions_;
134 }; 134 };
135 135
136 } // namespace file_handler_util 136 } // namespace file_handler_util
137 137
138 #endif // CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_HANDLER_UTIL_H_ 138 #endif // CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_HANDLER_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698