Commit 57176f50 authored by webchick's avatar webchick

Issue #1933426 by dawehner: Fixed contextual links on views.

parent b9a4e9b7
......@@ -483,7 +483,7 @@ function views_preprocess_html(&$variables) {
unset($variables['attributes']['class'][$key]);
// Add the JavaScript, with a group and weight such that it will run
// before modules/contextual/contextual.js.
drupal_add_js(drupal_get_path('module', 'views') . '/js/views-contextual.js', array('group' => JS_LIBRARY, 'weight' => -1));
drupal_add_library('views', 'views.contextual-links');
}
}
}
......@@ -861,6 +861,17 @@ function views_library_info() {
array('system', 'drupal.ajax'),
),
);
$libraries['views.contextual-links'] = array(
'title' => 'Views Contextual links',
'version' => VERSION,
'js' => array(
"$path/views-contextual.js" => array('group' => JS_LIBRARY, 'weight' => -10),
),
'dependencies' => array(
array('system', 'jquery'),
array('system', 'drupal'),
),
);
return $libraries;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment