1.20.x installer.theme.inc template_preprocess_installer_browser_install_queue(&$variables)

Add some variables for the projects install queue theme.

File

modules/installer/installer.theme.inc, line 23
Project Installer theme pages.

Code

function template_preprocess_installer_browser_install_queue(&$variables) {
  $build = array();
  if (empty($variables['projects'])) {
    $build['empty_text'] = array(
      '#markup' => t('Installation queue is empty.'),
    );
  }
  else {
    foreach ($variables['projects'] as $project) {
      $build['queued-item-' . $project['name']] = array(
        '#prefix' => "<div class='installer-browser-install-queue-item'>",
        '#markup' => installer_browser_add_remove_queue_link($project['name'], $project['title'], 'remove-queue-link'),
        '#suffix' => "</div>",
      );
    }
    $build['install-link'] = backdrop_get_form('installer_browser_install_button_form');
  }

  // Add the install button.
  $variables['queue_html'] = backdrop_render($build);
}