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

Unified Diff: chrome/browser/resources/file_manager/js/file_tasks.js

Issue 14982007: Merge 199417 "Remove internal handlers from the Files.app's UI." (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1500/src/
Patch Set: Created 7 years, 7 months 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/file_manager/js/file_tasks.js
===================================================================
--- chrome/browser/resources/file_manager/js/file_tasks.js (revision 199670)
+++ chrome/browser/resources/file_manager/js/file_tasks.js (working copy)
@@ -137,13 +137,19 @@
for (var i = 0; i < tasks.length; i++) {
var task = tasks[i];
+ var taskParts = task.taskId.split('|');
// Skip Drive App if the file is not on Drive.
if (!isOnDrive && task.driveApp)
continue;
+ // Skip internal Files.app's handlers.
+ if (taskParts[0] == id && (taskParts[2] == 'auto-open' ||
+ taskParts[2] == 'select' || taskParts[2] == 'open')) {
+ continue;
+ }
+
// Tweak images, titles of internal tasks.
- var taskParts = task.taskId.split('|');
if (taskParts[0] == id && taskParts[1] == 'file') {
if (taskParts[2] == 'play') {
// TODO(serya): This hack needed until task.iconUrl is working
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698