You are here

function wysiwyg_features_export in Wysiwyg 7.2

Implements hook_features_export().

File

./wysiwyg.features.inc, line 24

Code

function wysiwyg_features_export($data, &$export, $module_name = '') {
  $pipe = array();

  // The wysiwyg_default_formats() hook integration is provided by the
  // features module so we need to add it as a dependency.
  $export['dependencies']['features'] = 'features';
  $export['dependencies']['wysiwyg'] = 'wysiwyg';
  foreach ($data as $name) {
    if ($profile = wysiwyg_get_profile($name)) {

      // Add profile to exports.
      $export['features']['wysiwyg'][$profile->format] = $profile->format;

      // Chain filter format for export.
      $pipe['filter'][] = $profile->format;
    }
  }
  return $pipe;
}