Commit 2fb510f2 authored by yoshiki@chromium.org's avatar yoshiki@chromium.org

Files.app: FileManager.isFolderShortcutsEnabled()

Folder shortcut is launched, since we no longer need to switch the feature.

BUG=none
TEST=manual
R=hirono@chromium.org

Review URL: https://codereview.chromium.org/24026002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@221647 0039d316-1c4b-4281-b951-d872f2087c98
parent 4823999b
...@@ -2122,18 +2122,6 @@ var BOTTOM_MARGIN_FOR_PREVIEW_PANEL_PX = 52; ...@@ -2122,18 +2122,6 @@ var BOTTOM_MARGIN_FOR_PREVIEW_PANEL_PX = 52;
}.bind(this)); }.bind(this));
}; };
/**
* Folder shared feature is under development and hidden behind flag. This
* method returns if the feature is explicitly enabled by the flag or not.
* TODO(yoshiki): Remove this after launching folder feature feature.
*
* @return {boolena} True if the flag is enabled.
*/
FileManager.prototype.isFolderShortcutsEnabled = function() {
// TODO(yoshiki): Remove this method in M31.
return true;
};
/** /**
* Creates a folder shortcut. * Creates a folder shortcut.
* @param {string} path A shortcut which refers to |path| to be created. * @param {string} path A shortcut which refers to |path| to be created.
......
...@@ -609,10 +609,8 @@ Commands.createFolderShortcutCommand = { ...@@ -609,10 +609,8 @@ Commands.createFolderShortcutCommand = {
*/ */
canExecute: function(event, fileManager) { canExecute: function(event, fileManager) {
var target = event.target; var target = event.target;
// TODO(yoshiki): remove this after launching folder shortcuts feature. if (!target instanceof NavigationListItem &&
if (!fileManager.isFolderShortcutsEnabled() || !target instanceof DirectoryItem) {
(!target instanceof NavigationListItem &&
!target instanceof DirectoryItem)) {
event.command.setHidden(true); event.command.setHidden(true);
return; return;
} }
...@@ -660,10 +658,8 @@ Commands.removeFolderShortcutCommand = { ...@@ -660,10 +658,8 @@ Commands.removeFolderShortcutCommand = {
*/ */
canExecute: function(event, fileManager) { canExecute: function(event, fileManager) {
var target = event.target; var target = event.target;
// TODO(yoshiki): remove this after launching folder shortcut feature. if (!target instanceof NavigationListItem &&
if (!fileManager.isFolderShortcutsEnabled() || !target instanceof DirectoryItem) {
(!target instanceof NavigationListItem &&
!target instanceof DirectoryItem)) {
event.command.setHidden(true); event.command.setHidden(true);
return; return;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment