Even with breakpoints included in the theme .info file, enabling the Breakpoints module via a hook_update will not register the settings.

The last update to the dev branch (Commit 6170278 on 7.x-1.x - "only load breakpoints from enabled themes") appears to stop this from working as list_themes returns zero value for status when read from the installation directory to prevent notices.

http://api.drupal.org/api/drupal/includes%21theme.inc/function/list_them...

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Axel Pressbutton’s picture

Status: Active » Needs review
FileSize
581 bytes

I've created a patch to remove the status check.

attiks’s picture

#1 this means it will import breakpoints from all themes, including disabled themes

If this is in a custom hook_update function, you can create the breakpoints and groups by your self, but maybe it's easier to refactor breakpoints_themes_enabled a bit so it's split in 2 functions:

  1. a wrapper checking the the theme info
  2. a creator accepting the necessary data as parameters so you can call it from elsewhere as well
attiks’s picture

Category: bug » feature
Status: Needs review » Postponed (maintainer needs more info)
attiks’s picture

Issue summary: View changes
Status: Postponed (maintainer needs more info) » Closed (works as designed)