You are here

function footable_breakpoint_load_multiple in FooTable 7.2

Returns a list of FooTable breakpoints filtered by machine name.

Parameters

array $machine_names: List of machines names to filter by or an empty array to load all breakpoints.

bool $disabled: Include disabled breakpoints.

Return value

array List of loaded FooTable breakpoints.

5 calls to footable_breakpoint_load_multiple()
footable_breakpoint_load in ./footable.module
Load a single FooTable breakpoint by machine name.
footable_breakpoint_load_all in ./footable.module
Returns a list of FooTable breakpoints including or excluding the default FooTable breakpoints (All / Default).
footable_plugin_style_footable::options_form in views/footable_plugin_style_footable.inc
Render the given style.
template_preprocess_footable_view in ./footable.module
Display a view as a FooTable style.
theme_footable in ./footable.theme.inc
Returns HTML for a table.

File

./footable.module, line 405
Provides Views integration for the jQuery FooTable plugin.

Code

function footable_breakpoint_load_multiple(array $machine_names = array(), $disabled = FALSE) {
  ctools_include('export');
  $breakpoints = empty($machine_names) ? ctools_export_load_object('footable_breakpoint') : ctools_export_load_object('footable_breakpoint', 'names', $machine_names);
  drupal_alter('footable_breakpoint_load', $breakpoints);
  if (!$disabled) {
    foreach ($breakpoints as $machine_name => $breakpoint) {
      if (!empty($breakpoint->disabled)) {
        unset($breakpoints[$machine_name]);
      }
    }
  }
  uasort($breakpoints, 'footable_breakpoint_sort');
  return $breakpoints;
}