[ Index ]

PHP Cross Reference of Drupal 6 (gatewave)

title

Body

[close]

/sites/all/modules/panels/plugins/styles/ -> default.inc (source)

   1  <?php
   2  // $Id: default.inc,v 1.1.2.8 2010/07/13 23:55:58 merlinofchaos Exp $
   3  
   4  /**
   5   * @file
   6   * Definition of the 'default' panel style.
   7   */
   8  
   9  // Plugin definition
  10  $plugin = array(
  11    'title' => t('No style'),
  12    'description' => t('The default panel rendering style; displays each pane with a separator.'),
  13    'render region' => 'panels_default_style_render_region',
  14    'weight' => -15,
  15  );
  16  
  17  /**
  18   * Render callback.
  19   *
  20   * @ingroup themeable
  21   */
  22  function theme_panels_default_style_render_region($display, $region_id, $panes, $settings) {
  23    $output = '';
  24  
  25    $print_separator = FALSE;
  26    foreach ($panes as $pane_id => $pane_output) {
  27      // Add the separator if we've already displayed a pane.
  28      if ($print_separator) {
  29        $output .= '<div class="panel-region-separator"></div>';
  30      }
  31  
  32      $output .= $pane_output;
  33      // If we displayed a pane, this will become true; if not, it will become
  34      // false.
  35      $print_separator = (bool) $pane_output;
  36    }
  37  
  38    return $output;
  39  }


Generated: Thu Mar 24 11:18:33 2011 Cross-referenced by PHPXref 0.7