# This patch file was generated by NetBeans IDE
# This patch can be applied using context Tools: Apply Diff Patch action on respective folder.
# It uses platform neutral UTF-8 encoding.
# Above lines and this line are ignored by the patching process.
Index: contributions/modules/ffmpeg_converter/ffmpeg_converter.install
--- contributions/modules/ffmpeg_converter/ffmpeg_converter.install Base (1.2)
+++ contributions/modules/ffmpeg_converter/ffmpeg_converter.install Locally Modified (Based On 1.2)
@@ -56,6 +56,54 @@
 }
 
 /**
+ * Implementation of hook_requirements.
+ */
+function ffmpeg_converter_requirements($phase) {
+  $requirements = array();
+  // Ensure translations don't break at install time
+  $t = get_t();
+
+  if ($phase == 'runtime') {
+    // Check Ctools API version.
+    if (!module_invoke('ctools', 'api_version', FFMPEG_CONVERTER_REQUIRED_CTOOLS_API)) {
+      $requirements['ffmpeg_converter_ctools'] = array(
+        'title' => $t('FFmpeg Converter Ctools dependency'),
+        'value' => $t('The Ctools API is below version 1.7. Please update Ctools.'),
+        'severity' => REQUIREMENT_WARNING,
+      );
+    }
+    else {
+      $requirements['ffmpeg_converter_ctools'] = array(
+        'title' => $t('FFmpeg Converter Ctools dependency'),
+        'value' => $t('The Ctools API is version 1.7 or higher.'),
+        'severity' => REQUIREMENT_OK,
+      );
+    }
+
+    // Check recommended modules.
+    $requirements['ffmpeg_converter_recommended'] = array(
+      'title' => $t('FFmpeg Converter recommended modules'),
+      'value' => $t('All recommended modules are available.'),
+      'severity' => REQUIREMENT_OK
+    );
+    $rec_missing = array();
+    foreach (array('job_queue' => $t('Job Queue'), 'rules' => $t('Rules')) as $key => $name) {
+      if (!module_exists($key)) {
+        $rec_missing[] = $name;
+      }
+    }
+    $rec_missing = join(', ', $rec_missing);
+    if (!empty($rec_missing)) {
+      $requirements['ffmpeg_converter_recommended']['value'] = $t('Missing modules: %modules', array('%modules' => $rec_missing));
+      $requirements['ffmpeg_converter_recommended']['description'] = $t('Some modules that FFmpeg Converter integrates with are unavailable. The built-in conversion functionality will not be available, but other modules may still use FFmpeg Converter as a conversion back end.');
+      $requirements['ffmpeg_converter_recommended']['severity'] = REQUIREMENT_INFO;
+    }
+  }
+
+  return $requirements;
+}
+
+/**
  * Implementation of hook_install().
  */
 function ffmpeg_converter_install() {
