You are here

function breakpoints_breakpoint_load_all_active in Breakpoints 7

Load all enabled breakpoints.

2 calls to breakpoints_breakpoint_load_all_active()
BreakpointsCRUDTestCase::testBreakpointsCRUD in ./breakpoints.test
Test CRUD operations for breakpoints.
breakpoints_add_style_form in ./breakpoints.admin.inc

File

./breakpoints.module, line 418
Breakpoints @todo: provide button to reload breakpoints from theme

Code

function breakpoints_breakpoint_load_all_active($theme_key = '') {
  $breakpoints = breakpoints_breakpoint_load_all($theme_key);
  $enabled = array();
  if (!empty($breakpoints)) {
    foreach ($breakpoints as $breakpoint_name => $breakpoint) {
      if ($breakpoint->status) {
        $enabled[$breakpoint_name] = $breakpoint;
      }
    }
  }
  return $enabled;
}