uw_virtual_site_homepage.features.inc 3.45 KB
Newer Older
1
<?php
Liam Morland's avatar
Liam Morland committed
2

3 4 5 6 7 8 9 10 11
/**
 * @file
 * uw_virtual_site_homepage.features.inc
 */

/**
 * Implements hook_ctools_plugin_api().
 */
function uw_virtual_site_homepage_ctools_plugin_api($module = NULL, $api = NULL) {
12 13 14
  if ($module == "field_group" && $api == "field_group") {
    return array("version" => "1");
  }
15 16 17 18 19 20 21 22 23 24 25 26
  if ($module == "strongarm" && $api == "strongarm") {
    return array("version" => "1");
  }
}

/**
 * Implements hook_views_api().
 */
function uw_virtual_site_homepage_views_api($module = NULL, $api = NULL) {
  return array("api" => "3.0");
}

27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59
/**
 * Implements hook_image_default_styles().
 */
function uw_virtual_site_homepage_image_default_styles() {
  $styles = array();

  // Exported image style: uw_homepage_banners.
  $styles['uw_homepage_banners'] = array(
    'label' => 'Homepage banners',
    'effects' => array(
      5 => array(
        'name' => 'focal_point_scale_and_crop',
        'data' => array(
          'width' => 380,
          'height' => 320,
          'focal_point_advanced' => array(
            'shift_x' => '',
            'shift_y' => '',
          ),
        ),
        'weight' => 1,
      ),
    ),
  );

  // Exported image style: uw_homepage_banners_large.
  $styles['uw_homepage_banners_large'] = array(
    'label' => 'Homepage banners large',
    'effects' => array(
      3 => array(
        'name' => 'focal_point_scale_and_crop',
        'data' => array(
          'width' => 1000,
60
          'height' => 400,
61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97
          'focal_point_advanced' => array(
            'shift_x' => '',
            'shift_y' => '',
          ),
        ),
        'weight' => 1,
      ),
    ),
  );

  // Exported image style: uw_homepage_banners_medium.
  $styles['uw_homepage_banners_medium'] = array(
    'label' => 'Homepage banners medium',
    'effects' => array(
      2 => array(
        'name' => 'focal_point_scale_and_crop',
        'data' => array(
          'width' => 800,
          'height' => 400,
          'focal_point_advanced' => array(
            'shift_x' => '',
            'shift_y' => '',
          ),
        ),
        'weight' => 1,
      ),
    ),
  );

  // Exported image style: uw_homepage_banners_small.
  $styles['uw_homepage_banners_small'] = array(
    'label' => 'Homepage banners small',
    'effects' => array(
      1 => array(
        'name' => 'focal_point_scale_and_crop',
        'data' => array(
          'width' => 480,
98
          'height' => 400,
99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116
          'focal_point_advanced' => array(
            'shift_x' => '',
            'shift_y' => '',
          ),
        ),
        'weight' => 1,
      ),
    ),
  );

  // Exported image style: uw_homepage_banners_xl.
  $styles['uw_homepage_banners_xl'] = array(
    'label' => 'Homepage banners xl',
    'effects' => array(
      4 => array(
        'name' => 'focal_point_scale_and_crop',
        'data' => array(
          'width' => 1600,
117
          'height' => 400,
118 119 120 121 122 123 124 125 126 127 128 129 130
          'focal_point_advanced' => array(
            'shift_x' => '',
            'shift_y' => '',
          ),
        ),
        'weight' => 1,
      ),
    ),
  );

  return $styles;
}

131 132 133 134 135 136 137 138 139 140 141 142 143 144
/**
 * Implements hook_node_info().
 */
function uw_virtual_site_homepage_node_info() {
  $items = array(
    'uw_virtual_site_homepage' => array(
      'name' => t('UW Virtual Site Homepage'),
      'base' => 'node_content',
      'description' => t('University of Waterloo\'s Virtual Site homepage.'),
      'has_title' => '1',
      'title_label' => t('Title'),
      'help' => '',
    ),
  );
145
  drupal_alter('node_info', $items);
146 147
  return $items;
}