Same name in other branches
  1. 7.x-2.x includes/admin.inc \_quicktabs_get_views_displays()
  2. 8.x-1.x quicktabs.admin.inc \_quicktabs_get_views_displays()

Helper function to get all view displays.

2 calls to _quicktabs_get_views_displays()
QuickViewContent::optionsForm dans plugins/QuickViewContent.inc
Method for returning the form elements to display for this tab type on the admin form.
_quicktabs_replace_view_displays_callback dans ./quicktabs.admin.inc
Ajax callback, triggered when view is changed.

Fichier

./quicktabs.admin.inc, line 605

Code

function _quicktabs_get_views_displays($view_name) {
    $displays = array();
    if (empty($view_name)) {
        // No view.
        return $displays;
    }
    $views = views_get_all_views();
    $view = $views[$view_name];
    if (empty($view->display)) {
        // This view is broken.
        return $displays;
    }
    foreach ($view->display as $id => $display) {
        $displays[$id] = $id . ': ' . $display->display_title;
    }
    return $displays;
}