Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 247eb444 authored by Hemant Gupta's avatar Hemant Gupta Committed by Linux Build Service Account
Browse files

MAP: Add support for Email and map bug fixes

Squashed bug fixes in map profile along with email support

MAP: Support MMS pushMessage feature.

Enable MMS push Message feature support. Parse multi
parts in bMessage including text and attachments as
per standard MIME format.

Change-Id: I292f9f96d0b1215f86c95c9ae531dbe7ec6e7b05

Bluetooth: Map: Add Bug fixes from kk.

Squashed commit of the following:

commit 2f11cda9955871c40e0ecde465e79eadeb24b089
Author: Pradeep Panigrahi <pradeepp@codeaurora.org>
Date:   Fri Jul 18 00:03:10 2014 +0530

    Bluetooth: Map: Bug fixes on MAP profile

    Generic bug fixes in map profile.

    Change-Id: I9b3dcf73de595f30c5c132caf6d9bb728f75191a

commit 741be2f08a844e7559f6e328e5b1e86311e5a4cf
Author: Ashwini Munigala <AshwiniM@codeaurora.org>
Date:   Fri May 30 18:25:24 2014 +0530

    MAP: Fix MAP Connect issue for frequent connect/disconnect trials

    Ensure isWaitingAuthorization flag update during MAP Connect
    authorization from SocketAcceptThread to avoid user timeout
    disconnection for frequent remote connect/disconnect trials.

    Change-Id: I1502ef1bd97cc1ecaf624f371fb23a33869ab80e
    CRs-fixed: 667467
    (cherry picked from commit 99eb62b3195782cdde8320e9fe231168b5b48a77)

commit 29111c59dba3498b24c5fdfad649b83ae59a7e40
Author: Pradeep Panigrahi <pradeepp@codeaurora.org>
Date:   Sun Jun 22 17:33:51 2014 +0530

    Bluetooth: Map: Add below fixes in map code

    1) Do not allow message listing on root, telecom, msg folders.

    2) Use fastXmlSerializer for creating xml folder listing element.

    CRs-fixed: 683145

    Change-Id: I446049d21272542274cb675123e9b1735691640d

commit 14713469686e72d82b05299ce0dac09f622fe16a
Author: Pradeep Panigrahi <pradeepp@codeaurora.org>
Date:   Wed Jul 16 11:41:50 2014 +0530

    Bluetooth: Map: Add only originator phone number in getMessage response

    In a scenario where originator vcard comprises of multiple numbers,
    Map server is adding all the numbers present in Originator's vcard
    to bMessage while responding to getMessage request. This is creating
    IOT issues with all the carkits, as carkits are not able to parse
    properly this bMessage and always showing the last contact as the
    message Originator. Add change to keep only the primary number with
    which the message is sent, on the originator vcard.

    Change-Id: I9b3368353ad57476357b4d9933227d39653f3328
    CRs-fixed: 694556

commit 365673eb378670d8be8212b10dea34fde35a8f2b
Author: Pradeep Panigrahi <pradeepp@codeaurora.org>
Date:   Wed Jul 9 12:28:02 2014 +0530

    BT: Map: Add null check for number parameter during message listing

    A case where message is saved in draft with no recipeint name. when we
    try to fetch contact name during messagelisting, null number passed to
    ContactsProvider would cause IllegalArgumentException. Add null and
    empty check before quering contact provider.

    Change-Id: Id25ba00af414d252dd8b1ca6475bfa31b9278757
    CRs-fixed: 690894

commit 162b129aac30c5e4081b04e4144d2baa309ea587
Author: Pradeep Panigrahi <pradeepp@codeaurora.org>
Date:   Tue Jun 24 11:08:48 2014 +0530

    Bluetooth: Map: Parse Native format message properly

    Add change to parse native format message properly and call
    telephony interface with correct parameter.

    Change-Id: I52b27fa872986229914787053528e2cc53d8440b
    CRs-fixed: 684522

commit 2c5d6c433387c2dd863333c6f724ab6573fb4e0f
Author: Pradeep Panigrahi <pradeepp@codeaurora.org>
Date:   Wed May 21 08:50:37 2014 +0530

    Bluetooth: Map: IOT: Fix Message Display issue with FORD SYNC carkit

    FORD SYNC carkit is unable to parse message if line feed (\n)
    is present in it and displaying incomplete message. Add change to
    remove line feed (\n) from message and keep only carriage return
    (\r) in the message, to fix this IOT issue.

    Change-Id: Icf30097a5651be8595017aa6772cac02582c99be
    CRs-fixed: 667984

commit 858a4d750e05111e86d98cdbeb511d19fcd47a19
Author: Pradeep Panigrahi <pradeepp@codeaurora.org>
Date:   Fri May 16 10:54:56 2014 +0530

    Bluetooth:Map:IOT: Fix Subject Display issue with HONDA Carkit

    Honda Carkit always masks subject field in message listing and hence
    always shows a blank subject in UI. Add change to always send subject
    field in Messagelisting for honda carkit,so that it can show proper
    subject fields in UI and better user experience.

    Change-Id: Icb9dd51ba0e1d1a5b45aeb417afcce6e79365b32
    CRs-fixed: 664315

commit 030d6ddffc9df745f46566e93316c52913b14aac
Author: Pradeep Panigrahi <pradeepp@codeaurora.org>
Date:   Thu May 8 13:02:58 2014 +0530

    Bluetooth: Map: IOT: Fix Message Display issue with PCM carkit

    PCM carkit is unable to parse message if carriage return(\r)
    is present in it and displaying incomplete message. Add change to
    remove carriage return (\r) from message to fix this IOT issue.

    Change-Id: Ic69ffad138f2c633214a7a24c377b03c6f569d3f
    CRs-fixed: 660620

commit 71124336d13c61190d41dccdf830b11242892dac
Author: Pradeep Panigrahi <pradeepp@codeaurora.org>
Date:   Mon Feb 10 12:19:05 2014 +0530

    Bluetooth: MAP: Synchronize Mns function's to avoid race condition

    synchronize Mns shutdown and disconnect function so that if it is
    called from different threads at the same point, it should not lead
    to any crash.

    CRs-fixed: 613764

    Change-Id: I1df0440b4189521a0fb88d981f4208f225ef2a51

commit f1a78b061cffe66b58410bf2fd6dce3527150e56
Author: Pradeep Panigrahi <pradeepp@codeaurora.org>
Date:   Fri Jan 31 11:27:58 2014 +0530

    Bluetooth: Map: Validate BT Adapter before starting rfcomm listener

    Validate BT adapter handle to avoid null pointer exception, while
    trying to start rfcomm listener as a part of MAP profile startup.

    Change-Id: Ifa5f1f77ea51cab793df3695a8f7058525f67b98
    CRs-fixed: 608319

Change-Id: I7467247891b45708f9ebf8710c9545bdd94d93c3
Conflicts:
src/com/android/bluetooth/map/BluetoothMapService.java

MAP: Support MAP S Email Instance

Add MSE Implementation in Bluetooth Map Profile to
support email MAS instance for EMAIL type messages.

Change-Id: I65802821ebe545b605c7cfd5e9679173e780f2a1

Conflicts:
	src/com/android/bluetooth/map/BluetoothMapService.java

Bluetooth:Map: Bug fixes in MAP profile.

1) Use Application mainlooper while calling phoneStateListener.
2) Generic bug fixes in map profile.

CRs-fixed: 716711

Change-Id: Ibc874c5cba17faa8c97c8b085525a4e40531b9b2

Bluetooth: Map: Add replyToAddressing field in message lisitng element

replyToAddressing field is not getting added in messageListing element even
if parameter mask is set to zero. Add change to include reply to address as
well in the messagelisting element.

Change-Id: Id4a87685684b6eb746690489f84347271bd2f21e
CRs-fixed: 718838

Bluetooth: Map: Filter email messages based on priority

Add change to filter email messages based on priority if message
lisiting is done with filterPriority parameter

CRs-fixed: 718854

Change-Id: I1dc963ba370d13b867ce559b43e939a5dcf120c4

Bluetooth: Map: Add following fix in MAP profile

Add change to filter email messages using originator email .When message
listing is done with filter originator parameter set to email
address then message listing is failing because filtering was only supported
with originator name. Add change to filter email address using originator
email as well to fix this issue.

Add change to create proper v card for all reciepints in bMessage response
to get message request.

CRs-fixed: 718859

Change-Id: I1834d6fdc77c6fb92dd29c8bf74e6df37e0b6637

Bluetooth: Map: do not add old folder field in MessageDeleted mns event

As per MAP spec 1.2 MessageDeleted event should not contain the old_folder
field in mns event report. Add change for the same.

CRs-fixed: 720675

Change-Id: I6259b6db1e3d7d8fb83a8c6ea9a912560c2cc4d9

Bluetooth: Map: Add change to not send mns event for mce initiate operation

MCE initiated operation does not need mns event to be sent by mas server.
Add change such that no mns event is sent for mce initiated operation for
email instance.

CRs-fixed: 720677

Change-Id: I2355a9c7b81b8ef3c9dc6d612ac440a8fee9b1ee

MAP: MMS SendingSuccess event only for MCE initiated push.

Report MNS SendingSuccess type event only when
MMS is pushed through MAP from MCE.

CRs-fixed: 715343
Change-Id: I6f291152d1d91e8eda5ed2aaba6986e018f45446

Bluetooth: Map: Add following fixes in map profile

1) Add change to send sending success mns event for only mce initiated
   operation.
2) Add change to send message shift mns event
3) Add change to filter reply to addressing using parameter mask.

CRs-fixed: 724276

Change-Id: Iae285c63d9e0a452f44e32b58bb8c3240e07f933
parent 54dde23d
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -12,8 +12,8 @@ LOCAL_CERTIFICATE := platform
LOCAL_JNI_SHARED_LIBRARIES := libbluetooth_jni
LOCAL_JAVA_LIBRARIES += javax.btobex
LOCAL_JAVA_LIBRARIES += telephony-common
LOCAL_JAVA_LIBRARIES := javax.obex telephony-common
LOCAL_STATIC_JAVA_LIBRARIES := com.android.vcard
LOCAL_STATIC_JAVA_LIBRARIES += com.android.emailcommon

LOCAL_REQUIRED_MODULES := bluetooth.default
LOCAL_MULTILIB := 32
+4 −0
Original line number Diff line number Diff line
@@ -56,6 +56,10 @@
    <uses-permission android:name="android.permission.MEDIA_CONTENT_CONTROL" />
    <uses-permission android:name="android.permission.MANAGE_DOCUMENTS" />

<uses-permission android:name="com.android.email.permission.ACCESS_PROVIDER"/>
    <uses-permission android:name="com.android.email.permission.READ_ATTACHMENT"/>


    <!-- For PBAP Owner Vcard Info -->
    <uses-permission android:name="android.permission.READ_PROFILE"/>
    <application
+8 −1
Original line number Diff line number Diff line
@@ -168,6 +168,9 @@ public class BluetoothMapAppParams {
        while (i < appParams.length) {
            tagId = appParams[i++] & 0xff;     // Convert to unsigned to support values above 127
            tagLength = appParams[i++] & 0xff; // Convert to unsigned to support values above 127
            Log.d(TAG, "tagId is "+ tagId );
            Log.d(TAG, "tagLength is "+ tagLength );
            Log.d(TAG, "appParams[i] is "+ appParams[i]);
            switch (tagId) {
            case MAX_LIST_COUNT:
                if (tagLength != MAX_LIST_COUNT_LEN) {
@@ -696,8 +699,12 @@ public class BluetoothMapAppParams {
    public void setParameterMask(long parameterMask) {
        if (parameterMask < 0 || parameterMask > 0xFFFFFFFFL)
            throw new IllegalArgumentException("Out of range, valid range is 0x0000 to 0xFFFFFFFF");
        if(parameterMask == 0) {
           this.parameterMask = INVALID_VALUE_PARAMETER;
        } else {
           this.parameterMask = parameterMask;
        }
    }

    public int getFolderListingSize() {
        return folderListingSize;
+2 −2
Original line number Diff line number Diff line
@@ -18,8 +18,8 @@ import android.os.Handler;
import android.os.Message;
import android.util.Log;

import javax.obex.Authenticator;
import javax.obex.PasswordAuthentication;
import javax.btobex.Authenticator;
import javax.btobex.PasswordAuthentication;

/**
 * BluetoothMapAuthenticator is a used by BluetoothObexServer for obex
+1120 −51

File changed.

Preview size limit exceeded, changes collapsed.

Loading