Przeglądaj źródła

feat(android) extract notification channel name

master
tmoldovan8x8 4 lat temu
rodzic
commit
6124e72f21
No account linked to committer's email address

+ 0
- 1
android/sdk/src/main/java/org/jitsi/meet/sdk/NotificationChannels.java Wyświetl plik

5
 
5
 
6
 public class NotificationChannels {
6
 public class NotificationChannels {
7
     static final String ONGOING_CONFERENCE_CHANNEL_ID = "JitsiOngoingConferenceChannel";
7
     static final String ONGOING_CONFERENCE_CHANNEL_ID = "JitsiOngoingConferenceChannel";
8
-    static final String ONGOING_CONFERNCE_CHANNEL_NAME = "Ongoing Conference Notifications";
9
 
8
 
10
     public static List<String> allIds = new ArrayList<String>() {{ add(ONGOING_CONFERENCE_CHANNEL_ID); }};
9
     public static List<String> allIds = new ArrayList<String>() {{ add(ONGOING_CONFERENCE_CHANNEL_ID); }};
11
 }
10
 }

+ 1
- 2
android/sdk/src/main/java/org/jitsi/meet/sdk/OngoingNotification.java Wyświetl plik

17
 package org.jitsi.meet.sdk;
17
 package org.jitsi.meet.sdk;
18
 
18
 
19
 import static org.jitsi.meet.sdk.NotificationChannels.ONGOING_CONFERENCE_CHANNEL_ID;
19
 import static org.jitsi.meet.sdk.NotificationChannels.ONGOING_CONFERENCE_CHANNEL_ID;
20
-import static org.jitsi.meet.sdk.NotificationChannels.ONGOING_CONFERNCE_CHANNEL_NAME;
21
 
20
 
22
 import android.app.Notification;
21
 import android.app.Notification;
23
 import android.app.NotificationChannel;
22
 import android.app.NotificationChannel;
66
             return;
65
             return;
67
         }
66
         }
68
 
67
 
69
-        channel = new NotificationChannel(ONGOING_CONFERENCE_CHANNEL_ID, ONGOING_CONFERNCE_CHANNEL_NAME, NotificationManager.IMPORTANCE_DEFAULT);
68
+        channel = new NotificationChannel(ONGOING_CONFERENCE_CHANNEL_ID, context.getString(R.string.ongoing_notification_action_unmute), NotificationManager.IMPORTANCE_DEFAULT);
70
         channel.enableLights(false);
69
         channel.enableLights(false);
71
         channel.enableVibration(false);
70
         channel.enableVibration(false);
72
         channel.setShowBadge(false);
71
         channel.setShowBadge(false);

+ 1
- 0
android/sdk/src/main/res/values/strings.xml Wyświetl plik

6
     <string name="ongoing_notification_action_hang_up">Hang up</string>
6
     <string name="ongoing_notification_action_hang_up">Hang up</string>
7
     <string name="ongoing_notification_action_mute">Mute</string>
7
     <string name="ongoing_notification_action_mute">Mute</string>
8
     <string name="ongoing_notification_action_unmute">Unmute</string>
8
     <string name="ongoing_notification_action_unmute">Unmute</string>
9
+    <string name="ongoing_notification_channel_name">Ongoing Conference Notifications</string>
9
 </resources>
10
 </resources>

Ładowanie…
Anuluj
Zapisz