| Index: ui/file_manager/file_manager/background/js/file_operation_manager.js
|
| diff --git a/ui/file_manager/file_manager/background/js/file_operation_manager.js b/ui/file_manager/file_manager/background/js/file_operation_manager.js
|
| index ad6ccc28e6f60d25869249915566c597c0413ed7..88be24d7e45f5c93497b30b0a23237f774018870 100644
|
| --- a/ui/file_manager/file_manager/background/js/file_operation_manager.js
|
| +++ b/ui/file_manager/file_manager/background/js/file_operation_manager.js
|
| @@ -261,7 +261,7 @@ fileOperationUtil.copyTo = function(
|
| break;
|
|
|
| case 'success':
|
| - chrome.fileBrowserPrivate.onCopyProgress.removeListener(
|
| + chrome.fileManagerPrivate.onCopyProgress.removeListener(
|
| onCopyProgress);
|
| // TODO(mtomasz): Convert URL to Entry in custom bindings.
|
| util.URLsToEntries(
|
| @@ -272,7 +272,7 @@ fileOperationUtil.copyTo = function(
|
| break;
|
|
|
| case 'error':
|
| - chrome.fileBrowserPrivate.onCopyProgress.removeListener(
|
| + chrome.fileManagerPrivate.onCopyProgress.removeListener(
|
| onCopyProgress);
|
| errorCallback(util.createDOMError(status.error));
|
| callback();
|
| @@ -281,9 +281,9 @@ fileOperationUtil.copyTo = function(
|
| default:
|
| // Found unknown state. Cancel the task, and return an error.
|
| console.error('Unknown progress type: ' + status.type);
|
| - chrome.fileBrowserPrivate.onCopyProgress.removeListener(
|
| + chrome.fileManagerPrivate.onCopyProgress.removeListener(
|
| onCopyProgress);
|
| - chrome.fileBrowserPrivate.cancelCopy(copyId);
|
| + chrome.fileManagerPrivate.cancelCopy(copyId);
|
| errorCallback(util.createDOMError(
|
| util.FileError.INVALID_STATE_ERR));
|
| callback();
|
| @@ -293,16 +293,16 @@ fileOperationUtil.copyTo = function(
|
|
|
| // Register the listener before calling startCopy. Otherwise some events
|
| // would be lost.
|
| - chrome.fileBrowserPrivate.onCopyProgress.addListener(onCopyProgress);
|
| + chrome.fileManagerPrivate.onCopyProgress.addListener(onCopyProgress);
|
|
|
| // Then starts the copy.
|
| // TODO(mtomasz): Convert URL to Entry in custom bindings.
|
| - chrome.fileBrowserPrivate.startCopy(
|
| + chrome.fileManagerPrivate.startCopy(
|
| source.toURL(), parent.toURL(), newName, function(startCopyId) {
|
| // last error contains the FileError code on error.
|
| if (chrome.runtime.lastError) {
|
| // Unsubscribe the progress listener.
|
| - chrome.fileBrowserPrivate.onCopyProgress.removeListener(
|
| + chrome.fileManagerPrivate.onCopyProgress.removeListener(
|
| onCopyProgress);
|
| errorCallback(util.createDOMError(chrome.runtime.lastError));
|
| return;
|
| @@ -318,17 +318,17 @@ fileOperationUtil.copyTo = function(
|
| // If copyId is not yet available, wait for it.
|
| if (copyId == null) {
|
| pendingCallbacks.push(function() {
|
| - chrome.fileBrowserPrivate.cancelCopy(copyId);
|
| + chrome.fileManagerPrivate.cancelCopy(copyId);
|
| });
|
| return;
|
| }
|
|
|
| - chrome.fileBrowserPrivate.cancelCopy(copyId);
|
| + chrome.fileManagerPrivate.cancelCopy(copyId);
|
| };
|
| };
|
|
|
| /**
|
| - * Thin wrapper of chrome.fileBrowserPrivate.zipSelection to adapt its
|
| + * Thin wrapper of chrome.fileManagerPrivate.zipSelection to adapt its
|
| * interface similar to copyTo().
|
| *
|
| * @param {Array.<Entry>} sources The array of entries to be archived.
|
| @@ -343,7 +343,7 @@ fileOperationUtil.zipSelection = function(
|
| sources, parent, newName, successCallback, errorCallback) {
|
| // TODO(mtomasz): Pass Entries instead of URLs. Entries can be converted to
|
| // URLs in custom bindings.
|
| - chrome.fileBrowserPrivate.zipSelection(
|
| + chrome.fileManagerPrivate.zipSelection(
|
| parent.toURL(),
|
| util.entriesToURLs(sources),
|
| newName, function(success) {
|
|
|