Modify

#10687 closed defect (fixed)

Can't drag item into last table row

Reported by: rjollos Owned by: rjollos
Priority: normal Component: AdminEnumListPlugin
Severity: normal Keywords:
Cc: jun66j5, nonplus Trac Release:

Description

It is not currently possible to drag an item into the last row. I found one hint that suggested this is because the last element is flush against the bottom of the container, and the solution is to add some padding.

Attachments (1)

t10687-r12416-mousemove.diff (1.6 KB) - added by jun66j5 17 months ago.
including fix of #10664

Download all attachments as: .zip

Change History (10)

Changed 17 months ago by jun66j5

including fix of #10664

comment:1 Changed 17 months ago by jun66j5

I just found the same ;)

This issue is caused by the broken capture of mouse position. The following code does not work.

    $().mousemove(function(e) {
        mouseY = e.pageY;
    });

Also, it causes the another issue. After clicking checkbox or radio buttons, it cannot drag the items.

After t10687-r12416-mousemove.diff, it would be possible to drag into the last row.

comment:2 Changed 17 months ago by rjollos

Thanks! I will commit the change by later this evening. If you have a chance to look at any of the other changes and have any comments, I appreciate any feedback you have.

comment:3 follow-up: Changed 17 months ago by rjollos

  • Status changed from new to assigned

I have to wonder though, why the original author didn't just use jQuery UI's sortable widget, which should handle a lot of this work behind the scenes. The API docs say it has been available since jQuery UI 1.0.

The BacklogPlugin utilizes the sortable widget, and the code is much more concise.

comment:4 Changed 17 months ago by rjollos

This ticket is next up on my list, but I'll have to wait until morning. Thanks for all of your testing!

comment:5 in reply to: ↑ 3 Changed 17 months ago by jun66j5

Replying to rjollos:

I have to wonder though, why the original author didn't just use jQuery UI's sortable widget, which should handle a lot of this work behind the scenes. The API docs say it has been available since jQuery UI 1.0.

+1, good idea and useful information. I didn't think that sortable works with table elements.

comment:6 Changed 16 months ago by rjollos

(In [12460]) Refs #10687:

  • FIX: It was not possible to drag an item into the last row.
  • FIX: drag of items was broken after selecting a checkbox, radio button or select.


Patch by Jun Omae (jun66j5).

comment:7 follow-up: Changed 16 months ago by rjollos

I previously ran into trouble getting the sortable widget working with Trac 0.11 while working on the BacklogPlugin. I'm not certain, but I suspect that the sortable widget won't work with the versions of jQuery in Trac 0.11.x (see comment:5:ticket:10657).

comment:8 in reply to: ↑ 7 Changed 16 months ago by anonymous

Replying to rjollos:

I previously ran into trouble getting the sortable widget working with Trac 0.11 while working on the BacklogPlugin.

I see now that I had some luck getting jQuery UI 1.6 working with Trac 0.11.1 and later in #10331, so I've created ticket #10732 for using the Sortable widget in this plugin. I guess this is a good step to make prior to t:#10994.

comment:9 Changed 14 months ago by rjollos

  • Resolution set to fixed
  • Status changed from assigned to closed

Add Comment

Modify Ticket

Action
as closed .
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from rjollos. Next status will be 'closed'.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.