-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfeatures_profiler.pages.inc
More file actions
46 lines (39 loc) · 1.21 KB
/
features_profiler.pages.inc
File metadata and controls
46 lines (39 loc) · 1.21 KB
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
<?php
function features_profiler_get_components($type = 'supported', $feature = NULL) {
$return = array();
$profiler_components = array();
$enabled_components = array_keys(features_get_components());
sort($enabled_components);
switch ($type) {
case 'supported':
return array_intersect($enabled_components, $profiler_components);
break;
case 'unsupported':
return array_diff($enabled_components, $profiler_components);
break;
}
}
function features_profiler_scribbler() {
$output = '<h2>Features Profiler</h2>';
if ($unsupported = features_profiler_get_components('unsupported')) {
drupal_set_message(
t(
'Features Profiler does not currently support the following enabled components:<br>!components',
array('!components' => implode('<br>', $unsupported))
),
'warning'
);
}
foreach (features_profiler_get_components() as $component) {
$output .= '<h4>'. $component . '</h4>';
}
return $output;
}
function features_profiler_form($form, $form_state, $feature = NULL) {
$form = array();
return $form;
}
function features_profiler_settings_form($form, $form_state, $feature = NULL) {
$form = array();
return $form;
}