Closed Bug 1457074 Opened 7 years ago Closed 3 years ago

Attachments drag and drop between attachment panes of two compose windows will only copy one attachment

Categories

(Thunderbird :: Message Compose Window, defect, P3)

52 Branch

Tracking

(thunderbird_esr91 wontfix, thunderbird93 affected)

RESOLVED FIXED
94 Branch
Tracking Status
thunderbird_esr91 --- wontfix
thunderbird93 --- affected

People

(Reporter: germano.massullo, Assigned: henry-x)

Details

Attachments

(1 file)

User Agent: Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:59.0) Gecko/20100101 Firefox/59.0 Build ID: 20180327091359 Steps to reproduce: In sent box, I have a message with 3 attachments. 1) I selected the message, then clicked on "Forward message", so a new message editing window appeared with the 3 attachments. Let's call this window 'A'; 2) I opened a new "new message" window. Let's call this window 'B'; 3) I tried to drag and drop the 3 attachments from A to B: only one attachment has been copied. Actual results: Only one attachment has been copied, instead of three. Dragging attachments one per time worked instead Thunderbird 52.7.0 on Fedora 27
I can confirm this. When you say "is broken", are you implying that this worked in some prior version?
Status: UNCONFIRMED → NEW
Ever confirmed: true
Summary: Attachments drag and drop between messages is broken → Attachments drag and drop between attachment panes of two compose windows will only copy one attachment
(In reply to Jorg K (GMT+1) from comment #1) > I can confirm this. When you say "is broken", are you implying that this > worked in some prior version? I haven't ever tried this before

Still seen exactly as described on 91.1.0 (64-bit), Win10.

Alex, can you have a look?

Severity: normal → S3
Flags: needinfo?(alessandro)
Priority: -- → P3

I tested this.

Moving multiple attachments from an email to another works IF the drag action starts from the message pane.
It fails if, as reported by the user, the action starts from the attachment pane of a forwarded message (Compose window).

The problem could be here, when the data is received: https://searchfox.org/comm-central/rev/c95ebf4f2b53e75652abc2e322b4885547bb5978/mail/components/compose/content/MsgComposeCommands.js#8319-8424

Or here, when the drag starts inside the attachment bucket: https://searchfox.org/comm-central/rev/c95ebf4f2b53e75652abc2e322b4885547bb5978/mail/components/compose/content/MsgComposeCommands.js#8606-8613

Henry, would you have time to look at this?

Flags: needinfo?(alessandro) → needinfo?(henry)

(In reply to Alessandro Castellani [:aleca] from comment #4)

Or here, when the drag starts inside the attachment bucket: https://searchfox.org/comm-central/rev/c95ebf4f2b53e75652abc2e322b4885547bb5978/mail/components/compose/content/MsgComposeCommands.js#8606-8613

From looking at the code, this seems to be the origin. It only selects the attachment that is under the mouse at the drag start.

Assignee: nobody → henry
Status: NEW → ASSIGNED
Flags: needinfo?(henry)

Also, for both the writing and reading messages, make sure that attachments are only dragged if they are selected.

Thanks for taking care of this so quickly, great job.

I think we should implement a simple test to cover this scenario.
If you want, you can mark this for check in and leave open so this initial fix can be pushed and deal with the test in another patch.

Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/3bc253be4432
Transfer all selected attachments from the composition window. r=aleca

Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 94 Branch

Comment on attachment 9241755 [details]
Bug 1457074 - Transfer all selected attachments from the composition window. r=aleca

[Approval Request Comment]
Regression caused by (bug #):
User impact if declined: drag dropping might not get all attachments
Testing completed (on c-c, etc.):
Risk to taking this patch (and alternatives if risky):
minor fix, includes tests

Attachment #9241755 - Flags: approval-comm-beta?

Comment on attachment 9241755 [details]
Bug 1457074 - Transfer all selected attachments from the composition window. r=aleca

[Triage Comment]
approved for beta

Attachment #9241755 - Flags: approval-comm-beta? → approval-comm-beta+

The tests for this fix failed after uplift to beta. The test is looking for an "attachmentArea" element that looks like it was added in bug 1729314.

Backout from comm-beta (Thunderbird 93.0b5):
https://hg.mozilla.org/releases/comm-beta/rev/bf226aa12f86

Status: RESOLVED → REOPENED
Resolution: FIXED → ---

Rob, do you still want to uplift this? I don't really know how to provide a different patch for 93/91 and to test it, but I think the test could pass if you changed https://hg.mozilla.org/releases/comm-beta/rev/7a88728e6cb4#l3.276 to

let srcAttachmentArea = ctrlSrc.window.document.getElementById(
  "attachmentsBox"
);

// Wait for attachment area to be visible and open in response.
await TestUtils.waitForCondition(
  () => !srcAttachmentArea.collapsed,
  "Attachment area is visible and open"
);

Not sure if splitting the patches is worth it in this case.

Flags: needinfo?(rob)

At this point, the fix is on beta, so unless there's no need to uplift there.

Flags: needinfo?(rob)

This bug is still present in version 95.0a1 (2021-10-18), so the drag and drop appears to be broken. The only thing that seems to work reliably is selecting the files using the paper clip icon (Ctrl+Shift+A). Further, it appears that the area to drag and drop is now limited to the outside of the highlighted message square that is presented upon the process of dragging the files. Since this outside area is very small, it is very hard now to use the drag and drop feature.

Just checked with version 95.0a1 (2021-10-21) and the bug has been fixed. However, this issue about the area to drag and drop being limited to the outside of the highlighted message square (which almost covers the entire message) is still outstanding. This makes dragging and dropping difficult to use.

(In reply to carodri2 from comment #17)

Just checked with version 95.0a1 (2021-10-21) and the bug has been fixed. However, this issue about the area to drag and drop being limited to the outside of the highlighted message square (which almost covers the entire message) is still outstanding. This makes dragging and dropping difficult to use.

This sounds like a completely unrelated issue to this bug.
Please, open a new bug and attach a screenshot/screencast of the issue with a detailed description on how to reproduce the error.

Rob, can this be closed?

Flags: needinfo?(rob)
Status: REOPENED → RESOLVED
Closed: 3 years ago3 years ago
Flags: needinfo?(rob)
Resolution: --- → FIXED

Henry - uplift to 91?

(In reply to Magnus Melin [:mkmelin] from comment #20)

Henry - uplift to 91?

It would require a different patch to fix the test, along the lines of comment 14, but I would have to test it. I can test it next week if you think this is worth uplifting.

Thanks, no not important enough to put additional time on.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: