It would be helpful to have administrative control over drag and drop in the WebFM user interface, i.e., an administrator should be able to turn off the ability to move files and folders from one folder to another in the AJAX code.

At our web site, we're having user interface issues with Internet Explorer that we cannot resolve (files get moved by accident when users click on them), so I would like to disable the functionality since it is not that valuable in our web site.

If such administrative control is not possible, what is the easiest way to disable the functionality by modifying the code? I do not mind have a privately modified version.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

filsterjisah’s picture

subscribing, having the same issue with one of our clients

filsterjisah’s picture

Assigned: Unassigned » filsterjisah
filsterjisah’s picture

Please try this patch. And see webfm settings for "Disable drag and dropping on folders.".

bruc’s picture

Dear Filip,
Thanks. I tried it myself, and it works (actually, it doesn't work, which is what we want :) )

I've asked my users to test it, and I'll let you know if there are any issues.

I really appreciate your help! Thanks again. --Bob

filsterjisah’s picture

Status: Active » Reviewed & tested by the community

You're welcome :)

nhck’s picture

Status: Reviewed & tested by the community » Needs work

As for me this can go in, but a couple of things:
The patch should be against the current master of webfm - you can read on how to create a patch here: https://drupal.org/patch/create

+++ sites/all/modules/contrib/webfm/webfm.admin.incundefined
@@ -67,6 +67,14 @@
+          ¶
+          $form['webfm_setting_disable_drag_and_drop'] = array(
+          	'#type' => 'checkbox',
+            '#title' => t('Disable drag and dropping on folders.'),
+            '#description' => t('Disabled because of sensitive dragging in IE or other reason.'),
+            '#default_value' => variable_get('webfm_setting_disable_drag_and_drop', 0),
+          );
 
           $form['file_perm'] =
           array('#type' => 'fieldset',

I think this should go in the respective settings fieldset.

+++ sites/all/modules/contrib/webfm/webfm.admin.incundefined
@@ -67,6 +67,14 @@
+            '#title' => t('Disable drag and dropping on folders.'),
+            '#description' => t('Disabled because of sensitive dragging in IE or other reason.'),
+            '#default_value' => variable_get('webfm_setting_disable_drag_and_drop', 0),
+          );
 
           $form['file_perm'] =
           array('#type' => 'fieldset',

This has to be a proper explanation. Also it needs to state that this is merely a cosmetic change. Any experienced user can just re-enable it.

bruc’s picture

Do you need me to do anything to finish this patch?

I should say that I'm a newbie to Drupal, and making a patch would take a lot of effort on my part.