You are here

function cloud_zoom_library in Cloud Zoom 8

Same name and namespace in other branches
  1. 7 cloud_zoom.module \cloud_zoom_library()

Implements hook_library()

File

./cloud_zoom.module, line 28
This module integrates the Cloud Zoom JQuery library from: http://www.professorcloud.com/mainsite/cloud-zoom.htm

Code

function cloud_zoom_library() {
  if ($path = _cloud_zoom_get_path()) {
    $module_path = drupal_get_path('module', 'cloud_zoom');
    $library = _cloud_zoom_check_path($path);
    $library_base = dirname($library->uri);
    return array(
      'cloud-zoom' => array(
        'title' => 'Cloud Zoom',
        'website' => 'http://www.professorcloud.com/mainsite/cloud-zoom.htm',
        'version' => $library->cz_version,
        'js' => array(
          $library->uri => array(
            'group' => JS_LIBRARY,
          ),
          $module_path . '/js/cloud_zoom.js' => array(),
        ),
        'css' => array(
          $library_base . '/cloud-zoom.css' => array(
            'group' => JS_LIBRARY,
          ),
          $module_path . '/css/cloud_zoom.css' => array(),
        ),
        'dependencies' => array(
          array(
            'system',
            'jquery',
          ),
        ),
      ),
    );
  }
  return;
}