spaces_test.module in Spaces 7        
                          
                  
                        
  
  
  
File
  tests/spaces_test.module
  
    View source  
  <?php
include_once 'spaces_test.features.inc';
function spaces_test_system_info_alter(&$info, $file, $type) {
  if ($file->name == 'features_test') {
    $info['spaces']['types'][] = 'all';
  }
}
function spaces_test_menu() {
  $items = array();
  $items['features/features_test'] = array(
    'title' => 'Settings',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'spaces_test_admin_form',
    ),
    'access callback' => 'spaces_access_admin_perms',
    'access arguments' => array(
      array(
        'administer site configuration',
      ),
    ),
    'type' => MENU_NORMAL_ITEM,
  );
  return $items;
}
function spaces_test_admin_form($form, &$form_state) {
  $form['features_test_setting'] = array(
    '#type' => 'checkbox',
    '#title' => t('Customized'),
    '#default_value' => variable_get('features_test_setting', FALSE),
  );
  return system_settings_form($form);
}