skinr_panels.skinr.inc 910 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. <?php
  2. /**
  3. * @file
  4. * Implements Skinr hooks for panels.module.
  5. */
  6. /**
  7. * Implements hook_skinr_config_info().
  8. */
  9. function skinr_panels_skinr_config_info() {
  10. return array('panels');
  11. }
  12. /**
  13. * Implements hook_skinr_theme_hooks().
  14. */
  15. function skinr_panels_skinr_theme_hooks($module, $element) {
  16. $theme_hooks = array();
  17. if ($module == 'panels') {
  18. if (strpos($element, 'region') === 0) {
  19. $theme_hooks[] = 'panels_region';
  20. }
  21. elseif (strpos($element, 'pane') === 0) {
  22. $theme_hooks[] = 'panels_pane';
  23. }
  24. else {
  25. $theme_hooks[] = 'panels_display';
  26. }
  27. }
  28. return $theme_hooks;
  29. }
  30. /**
  31. * Implements hook_skinr_elements().
  32. */
  33. function skinr_panels_skinr_elements($variables, $hook) {
  34. $elements = array();
  35. if ($hook == 'panels_pane') {
  36. $elements['panels'] = array('pane__' . $variables['pane']->did . '__' . $variables['pane']->pid);
  37. }
  38. return $elements;
  39. }