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

Unified Diff: ui/file_manager/file_manager/common/js/util.js

Issue 824003004: Add type annotations to metadata_dispatcher.js. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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 side-by-side diff with in-line comments
Download patch
Index: ui/file_manager/file_manager/common/js/util.js
diff --git a/ui/file_manager/file_manager/common/js/util.js b/ui/file_manager/file_manager/common/js/util.js
index 9d97701a8ab0b49021ad741c585893442278e051..29c7465576031f0f44cbff4c5cc5afc2160eba34 100644
--- a/ui/file_manager/file_manager/common/js/util.js
+++ b/ui/file_manager/file_manager/common/js/util.js
@@ -200,26 +200,6 @@ util.bytesToString = function(bytes) {
};
/**
- * Utility function to read specified range of bytes from file
- * @param {File} file The file to read.
- * @param {number} begin Starting byte(included).
- * @param {number} end Last byte(excluded).
- * @param {function(File, ByteReader)} callback Callback to invoke.
- * @param {function(string)} onError Error handler.
- */
-util.readFileBytes = function(file, begin, end, callback, onError) {
- var fileReader = new FileReader();
- fileReader.onerror = function(event) {
- onError(event.type);
- };
- fileReader.onloadend = function() {
- callback(file, new ByteReader(
- /** @type {ArrayBuffer} */ (fileReader.result)));
- };
- fileReader.readAsArrayBuffer(file.slice(begin, end));
-};
-
-/**
* Returns a string '[Ctrl-][Alt-][Shift-][Meta-]' depending on the event
* modifiers. Convenient for writing out conditions in keyboard handlers.
*
« no previous file with comments | « ui/file_manager/externs/platform_worker.js ('k') | ui/file_manager/file_manager/foreground/js/metadata/compiled_resources.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698