Mms: Fix messaging has stopped when copy SIM SMS to Phone

When copy SIM SMS to phone, copyToPhoneMemory() try to get subscription
use sub_id, cause java.lang.IllegalArgumentException: column 'sub_id'
does not exist.

Change sub_id to phone_id.

CRs-Fixed: 740114

Change-Id: I2856f15e91ffede03e1b8dcc053c919c00eec0ab
Mms: Fix The new message tip not disappeared

The Mms app failed to cancel the notification after marking the
new message as read in database.

If marking the new message as read in database throws a
“SQLiteFullException” exception, just return without cancelling
the notification. Otherwise, cancel the notification.

CRs-Fixed: 740039

Change-Id: Ib3058e8ea2cf1684260e04411b984f272f3464ee
Mms: Fix can't share video via MMS in gallery.

Because Mms intent filter don't match the video.

Add video mime type to intent filter data.

CRs-Fixed: 743496

Change-Id: I2623999515b8f92041b5c39f8d39cedf39c72848
Fix click notification will go to the wrong SIM storage when MT SMS to SIM card.

It did not update the PendingIntent's extra info without the FLAG_UPDATE_CURRENT.

Add FLAG_UPDATE_CURRENT to update PendingIntent's extra info. Use different
notification id for different SIMs' notifications.

Change-Id: I63027263247387ebb89f0f6865573045f5c2b1be
CRs-Fixed: 744865
MMS: Fix no add attachment option when reply SMS from folder mode

When mSendDiscreetMode is true, it will not show any menu.

Add a reply flag to show menu when in mSendDiscreetMode.

Add CRs-Fixed: 741034
(cherry picked from commit 231506b81b6557061ad364bf11c6dda3519f5a64)

Change-Id: I97a88a4746399eb9ab03f7f3add047179603d8bd
Mms: Unified dual SIM message prefereces in setting

Disable the preference if current SIM card is absent or not active
for dual SIM message setting.

Change-Id: I61a6d4a26fb34ef651922478099c06976d10fd4b
Mms: Fix copying SMS to SUB2 fail in C+G

Use new interface SmsMessage.getSubmitPdu() and pass a parameter
subId to get the correct Pdu.

CRs-Fixed: 727110

Change-Id: I7fbda47cbdf11d9995dd549f24867de319103e3a
Mms: Fix SMS/MMS draft's phone number can't be changed.

Because initialize recipient editor after activity resume when edit
draft, so don't add recipient changed listener in activity resume.

Add recipient changed listener after query complete for editing draft.

CRs-Fixed: 741024

Change-Id: I630adc26878fdd16f66cd170f289c65766c47255
Mms: Fix that can't show vcard in folder mode.

The slideshow presenter doesn't have an interface to  show vcard.

Follow the change of CR619137, add view/save vCard function for
slideshow presenter.

CRs-Fixed: 740991

Change-Id: Idf4a4b77545f85bff9e003922132b4ee59eccd02
Mms: Do not display process bar when slideshow with only text inside

Check code, a condition control the showing.

Change the condition.

CRs-Fixed: 636502

Change-Id: I8f5a4f2c5ba7bffec963345c5d6693f5aba7d553
Mms: Fix there is no save attachment option when long press Mms attachment

No save attachment menu item in compose_multi_select_menu.xml

Add the menu item and realize save attachment function.

CRs-Fixed: 739281

Change-Id: I3fc3168ea954c1f6f9e7cec4a5f2666820790250
Mms: Fix there is no effect when tap the add recipients/group icon

It will show two send buttons if insert two sim cards, the
judging conditions in method onClick() is improper in this
issue. The click event was intercepted.

Modify the judging conditions in method onClick().

CRs-Fixed: 741082

Change-Id: I8d0534135b6f1d93645810e87348a01e7634ca64
Mms: Fix drop-down icons cover with contact name

Doesn't set left padding for text view which diplays contacts name.

Same with CR693682, use dp to set left padding in pick_contact_item.xml.

CRs-Fixed: 740956

Change-Id: Ic2acf4a486e89ac1057e6aa5258351fa1b7fe161
Mms: Fix not remind user about "Delete lock message"

Don't prompt whether containing locked message when confirm delete.

Change to using confirm dialog that check locked message.

CRs-Fixed: 745312

Change-Id: Id04ea57612514b7e49ff797113e902ded6d5118a
Mms: Fix no progress bar during deleting threads.

UI does not show a progress dialog during deleting threads.

Follow the change of CR589963 and CR561491,show a ProgressDialog if
deleting sms takes time longer than 0.5sec.
Only dismiss the dialog after the last conversation has been deleted.

CRs-Fixed: 744808

Change-Id: I78887bf03fdc0ba3aca8ebb319a6cfa7cb2af71b
MMS: Fix The slideshow can't be shown in message

After the MessageItem Pdu Loaded, the MessageItem's AttachmentType
might have changed. So precisely, it's not the same MessageItem
anymore.Since it's not the same MessageItem, we should setImage,
and the slideshow will be shown normally.

After Pdu Loaded, when bindCommonMessage again, the sameItem
argument should be false, because it's not the same MessageItem
anymore.

CRs-Fixed: 741025

Change-Id: Ibef5ca408d86ba76e730fe1fc4117d953d6c74fa
MMS: Fix issue that can't download MMS after MT call.

Save STATE_PERMANENT_FAILURE(0x87) of MMS status when receiving a call,
 after the call, get wrong MMS download status STATE_PRE_DOWNLOADING(0x83).
MMS download status no need do this operator
 "mMmsStatus & ~DownloadManager.DEFERRED_MASK(0x04)".

Change-Id: Ia73bcaa1ecf686656dea345de2169324c7490ec9
CRs-Fixed: 743554
Mms: Show statistics of SIM card message.

Add sim capacity function on SIM card message view.

Change-Id: If2967e0cd40753e0fe78e1f77eaa8ef76822ed8b
CRs-Fixed: 645022