web/drupal/modules/imce/imce.install
author cavaliet@caf4f556-3d62-0410-8435-a86758001935
Fri, 21 Aug 2009 16:26:26 +0000
branchdrupal
changeset 74 0ff3ba646492
permissions -rw-r--r--
Create branch for drupal with first commit from local working copy

<?php
// $Id: imce.install,v 1.2.2.2 2008/04/17 23:38:24 ufku Exp $

/**
 * Implementation of hook_install().
 */
function imce_install() {
  include_once './'. drupal_get_path('module', 'imce') .'/inc/core_profiles.inc';
  imce_install_profiles();
}

/**
 * Implementation of hook_uninstall().
 */
function imce_uninstall() {
  variable_del('imce_profiles');
  variable_del('imce_roles_profiles');
  variable_del('imce_settings_textarea');
  variable_del('imce_settings_absurl');
  variable_del('imce_settings_replace');
  variable_del('imce_custom_content');
  variable_del('imce_custom_process');
  variable_del('imce_custom_scan');
}

/**
 * Update from 5.x to 6.x.
 */
function imce_update_6000() {
  imce_install();
  return array();
}

/**
 * New option: total user quota.
 */
function imce_update_6001() {
  $profiles = variable_get('imce_profiles', array());
  foreach ($profiles as $id => $profile) {
    $profiles[$id]['tuquota'] = 0;
  }
  variable_set('imce_profiles', $profiles);
  return array();
}