--- attachment.module	Thu Aug 02 12:37:32 2007
+++ attachment.module	Thu Jan 03 16:42:29 2008
@@ -191,13 +191,23 @@
     '#type' => 'fieldset',
     '#title' => t('Security settings')
   );
-  $form['security']['attachment_private_files'] = array(
+  $form['security']['attachment_filemanager_force_private'] = array(
     '#type' => 'checkbox',
     '#title' => t('Private files'),
-    '#default_value' => variable_get('attachment_private_files', 0),
+    '#default_value' => variable_get('attachment_filemanager_force_private', 0),
     '#return_value' => 1,
     '#description' => t('If checked attachments will be streamed through the private directory and node access security will be enforced.  When unchecked public URLs can be accessed by anyone with the URL regardless if they are logged in or have access to that node.  There is a server load impact to using private files.  Changes to this setting only affect new attachments it will not update any existing attachments.')
   );
+  $form['security']['attachment_filemanager_area_limit'] = array(
+    '#type' => 'textfield',
+    '#title' => t('Maximum size limit (MB)'),
+    '#default_value' => variable_get('attachment_filemanager_area_limit', '400'),
+    '#size' => 6,
+    '#maxlength' => 6,
+    '#description' => t('Maximum amount of disk space that can be consumed by this module. Unlimited => -1.'),
+    '#requred' => true
+  );
+  
   $form['security']['attachment_text_rename_whitelist'] = array(
     '#type' => 'textarea',
     '#title' => t('File extension whitelist'),
@@ -212,7 +222,15 @@
  * Implementation of hook_file_areas()
  */
 function attachment_filemanager_areas() {
-  return array(array('area'=>'attachments','name'=>t('Attachments'),'description'=>t('Area where all node attachments are stored.')));
+  return array(
+    array(
+      'area' => 'attachments',
+      'description' => t('Area where all node attachments are stored.'),
+      'module' => 'attachment',
+      'name' => t('Attachments'),
+      'area settings' => 'admin/settings/attachment'
+    )
+  );
 }
 
 /**
--- attachment.install	Tue Jul 17 14:50:04 2007
+++ attachment.install	Thu Jan 03 16:53:58 2008
@@ -66,4 +66,7 @@
   foreach ($nodetypes as $type => $v) {
     variable_del('attachment_node_'. $type);
   }
+  // Cleanup filemanager variables
+  variable_del('attachment_filemanager_area_limit');
+  variable_del('attachment_filemanager_force_private');
 }
