Revision 90fe4c79
Added by Andreas Kohlbecker over 7 years ago
modules/cdm_dataportal/theme/cdm_dataportal.media.theme | ||
---|---|---|
109 | 109 |
return $out; |
110 | 110 |
} |
111 | 111 |
|
112 |
|
|
112 | 113 |
/** |
113 |
* @todo Please document this function. |
|
114 |
* @see http://drupal.org/node/1354 |
|
114 |
* Creates the markup for a CDM Media instance. |
|
115 |
* |
|
116 |
* (This method is currently only called from within theme_cdm_media()) |
|
117 |
* |
|
118 |
* @param $variables |
|
119 |
* An associative array |
|
120 |
* @return string |
|
121 |
* The markup |
|
115 | 122 |
*/ |
116 | 123 |
function theme_cdm_media_mime_image($variables) { |
117 |
$mediaRepresentation = $variables['mediaRepresentation'];
|
|
124 |
$media_representation = $variables['mediaRepresentation'];
|
|
118 | 125 |
$feature = $variables['feature']; |
119 | 126 |
$out = ''; |
120 | 127 |
// TODO thickbox is not used anymore -> delete? |
121 | 128 |
$attributes = array( |
122 | 129 |
'class' => 'thickbox', |
123 |
'rel' => 'representation-' . $representation->uuid, |
|
130 |
'rel' => 'representation-' . $media_representation->uuid,
|
|
124 | 131 |
'title' => $feature->representation_L10n, |
125 | 132 |
); |
126 |
for ($i = 0; $part = $representation->representationParts[$i]; $i++) {
|
|
133 |
for ($i = 0; $part = $media_representation->parts[$i]; $i++) {
|
|
127 | 134 |
if ($i == 0) { |
128 | 135 |
$out .= l(media_feature_icon($feature, $part->uri), $part->uri, array( |
129 | 136 |
'attributes' => $attributes, |
Also available in: Unified diff
fix #5918