
Update commons modules to release 7.12, and move the codebase under modules/commons instead of constant fetching from remote repository. The commons.make file removed so it is not required to rebuild groups distribution. Change-Id: I3be393ba1af34427e2915b18ab1ad718fd4e54db
94 lines
2.5 KiB
PHP
94 lines
2.5 KiB
PHP
<?php
|
|
/**
|
|
* @file
|
|
* commons_groups.features.inc
|
|
*/
|
|
|
|
/**
|
|
* Implements hook_ctools_plugin_api().
|
|
*/
|
|
function commons_groups_ctools_plugin_api($module = NULL, $api = NULL) {
|
|
if ($module == "strongarm" && $api == "strongarm") {
|
|
return array("version" => "1");
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Implements hook_views_api().
|
|
*/
|
|
function commons_groups_views_api($module = NULL, $api = NULL) {
|
|
return array("api" => "3.0");
|
|
}
|
|
|
|
/**
|
|
* Implements hook_image_default_styles().
|
|
*/
|
|
function commons_groups_image_default_styles() {
|
|
$styles = array();
|
|
|
|
// Exported image style: 35x35.
|
|
$styles['35x35'] = array(
|
|
'label' => '35x35',
|
|
'name' => '35x35',
|
|
'effects' => array(
|
|
1 => array(
|
|
'label' => 'Scale and crop',
|
|
'help' => 'Scale and crop will maintain the aspect-ratio of the original image, then crop the larger dimension. This is most useful for creating perfectly square thumbnails without stretching the image.',
|
|
'effect callback' => 'image_scale_and_crop_effect',
|
|
'dimensions callback' => 'image_resize_dimensions',
|
|
'form callback' => 'image_resize_form',
|
|
'summary theme' => 'image_resize_summary',
|
|
'module' => 'image',
|
|
'name' => 'image_scale_and_crop',
|
|
'data' => array(
|
|
'width' => 35,
|
|
'height' => 35,
|
|
),
|
|
'weight' => 1,
|
|
),
|
|
),
|
|
);
|
|
|
|
// Exported image style: 50x50.
|
|
$styles['50x50'] = array(
|
|
'label' => '50x50',
|
|
'name' => '50x50',
|
|
'effects' => array(
|
|
2 => array(
|
|
'label' => 'Scale and crop',
|
|
'help' => 'Scale and crop will maintain the aspect-ratio of the original image, then crop the larger dimension. This is most useful for creating perfectly square thumbnails without stretching the image.',
|
|
'effect callback' => 'image_scale_and_crop_effect',
|
|
'dimensions callback' => 'image_resize_dimensions',
|
|
'form callback' => 'image_resize_form',
|
|
'summary theme' => 'image_resize_summary',
|
|
'module' => 'image',
|
|
'name' => 'image_scale_and_crop',
|
|
'data' => array(
|
|
'width' => 50,
|
|
'height' => 50,
|
|
),
|
|
'weight' => 1,
|
|
),
|
|
),
|
|
);
|
|
|
|
return $styles;
|
|
}
|
|
|
|
/**
|
|
* Implements hook_node_info().
|
|
*/
|
|
function commons_groups_node_info() {
|
|
$items = array(
|
|
'group' => array(
|
|
'name' => t('Group'),
|
|
'base' => 'node_content',
|
|
'description' => t('Use groups to contain people and content related by a shared interest or purpose.'),
|
|
'has_title' => '1',
|
|
'title_label' => t('Group name'),
|
|
'help' => '',
|
|
),
|
|
);
|
|
return $items;
|
|
}
|