Index: chrome/browser/resources/file_manager/js/main.js |
=================================================================== |
--- chrome/browser/resources/file_manager/js/main.js (revision 95624) |
+++ chrome/browser/resources/file_manager/js/main.js (working copy) |
@@ -13,11 +13,19 @@ |
* Called by main.html after the dom has been parsed. |
*/ |
function init() { |
+ var params; |
+ |
var rootPaths = ['Downloads', 'removable', 'archive', 'tmp']; |
+ if (document.location.search) { |
+ var json = decodeURIComponent(document.location.search.substr(1)); |
+ var params = JSON.parse(json); |
+ console.log('params: ' + JSON.stringify(params)); |
+ } |
+ |
function onEntriesFound(filesystem, entries) { |
FileManager.initStrings(function () { |
- fileManager = new FileManager(document.body, filesystem, entries); |
+ fileManager = new FileManager(document.body, filesystem, entries, params); |
// We're ready to run. Tests can monitor for this state with |
// ExtensionTestMessageListener listener("ready"); |
// ASSERT_TRUE(listener.WaitUntilSatisfied()); |