Skip to content

Commit

Permalink
Merge pull request #387 from apptentive/next
Browse files Browse the repository at this point in the history
Merge next to master for 3.4.0 release
  • Loading branch information
skykelsey authored Dec 8, 2016
2 parents b3ef339 + c0abb2d commit ec184c5
Show file tree
Hide file tree
Showing 120 changed files with 2,934 additions and 3,953 deletions.
15 changes: 14 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,17 @@
# 2016-10-?? - 3.3.0
# 2016-12-07 - 3.4.0

#### Improvements

* Rebuilt Message Center to use modern `RecyclerView` for better performance and stability.
* Improved accessibility of our UI, including TalkBack support and fixing hit target sizes.
* Improved version targeting

#### Bugs Fixed

* Fixed a bug where the Profile Card in Message Center wouldn't let a user focus the email field.
* Fixed a bug where the Survey "thank you" message text was the wrong color.

# 2016-10-21 - 3.3.0

#### Improvements

Expand Down
13 changes: 7 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,18 @@
The Apptentive Android SDK is the best way to engage your mobile customers. Use it to learn about how your customers
use your app, to talk to them at the right time, and in the right way.

#### To get started, read our [Integration Guide](http://www.apptentive.com/docs/android/integration/)
#### To get started, read our [Integration Guide](https://learn.apptentive.com/knowledge-base/android-integration/)

#### Learn about SDK Features [Features](http://www.apptentive.com/docs/android/features/)

#### Browse the [Client API](http://www.apptentive.com/docs/android/api)
#### [Android Interface Customization](https://learn.apptentive.com/knowledge-base/interface-customization-android/)
#### [Apptentive SDK API Javadoc](http://www.apptentive.com/docs/android/api)

##### API Changes are tracked [here](docs/APIChanges.md)
##### [API Changes here](docs/APIChanges.md)

##### Version history is tracked [here](CHANGELOG.md)
##### [Release Notes](https://learn.apptentive.com/knowledge-base/android-sdk-releases-notes/)

##### Binary releases are hosted for Maven [here](http://search.maven.org/#artifactdetails|com.apptentive|apptentive-android|3.3.0|aar)
##### Binary releases are hosted for Maven [here](http://search.maven.org/#artifactdetails|com.apptentive|apptentive-android|3.4.0|aar)

#### Reporting Bugs

Expand All @@ -26,5 +27,5 @@ We appreciate contributions to make this SDK better. If you have an improvement

#### Notes

* Make sure you have latest version or our SDK. We're always adding new features!
* Make sure you have latest version of our SDK. We're always adding new features!
* Make sure to follow the repo to get updates about features and bug fixes.
1 change: 1 addition & 0 deletions apptentive/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ task androidJavadocs(type: Javadoc) {
include 'com/apptentive/android/sdk/module/rating/IRatingProvider.java'
include 'com/apptentive/android/sdk/module/messagecenter/UnreadMessagesListener.java'
include 'com/apptentive/android/sdk/module/survey/OnSurveyFinishedListener.java'
include 'com/apptentive/android/sdk/model/CustomData.java'
include 'com/apptentive/android/sdk/model/ExtendedData.java'
include 'com/apptentive/android/sdk/model/CommerceExtendedData.java'
include 'com/apptentive/android/sdk/model/LocationExtendedData.java'
Expand Down
11 changes: 6 additions & 5 deletions apptentive/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
~ Copyright (c) 2015, Apptentive, Inc. All Rights Reserved.
~ Copyright (c) 2016, Apptentive, Inc. All Rights Reserved.
~ Please refer to the LICENSE file for the terms and conditions
~ under which redistribution and use of this file is permitted.
-->

<manifest
package="com.apptentive.android.sdk"
xmlns:android="http://schemas.android.com/apk/res/android">
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.apptentive.android.sdk">
<!-- Required for Apptentive -->
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<!-- Optional for Apptentive -->
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>

<application>
<activity android:name="com.apptentive.android.sdk.ApptentiveViewActivity" android:theme="@style/ApptentiveTheme.Base.Versioned"/>
<activity android:name="com.apptentive.android.sdk.ApptentiveViewActivity"
android:theme="@style/ApptentiveTheme.Base.Versioned"/>
</application>
</manifest>
51 changes: 22 additions & 29 deletions apptentive/src/main/java/com/apptentive/android/sdk/Apptentive.java
Original file line number Diff line number Diff line change
Expand Up @@ -17,25 +17,31 @@
import android.text.TextUtils;
import android.webkit.MimeTypeMap;

import com.apptentive.android.sdk.model.*;
import com.apptentive.android.sdk.model.CommerceExtendedData;
import com.apptentive.android.sdk.model.CustomData;
import com.apptentive.android.sdk.model.ExtendedData;
import com.apptentive.android.sdk.model.LocationExtendedData;
import com.apptentive.android.sdk.model.StoredFile;
import com.apptentive.android.sdk.model.TimeExtendedData;
import com.apptentive.android.sdk.module.engagement.EngagementModule;
import com.apptentive.android.sdk.module.messagecenter.MessageManager;
import com.apptentive.android.sdk.module.messagecenter.UnreadMessagesListener;
import com.apptentive.android.sdk.module.messagecenter.model.CompoundMessage;
import com.apptentive.android.sdk.module.metric.MetricModule;
import com.apptentive.android.sdk.module.rating.IRatingProvider;
import com.apptentive.android.sdk.module.survey.OnSurveyFinishedListener;
import com.apptentive.android.sdk.storage.*;
import com.apptentive.android.sdk.storage.DeviceManager;
import com.apptentive.android.sdk.storage.PersonManager;
import com.apptentive.android.sdk.util.Constants;
import com.apptentive.android.sdk.util.Util;

import org.json.JSONException;
import org.json.JSONObject;

import java.io.ByteArrayInputStream;

import java.io.InputStream;
import java.util.*;
import java.util.ArrayList;
import java.util.Map;

/**
* This class contains the complete API for accessing Apptentive features from within your app.
Expand Down Expand Up @@ -471,7 +477,7 @@ public static boolean isApptentivePushNotification(Intent intent) {
* Determines whether this Bundle came from an Apptentive push notification. This method is used with Urban Airship
* integrations.
*
* @param bundle The push payload bundle paseed to GCM onMessageReceived() callback
* @param bundle The push payload bundle passed to GCM onMessageReceived() callback
* @return True if the push came from, and should be handled by Apptentive.
*/
public static boolean isApptentivePushNotification(Bundle bundle) {
Expand All @@ -495,23 +501,19 @@ public static boolean isApptentivePushNotification(Map<String, String> data) {
}

/**
* <p>
* Use this method in your push receiver to build a pending Intent when an Apptentive push
* <p>Use this method in your push receiver to build a pending Intent when an Apptentive push
* notification is received. Pass the generated PendingIntent to
* {@link android.support.v4.app.NotificationCompat.Builder#setContentIntent} to allow Apptentive
* to display Interactions such as Message Center. This method replaces the deprecated
* {@link #setPendingPushNotification(Intent)}. Calling this method for a push {@Intent} that did
* {@link #setPendingPushNotification(Intent)}. Calling this method for a push {@link Intent} that did
* not come from Apptentive will return a null object. If you receive a null object, your app will
* need to handle this notification itself.
* </p>
* <p>
* This is the method you will likely need if you integrated using:
* need to handle this notification itself.</p>
* <p>This is the method you will likely need if you integrated using:</p>
* <ul>
* <li>GCM</li>
* <li>AWS SNS</li>
* <li>Parse</li>
* </ul>
* </p>
*
* @param intent An {@link Intent} containing the Apptentive Push data. Pass in what you receive
* in the Service or BroadcastReceiver that is used by your chosen push provider.
Expand All @@ -526,21 +528,17 @@ public static PendingIntent buildPendingIntentFromPushNotification(@NonNull Inte
}

/**
* <p>
* Use this method in your push receiver to build a pending Intent when an Apptentive push
* <p>Use this method in your push receiver to build a pending Intent when an Apptentive push
* notification is received. Pass the generated PendingIntent to
* {@link android.support.v4.app.NotificationCompat.Builder#setContentIntent} to allow Apptentive
* to display Interactions such as Message Center. This method replaces the deprecated
* {@link #setPendingPushNotification(Bundle)}. Calling this method for a push {@link Bundle} that
* did not come from Apptentive will return a null object. If you receive a null object, your app
* will need to handle this notification itself.
* </p>
* <p>
* This is the method you will likely need if you integrated using:
* will need to handle this notification itself.</p>
* <p>This is the method you will likely need if you integrated using:</p>
* <ul>
* <li>Urban Airship</li>
* </ul>
* </p>
*
* @param bundle A {@link Bundle} containing the Apptentive Push data. Pass in what you receive in
* the the Service or BroadcastReceiver that is used by your chosen push provider.
Expand All @@ -555,21 +553,17 @@ public static PendingIntent buildPendingIntentFromPushNotification(@NonNull Bund
}

/**
* <p>
* Use this method in your push receiver to build a pending Intent when an Apptentive push
* <p>Use this method in your push receiver to build a pending Intent when an Apptentive push
* notification is received. Pass the generated PendingIntent to
* {@link android.support.v4.app.NotificationCompat.Builder#setContentIntent} to allow Apptentive
* to display Interactions such as Message Center. This method replaces the deprecated
* {@link #setPendingPushNotification(Bundle)}. Calling this method for a push {@link Bundle} that
* did not come from Apptentive will return a null object. If you receive a null object, your app
* will need to handle this notification itself.
* </p>
* <p>
* This is the method you will likely need if you integrated using:
* will need to handle this notification itself.</p>
* <p>This is the method you will likely need if you integrated using:</p>
* <ul>
* <li>Firebase Cloud Messaging (FCM)</li>
* </ul>
* </p>
*
* @param data A {@link Map}&lt;{@link String},{@link String}&gt; containing the Apptentive Push
* data. Pass in what you receive in the the Service or BroadcastReceiver that is
Expand Down Expand Up @@ -1086,8 +1080,7 @@ public static void sendAttachmentFile(InputStream is, String mimeType) {
message.setSenderId(ApptentiveInternal.getInstance().getPersonId());

ArrayList<StoredFile> attachmentStoredFiles = new ArrayList<StoredFile>();
String localFilePath = Util.generateCacheFilePathFromNonceOrPrefix(ApptentiveInternal.getInstance().getApplicationContext(),
message.getNonce(), null);
String localFilePath = Util.generateCacheFilePathFromNonceOrPrefix(ApptentiveInternal.getInstance().getApplicationContext(), message.getNonce(), null);

String extension = MimeTypeMap.getSingleton().getExtensionFromMimeType(mimeType);
if (!TextUtils.isEmpty(extension)) {
Expand Down
Loading

0 comments on commit ec184c5

Please sign in to comment.