OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #include "chrome/renderer/extensions/file_browser_private_bindings.h" | 5 #include "chrome/renderer/extensions/file_browser_private_bindings.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
11 #include "grit/renderer_resources.h" | 11 #include "grit/renderer_resources.h" |
12 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFileSystem.h" | 12 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebFileSyste
m.h" |
13 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" | 13 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" |
14 #include "third_party/WebKit/Source/WebKit/chromium/public/WebString.h" | 14 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h" |
15 | 15 |
16 namespace { | 16 namespace { |
17 | 17 |
18 const char* kDeps[] = { | 18 const char* kDeps[] = { |
19 "extensions/event.js" | 19 "extensions/event.js" |
20 }; | 20 }; |
21 | 21 |
22 static v8::Handle<v8::Value> GetExternalFileEntry(const v8::Arguments& args) { | 22 static v8::Handle<v8::Value> GetExternalFileEntry(const v8::Arguments& args) { |
23 // TODO(zelidrag): Make this magic work on other platforms when file browser | 23 // TODO(zelidrag): Make this magic work on other platforms when file browser |
24 // matures enough on ChromeOS. | 24 // matures enough on ChromeOS. |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 arraysize(kDeps), kDeps, NULL) { | 57 arraysize(kDeps), kDeps, NULL) { |
58 } | 58 } |
59 | 59 |
60 v8::Handle<v8::FunctionTemplate> FileBrowserPrivateBindings::GetNativeFunction( | 60 v8::Handle<v8::FunctionTemplate> FileBrowserPrivateBindings::GetNativeFunction( |
61 v8::Handle<v8::String> name) { | 61 v8::Handle<v8::String> name) { |
62 if (name->Equals(v8::String::New("GetExternalFileEntry"))) | 62 if (name->Equals(v8::String::New("GetExternalFileEntry"))) |
63 return v8::FunctionTemplate::New(GetExternalFileEntry); | 63 return v8::FunctionTemplate::New(GetExternalFileEntry); |
64 else | 64 else |
65 return ChromeV8Extension::GetNativeFunction(name); | 65 return ChromeV8Extension::GetNativeFunction(name); |
66 } | 66 } |
OLD | NEW |