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

Unified Diff: chrome/browser/resources/file_manager/js/image_editor/gallery.js

Issue 10387152: [filemanager] In Gallery, do not allow to rename files in readonly directory. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 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/image_editor/gallery.js
===================================================================
--- chrome/browser/resources/file_manager/js/image_editor/gallery.js (revision 137429)
+++ chrome/browser/resources/file_manager/js/image_editor/gallery.js (working copy)
@@ -485,6 +485,10 @@
};
Gallery.prototype.onFilenameClick_ = function() {
+ // We can't rename files in readonly directory.
+ if (this.context_.readonlyDirName)
+ return;
+
ImageUtil.setAttribute(this.filenameSpacer_, 'renaming', true);
setTimeout(this.filenameEdit_.select.bind(this.filenameEdit_), 0);
this.cancelFading_();
« 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