Closed
Bug 869255
Opened 12 years ago
Closed 12 years ago
[MMS][User Interface] Attach button fire pick Activity and create Attachment
Categories
(Firefox OS Graveyard :: Gaia::SMS, defect, P1)
Tracking
(blocking-b2g:leo+, b2g18 fixed)
| Tracking | Status | |
|---|---|---|
| b2g18 | --- | fixed |
People
(Reporter: danheberden, Assigned: jugglinmike)
References
Details
(Keywords: feature)
Attachments
(1 file, 6 obsolete files)
|
12.90 KB,
patch
|
gnarf
:
review+
|
Details | Diff | Splinter Review |
There needs to be UI for the user to attach (pick) a media element. This should fire the pick activity, allowing the user to pick a media element, returning that element to the messaging app and adding to the message. (Something like `Compose.append(new Attachment(blob))`
| Reporter | ||
Updated•12 years ago
|
| Reporter | ||
Comment 1•12 years ago
|
||
This bug covers not only the pick button but also making sure that the styles (that the attach button will certainly affect) related to composition (the input box, send button, etc) are all up to spec.
| Assignee | ||
Comment 2•12 years ago
|
||
I began implementing this interface component in Bug 840044. I've since marked that patch as obsolete, and I will attach a newer version here when it is available.
| Reporter | ||
Comment 3•12 years ago
|
||
Revering this being so large of a bug. This is only for the pick icon and related activity. The test of the styling issues are https://bugzilla.mozilla.org/show_bug.cgi?id=870057
| Reporter | ||
Comment 4•12 years ago
|
||
I mean the *bug* for the styling issues is https://bugzilla.mozilla.org/show_bug.cgi?id=870057
Updated•12 years ago
|
Whiteboard: [NO_UPLIFT]
| Assignee | ||
Comment 5•12 years ago
|
||
The "Search" building block[1] is documented to optionally support the "attachment" icon described by the UI specification. Unfortunately, it doesn't seem to technically implement this. I will reach out to the building block maintainers, but in the mean time, this patch will likely include an SMS-specific UI.
Updated•12 years ago
|
blocking-b2g: --- → leo+
| Assignee | ||
Comment 6•12 years ago
|
||
Attachment #748829 -
Flags: review?(felash)
| Assignee | ||
Comment 7•12 years ago
|
||
Corey has merged the "messaging" fork upstream, so I'm re-submitting this as a patch for review (and merge to "master") by Julien.
Attachment #748829 -
Attachment is obsolete: true
Attachment #748829 -
Flags: review?(felash)
Attachment #748982 -
Flags: review?(felash)
Comment 8•12 years ago
|
||
I kind of feel like this should be functionality & corresponding tests should baked into the Compose object, anyone else have opinions?
Comment 9•12 years ago
|
||
Also, this bug really feels co-dependant on bug 840044 - landing this one without the other is going to be confusing - a button that asks for a pick action, but doesn't actually do anything feels like a bug. Perhaps we can agree on the commit for this one, and just land it at the same time as bug 840044?
| Assignee | ||
Comment 10•12 years ago
|
||
As per Corey's feedback, I've moved the relevant logic into `compose.js`
Attachment #748982 -
Attachment is obsolete: true
Attachment #748982 -
Flags: review?(felash)
Attachment #748996 -
Flags: review?(felash)
| Assignee | ||
Comment 11•12 years ago
|
||
As per This version moves more of the code that actually concerns message composition into 'compose.js'
Attachment #748996 -
Attachment is obsolete: true
Attachment #748996 -
Flags: review?(felash)
Attachment #749011 -
Flags: review?(gnarf37)
| Assignee | ||
Comment 12•12 years ago
|
||
While working on Bug 840044, I realized that the test introduced in the previous patch excercised too many methods to be considered a unit test. This patch re-factors the test to be more focused.
Attachment #749011 -
Attachment is obsolete: true
Attachment #749011 -
Flags: review?(gnarf37)
Attachment #749036 -
Flags: review?(gnarf37)
Comment 13•12 years ago
|
||
Comment on attachment 749036 [details] [diff] [review]
Implement Attach button UI
Review of attachment 749036 [details] [diff] [review]:
-----------------------------------------------------------------
LGTM - Just a few comments, but consider it r+ - let me know if you decide to make the follow up change
::: apps/sms/js/compose.js
@@ +114,5 @@
> init: function thui_compose_init(formId) {
> dom.form = document.getElementById(formId);
> dom.message = dom.form.querySelector('[contenteditable]');
> + dom.submitButton = dom.form.querySelector('button[type="submit"]');
> + dom.attachButton = dom.form.querySelector('#messages-attach-button');
Should we use getElementById instead? Also maybe the same for the submit button?
@@ +270,5 @@
> + }
> + });
> +
> + activity.onsuccess = function() {
> + // TODO: use `activity.result` to create the attachment.
Not Blocking on this, but any TODO should have a bug # when possible
Attachment #749036 -
Flags: review?(gnarf37) → review+
Comment 14•12 years ago
|
||
Also, the attach button seems incorrectly aligned, i would imagine it should be at the bottom like send is: http://cl.ly/image/3S0F2J190D3S
| Assignee | ||
Comment 15•12 years ago
|
||
Addressing Corey's feedback.
Attachment #749036 -
Attachment is obsolete: true
Attachment #749456 -
Flags: review?(gnarf37)
Updated•12 years ago
|
Attachment #749456 -
Flags: review?(gnarf37) → review+
| Assignee | ||
Comment 16•12 years ago
|
||
This version addresses the rendering issue identified in comment 14
Attachment #749456 -
Attachment is obsolete: true
Attachment #749510 -
Flags: review?(gnarf37)
Updated•12 years ago
|
Attachment #749510 -
Flags: review?(gnarf37) → review+
| Assignee | ||
Comment 17•12 years ago
|
||
75e153f09e72b692917556e028dacb8436a0d86f
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Updated•12 years ago
|
Whiteboard: [NO_UPLIFT]
Updated•12 years ago
|
Attachment mime type: text/plain → text/x-github-pull-request
You need to log in
before you can comment on or make changes to this bug.
Description
•