MDL-46157 drag and drop: Improve item labels

Ignore the edit menu when determining the region to drag.
This commit is contained in:
Cameron Ball 2015-09-08 11:33:24 +08:00
parent 1dabedeedf
commit 9b5882d3e1
4 changed files with 5 additions and 5 deletions

View file

@ -339,7 +339,7 @@ Y.extend(DRAGDROP, Y.Base, {
*/ */
find_element_text: function(n) { find_element_text: function(n) {
// The valid node types to get text from. // The valid node types to get text from.
var nodes = n.all('h2, h3, h4, h5, span, p, div.no-overflow, div.dimmed_text'); var nodes = n.all('h2, h3, h4, h5, span:not(.actions):not(.menu-action-text), p, div.no-overflow, div.dimmed_text');
var text = ''; var text = '';
nodes.each(function () { nodes.each(function () {

File diff suppressed because one or more lines are too long

View file

@ -339,7 +339,7 @@ Y.extend(DRAGDROP, Y.Base, {
*/ */
find_element_text: function(n) { find_element_text: function(n) {
// The valid node types to get text from. // The valid node types to get text from.
var nodes = n.all('h2, h3, h4, h5, span, p, div.no-overflow, div.dimmed_text'); var nodes = n.all('h2, h3, h4, h5, span:not(.actions):not(.menu-action-text), p, div.no-overflow, div.dimmed_text');
var text = ''; var text = '';
nodes.each(function () { nodes.each(function () {

View file

@ -337,7 +337,7 @@ Y.extend(DRAGDROP, Y.Base, {
*/ */
find_element_text: function(n) { find_element_text: function(n) {
// The valid node types to get text from. // The valid node types to get text from.
var nodes = n.all('h2, h3, h4, h5, span, p, div.no-overflow, div.dimmed_text'); var nodes = n.all('h2, h3, h4, h5, span:not(.actions):not(.menu-action-text), p, div.no-overflow, div.dimmed_text');
var text = ''; var text = '';
nodes.each(function () { nodes.each(function () {