You are here

public function TMGMTTestTranslatorUIController::checkoutSettingsForm in Translation Management Tool 7

Form callback for the checkout settings form.

Overrides TMGMTDefaultTranslatorUIController::checkoutSettingsForm

File

tests/tmgmt_test.ui.translator.inc, line 37
Contains the test translator UI plugin.

Class

TMGMTTestTranslatorUIController
@file Contains the test translator UI plugin.

Code

public function checkoutSettingsForm($form, &$form_state, TMGMTJob $job) {
  if ($job
    ->getTranslator()
    ->getSetting('expose_settings')) {
    $form['action'] = array(
      '#type' => 'select',
      '#title' => t('Action'),
      '#options' => array(
        'translate' => t('Translate'),
        'submit' => t('Submit'),
        'reject' => t('Reject'),
        'fail' => t('Fail'),
        'not_translatable' => t('Not translatable'),
      ),
      '#default_value' => $job
        ->getTranslator()
        ->getSetting('action'),
    );
  }
  return $form;
}