-
Notifications
You must be signed in to change notification settings - Fork 0
/
portfolio.features.inc
82 lines (76 loc) · 2.25 KB
/
portfolio.features.inc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
<?php
/**
* @file
* portfolio.features.inc
*/
/**
* Implements hook_views_api().
*/
function portfolio_views_api() {
return array('api' => '3.0');
}
/**
* Implements hook_image_default_styles().
*/
function portfolio_image_default_styles() {
$styles = array();
// Exported image style: portfolio-full.
$styles['portfolio-full'] = array(
'name' => 'portfolio-full',
'effects' => array(
11 => 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' => 980,
'height' => 450,
),
'weight' => 1,
),
),
);
// Exported image style: portfolio-thumb.
$styles['portfolio-thumb'] = array(
'name' => 'portfolio-thumb',
'effects' => array(
14 => 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' => 85,
'height' => 85,
),
'weight' => 1,
),
),
);
return $styles;
}
/**
* Implements hook_node_info().
*/
function portfolio_node_info() {
$items = array(
'portfolio' => array(
'name' => t('Portfolio Item'),
'base' => 'node_content',
'description' => t('Appears in the Gallery'),
'has_title' => '1',
'title_label' => t('Title'),
'help' => '',
),
);
return $items;
}