You are here

function views_slideshow_xtra_overlay_plugin_style_overlay::options_validate in Views Slideshow Xtra 7.3

Same name and namespace in other branches
  1. 8.4 modules/views_slideshow_overlay/views_slideshow_overlay_plugin_style_overlay.inc \views_slideshow_xtra_overlay_plugin_style_overlay::options_validate()

Validate the options form.

Overrides views_plugin_style::options_validate

File

views_slideshow_xtra_overlay/views_slideshow_xtra_overlay_plugin_style_overlay.inc, line 71
Contains the list style plugin.

Class

views_slideshow_xtra_overlay_plugin_style_overlay
Style plugin to render each item of the xtra overlay.

Code

function options_validate(&$form, &$form_state) {
  if (!is_numeric($form_state['values']['style_options']['overlay_delay'])) {
    form_error($form['overlay_delay'], t('!setting must be numeric!', array(
      'Overlay Delay',
    )));
  }
  if (!is_numeric($form_state['values']['style_options']['overlay_fade_in'])) {
    form_error($form['overlay_fade_in'], t('!setting must be numeric!', array(
      'Overlay Fade In',
    )));
  }
  if (!is_numeric($form_state['values']['style_options']['overlay_fade_out'])) {
    form_error($form['overlay_fade_out'], t('!setting must be numeric!', array(
      'Overlay Fade Out',
    )));
  }
  if (!is_numeric($form_state['values']['style_options']['overlay_fade_out_delay'])) {
    form_error($form['overlay_fade_out_delay'], t('!setting must be numeric!', array(
      'Overlay Fade Out Delay',
    )));
  }
}