Projet

Général

Profil

Révision 64156087

Ajouté par Assos Assos il y a plus de 7 ans

Weekly update of contrib modules

Voir les différences:

drupal7/sites/all/modules/panels/panels_mini/panels_mini.module
39 39
    'type' => MENU_LOCAL_TASK,
40 40
  );
41 41

  
42
  // Also provide settings on the main panel UI
42
  // Also provide settings on the main panel UI.
43 43
  $items['admin/structure/panels/settings/panels-mini'] = array(
44 44
    'title' => 'Mini panels',
45 45
    'page callback' => 'panels_mini_settings',
......
59 59
}
60 60

  
61 61
// ---------------------------------------------------------------------------
62
// Allow the rest of the system access to mini panels
63

  
62
// Allow the rest of the system access to mini panels.
64 63
/**
65 64
 * Implementation of hook_block_info().
66 65
 */
......
91 90
 * @see panels_mini_panels_mini_content_type_render().
92 91
 */
93 92
function panels_mini_block_view($delta = 0) {
94
  // static recursion protection.
93
  // Static recursion protection.
95 94
  static $viewing = array();
96 95
  if (!empty($viewing[$delta])) {
97 96
    return;
......
114 113
  }
115 114
  drupal_alter('panels_mini_block_contexts', $contexts, $panel_mini);
116 115

  
117
  $panel_mini->context = $panel_mini->display->context =  ctools_context_load_contexts($panel_mini, FALSE, $contexts);
116
  $panel_mini->context = $panel_mini->display->context = ctools_context_load_contexts($panel_mini, FALSE, $contexts);
118 117
  $panel_mini->display->css_id = panels_mini_get_id($panel_mini->name);
119 118
  $panel_mini->display->owner = $panel_mini;
120 119

  
......
133 132
function panels_mini_block_configure($delta = 0) {
134 133
  return array(
135 134
    'admin_shortcut' => array(
136
      '#markup' => l(t('Manage this mini-panel'), 'admin/structure/mini-panels/list/' . $delta . '/edit')
135
      '#markup' => l(t('Manage this mini-panel'), 'admin/structure/mini-panels/list/' . $delta . '/edit'),
137 136
    ),
138 137
  );
139 138
}
......
241 240

  
242 241
// ---------------------------------------------------------------------------
243 242
// Database functions.
244

  
245 243
/**
246 244
 * Create a new page with defaults appropriately set from schema.
247 245
 */
......
331 329
          $dids[$mini->did] = $mini->name;
332 330
        }
333 331
        else {
334
        // Translate old style titles into new titles.
332
          // Translate old style titles into new titles.
335 333
          if (!empty($mini->title) && empty($mini->display->title)) {
336 334
            $mini->display->title = $mini->title;
337 335
          }
......
400 398
function panels_mini_export($mini, $indent = '') {
401 399
  ctools_include('export');
402 400
  $output = ctools_export_object('panels_mini', $mini, $indent);
403
  // Export the primary display
401
  // Export the primary display.
404 402
  $display = !empty($mini->display) ? $mini->display : panels_load_display($mini->did);
405 403
  $output .= panels_export_display($display, $indent);
406 404
  $output .= $indent . '$mini->display = $display' . ";\n";
......
462 460
}
463 461

  
464 462
/**
465
 * Get display edit cache for the panels mini export UI
463
 * Get display edit cache for the panels mini export UI.
466 464
 *
467 465
 * The key is the second half of the key in this form:
468 466
 * panels_mini:TASK_NAME:HANDLER_NAME;

Formats disponibles : Unified diff