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.


#1 theme_info_status_zero-1940652-1.patch581 bytesAxel Pressbutton
None View
Members fund testing for the Drupal project. Drupal Association Learn more


Axel Pressbutton’s picture

Status: Active » Needs review
581 bytes
None View

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)