diff options
author | zelidrag@chromium.org <zelidrag@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-04-16 09:24:14 +0000 |
---|---|---|
committer | zelidrag@chromium.org <zelidrag@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-04-16 09:24:14 +0000 |
commit | b6b805e9a9116fe454e11e652e5e8b3caac08c6b (patch) | |
tree | 0d71d800e2682649249b864796a157754fb6222d /chrome/browser/extensions/extension_local_filesystem_apitest.cc | |
parent | fad613288e2dd25496cb7d8be90566bdbb76f8ec (diff) | |
download | chromium_src-b6b805e9a9116fe454e11e652e5e8b3caac08c6b.zip chromium_src-b6b805e9a9116fe454e11e652e5e8b3caac08c6b.tar.gz chromium_src-b6b805e9a9116fe454e11e652e5e8b3caac08c6b.tar.bz2 |
New fileBrowserPrivate and fileHandler APIs added + plus magic needed to safely hand over access to local file system elements from content extension to 3rd party extension.
As agreed with aa@ and asargent@, this new API defines following event:
chrome.fileHandler.onExecute.addListener(function(id, file_entries) {
}
This event is invoked when user selects files in ChromeOS file browser.
The extension needs to register itself as file content hanlder with following manifest changes:
...
"file_browser_actions": [
{
"id" : "ActionIdentifier",
"default_title" : "Action title",
"default_icon" : "icon.png",
"file_filters" : [ "filesystem:*.jpeg", ... ]
}
...
],
...
BUG=chromium-os:11996
TEST=ExtensionApiTest.FileBrowserTest, ExtensionManifestTest.FileBrowserActions
Review URL: http://codereview.chromium.org/6749021
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81869 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/extension_local_filesystem_apitest.cc')
-rw-r--r-- | chrome/browser/extensions/extension_local_filesystem_apitest.cc | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/chrome/browser/extensions/extension_local_filesystem_apitest.cc b/chrome/browser/extensions/extension_local_filesystem_apitest.cc index 5a8ba72..856cbb4 100644 --- a/chrome/browser/extensions/extension_local_filesystem_apitest.cc +++ b/chrome/browser/extensions/extension_local_filesystem_apitest.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2010 The Chromium Authors. All rights reserved. +// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -6,9 +6,13 @@ #if defined(OS_CHROMEOS) -// TODO(zelidrag): Remove disable prefix on this test once API changes land. -IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_LocalFileSystem) { +IN_PROC_BROWSER_TEST_F(ExtensionApiTest, LocalFileSystem) { ASSERT_TRUE(RunComponentExtensionTest("local_filesystem")) << message_; } +IN_PROC_BROWSER_TEST_F(ExtensionApiTest, FileBrowserTest) { + ASSERT_TRUE(RunExtensionTest("filesystem_handler")) << message_; + ASSERT_TRUE(RunComponentExtensionTest("filebrowser_component")) << message_; +} + #endif |