[email/IMAP] Specialize delete behaviour on gmail so that deletion only removes the label/archives and does not place the message in trash



Firefox OS
4 years ago
2 years ago


(Reporter: asuth, Unassigned)


Firefox Tracking Flags

(Not tracked)



(1 attachment)



4 years ago
Under the gmail IMAP model, deleting a message from a folder removes the label (that is the folder).  But "moving" a message to the [Gmail]/Trash folder semantically moves it to the trash (which then self-empties after 30 days).

We currently move the message to trash, so the message will end up getting deleted.  Most e-mail apps out there, including Thunderbird, have adapted to handle gmail specifically by default to just remove the label.  We should do that too.

Juwei, I think this is the right thing to do from a UX perspective, but I am needinfo-ing you since you get to make the official call!

Implementation notes:
- IMAP's do_delete job has a comment about this gmail case that is misleading; no gmail-specific logic was ever implemented.
- IMAP's do_delete shunts to do_move with a target of the trash folder.  Rather than further complicate the move logic, we should probably just shunt to do_modtags under the hood keyed off of whether the server is gmail or not.

Gmail Context/docs:

iOS support docs on their behaviour which is interesting in that they also seem to try and change verbiage/icons in some, if not all, spots:

(Note that we currently do not implement an archive capability, though Thunderbird has one.)
Flags: needinfo?(jhuang)
Blocks: 950779

Comment 1

4 years ago
Hi Andrew,
I think it's good to have a special portal for Gmail, and I haven't seen any UX impact here... so it's fine with me :)
Flags: needinfo?(jhuang)


3 years ago
See Also: → bug 1093042
See Also: → bug 1178351
Created attachment 8656474 [details]

Hi James,

Please use attached images for archive icon.
Thank you.
You need to log in before you can comment on or make changes to this bug.