Skip to content

Commit 64dd551

Browse files
committed
4.2.9-chat-java
1 parent 2cd1271 commit 64dd551

File tree

6 files changed

+20
-133
lines changed

6 files changed

+20
-133
lines changed

sample-chat-java/app/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ android {
2626
applicationId "com.quickblox.sample.chat.java"
2727
minSdkVersion 21
2828
targetSdkVersion 31
29-
versionCode 428000
30-
versionName '4.2.8-java'
29+
versionCode 429000
30+
versionName '4.2.9'
3131
multiDexEnabled true
3232
}
3333

sample-chat-java/app/google-services.json

+4-124
Original file line numberDiff line numberDiff line change
@@ -1,149 +1,29 @@
11
{
22
"project_info": {
3-
"project_number": "247738611464",
3+
"project_number": "Put here your value",
44
"firebase_url": "https://qb-prod-samples.firebaseio.com",
55
"project_id": "qb-prod-samples",
66
"storage_bucket": "qb-prod-samples.appspot.com"
77
},
88
"client": [
99
{
1010
"client_info": {
11-
"mobilesdk_app_id": "1:247738611464:android:beb270faa2c3a789",
11+
"mobilesdk_app_id": "Put here your value",
1212
"android_client_info": {
1313
"package_name": "com.quickblox.sample.chat.java"
1414
}
1515
},
1616
"oauth_client": [],
1717
"api_key": [
1818
{
19-
"current_key": "AIzaSyBFXAfVr6kkFJdDNOm8U-c7iju0qIUkc_A"
19+
"current_key": "Put here your value"
2020
}
2121
],
2222
"services": {
2323
"appinvite_service": {
2424
"other_platform_oauth_client": [
2525
{
26-
"client_id": "247738611464-v2nvd29bmqum7niosnfuh28oq3beh9f6.apps.googleusercontent.com",
27-
"client_type": 3
28-
}
29-
]
30-
}
31-
}
32-
},
33-
{
34-
"client_info": {
35-
"mobilesdk_app_id": "1:247738611464:android:1cdc72e9ffd29448",
36-
"android_client_info": {
37-
"package_name": "com.quickblox.sample.chat.kotlin"
38-
}
39-
},
40-
"oauth_client": [],
41-
"api_key": [
42-
{
43-
"current_key": "AIzaSyBFXAfVr6kkFJdDNOm8U-c7iju0qIUkc_A"
44-
}
45-
],
46-
"services": {
47-
"appinvite_service": {
48-
"other_platform_oauth_client": [
49-
{
50-
"client_id": "247738611464-v2nvd29bmqum7niosnfuh28oq3beh9f6.apps.googleusercontent.com",
51-
"client_type": 3
52-
}
53-
]
54-
}
55-
}
56-
},
57-
{
58-
"client_info": {
59-
"mobilesdk_app_id": "1:247738611464:android:06cb0de4c719ad84",
60-
"android_client_info": {
61-
"package_name": "com.quickblox.sample.pushnotifications.java"
62-
}
63-
},
64-
"oauth_client": [],
65-
"api_key": [
66-
{
67-
"current_key": "AIzaSyBFXAfVr6kkFJdDNOm8U-c7iju0qIUkc_A"
68-
}
69-
],
70-
"services": {
71-
"appinvite_service": {
72-
"other_platform_oauth_client": [
73-
{
74-
"client_id": "247738611464-v2nvd29bmqum7niosnfuh28oq3beh9f6.apps.googleusercontent.com",
75-
"client_type": 3
76-
}
77-
]
78-
}
79-
}
80-
},
81-
{
82-
"client_info": {
83-
"mobilesdk_app_id": "1:247738611464:android:c2749661061637f0",
84-
"android_client_info": {
85-
"package_name": "com.quickblox.sample.pushnotifications.kotlin"
86-
}
87-
},
88-
"oauth_client": [],
89-
"api_key": [
90-
{
91-
"current_key": "AIzaSyBFXAfVr6kkFJdDNOm8U-c7iju0qIUkc_A"
92-
}
93-
],
94-
"services": {
95-
"appinvite_service": {
96-
"other_platform_oauth_client": [
97-
{
98-
"client_id": "247738611464-v2nvd29bmqum7niosnfuh28oq3beh9f6.apps.googleusercontent.com",
99-
"client_type": 3
100-
}
101-
]
102-
}
103-
}
104-
},
105-
{
106-
"client_info": {
107-
"mobilesdk_app_id": "1:247738611464:android:99e5b55a490c901c",
108-
"android_client_info": {
109-
"package_name": "com.quickblox.sample.videochat.java"
110-
}
111-
},
112-
"oauth_client": [],
113-
"api_key": [
114-
{
115-
"current_key": "AIzaSyBFXAfVr6kkFJdDNOm8U-c7iju0qIUkc_A"
116-
}
117-
],
118-
"services": {
119-
"appinvite_service": {
120-
"other_platform_oauth_client": [
121-
{
122-
"client_id": "247738611464-v2nvd29bmqum7niosnfuh28oq3beh9f6.apps.googleusercontent.com",
123-
"client_type": 3
124-
}
125-
]
126-
}
127-
}
128-
},
129-
{
130-
"client_info": {
131-
"mobilesdk_app_id": "1:247738611464:android:ac22e0d1b3a3e86b",
132-
"android_client_info": {
133-
"package_name": "com.quickblox.sample.videochat.kotlin"
134-
}
135-
},
136-
"oauth_client": [],
137-
"api_key": [
138-
{
139-
"current_key": "AIzaSyBFXAfVr6kkFJdDNOm8U-c7iju0qIUkc_A"
140-
}
141-
],
142-
"services": {
143-
"appinvite_service": {
144-
"other_platform_oauth_client": [
145-
{
146-
"client_id": "247738611464-v2nvd29bmqum7niosnfuh28oq3beh9f6.apps.googleusercontent.com",
26+
"client_id": "Put here your value",
14727
"client_type": 3
14828
}
14929
]

sample-chat-java/app/proguard-rules.pro

+4-1
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,7 @@
4343
-keep class com.bumptech.** { *; }
4444

4545
#google gms
46-
-keep class com.google.android.gms.** { *; }
46+
-keep class com.google.android.gms.** { *; }
47+
48+
#json
49+
-keep class org.json.** { *; }

sample-chat-java/app/src/main/java/com/quickblox/sample/chat/java/App.java

+4-4
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
public class App extends Application {
1212

13-
//Chat settings
13+
// chat settings
1414
public static final String USER_DEFAULT_PASSWORD = "quickblox";
1515
public static final int CHAT_PORT = 5223;
1616
public static final int SOCKET_TIMEOUT = 300;
@@ -21,13 +21,13 @@ public class App extends Application {
2121
public static final boolean RECONNECTION_ALLOWED = true;
2222
public static final boolean ALLOW_LISTEN_NETWORK = true;
2323

24-
//App credentials
24+
// app credentials
2525
private static final String APPLICATION_ID = "";
2626
private static final String AUTH_KEY = "";
2727
private static final String AUTH_SECRET = "";
2828
private static final String ACCOUNT_KEY = "";
2929

30-
//Chat settings range
30+
// chat settings range
3131
private static final int MAX_PORT_VALUE = 65535;
3232
private static final int MIN_PORT_VALUE = 1000;
3333
private static final int MIN_SOCKET_TIMEOUT = 300;
@@ -67,7 +67,7 @@ private void initCredentials() {
6767
QBSettings.getInstance().init(getApplicationContext(), APPLICATION_ID, AUTH_KEY, AUTH_SECRET);
6868
QBSettings.getInstance().setAccountKey(ACCOUNT_KEY);
6969

70-
// Uncomment and put your Api and Chat servers endpoints if you want to point the sample
70+
// uncomment and put your Api and Chat servers endpoints if you want to point the sample
7171
// against your own server.
7272
//
7373
// QBSettings.getInstance().setEndpoints("https://your_api_endpoint.com", "your_chat_endpoint", ServiceZone.PRODUCTION);

sample-chat-java/app/src/main/java/com/quickblox/sample/chat/java/utils/NotificationUtils.java

+5-1
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,10 @@ private static PendingIntent buildContentIntent(Context context, Class<? extends
6666
Intent intent = new Intent(context, activityClass);
6767
intent.putExtra(FcmConsts.EXTRA_FCM_MESSAGE, message);
6868
intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
69-
return PendingIntent.getActivity(context, 0, intent, PendingIntent.FLAG_UPDATE_CURRENT);
69+
int intentFlag = 0;
70+
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
71+
intentFlag = PendingIntent.FLAG_IMMUTABLE;
72+
}
73+
return PendingIntent.getActivity(context, 0, intent, intentFlag);
7074
}
7175
}

sample-chat-java/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ ext {
2828
lintAbortOnError = false
2929

3030
// QuickBlox SDK version
31-
qbSdkVersion = '3.9.15'
31+
qbSdkVersion = '3.10.1'
3232

3333
//Firebase
3434
firebaseCoreVersion = '20.1.2'

0 commit comments

Comments
 (0)