Skip to content

Commit

Permalink
Merge branch 'main' into video-player-followups/fix-not-adjusting-vol…
Browse files Browse the repository at this point in the history
…ume-on-press
  • Loading branch information
Skalakid committed Feb 26, 2024
2 parents 9112cce + 9bfe961 commit 075507a
Show file tree
Hide file tree
Showing 385 changed files with 7,421 additions and 4,768 deletions.
5 changes: 5 additions & 0 deletions .github/actions/composite/setupNode/action.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
name: Set up Node
description: Set up Node

outputs:
cache-hit:
description: Was there a cache hit on the main node_modules?
value: ${{ steps.cache-node-modules.outputs.cache-hit }}

runs:
using: composite
steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/failureNotifier.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ jobs:
repo: context.repo.repo,
title: issueTitle,
body: issueBody,
labels: [failureLabel, 'Daily'],
labels: [failureLabel, 'Hourly'],
assignees: [prMerger]
});
}
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/platformDeploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,7 @@ jobs:
run: ./scripts/setup-mapbox-sdk.sh ${{ secrets.MAPBOX_SDK_DOWNLOAD_TOKEN }}

- name: Setup Node
id: setup-node
uses: ./.github/actions/composite/setupNode

- name: Setup Ruby
Expand All @@ -206,7 +207,7 @@ jobs:

- name: Install cocoapods
uses: nick-invision/retry@0711ba3d7808574133d713a0d92d2941be03a350
if: steps.pods-cache.outputs.cache-hit != 'true' || steps.compare-podfile-and-manifest.outputs.IS_PODFILE_SAME_AS_MANIFEST != 'true'
if: steps.pods-cache.outputs.cache-hit != 'true' || steps.compare-podfile-and-manifest.outputs.IS_PODFILE_SAME_AS_MANIFEST != 'true' || steps.setup-node.outputs.cache-hit != 'true'
with:
timeout_minutes: 10
max_attempts: 5
Expand Down
4 changes: 2 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,8 @@ android {
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
multiDexEnabled rootProject.ext.multiDexEnabled
versionCode 1001044306
versionName "1.4.43-6"
versionCode 1001044318
versionName "1.4.43-18"
}

flavorDimensions "default"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
import android.graphics.PorterDuff.Mode;
import android.graphics.PorterDuffXfermode;
import android.graphics.Rect;
import android.media.AudioAttributes;
import android.net.Uri;
import android.os.Build;
import android.os.Bundle;
import android.service.notification.StatusBarNotification;
Expand All @@ -31,6 +33,7 @@
import androidx.core.graphics.drawable.IconCompat;
import androidx.versionedparcelable.ParcelUtils;

import com.expensify.chat.R;
import com.urbanairship.AirshipConfigOptions;
import com.urbanairship.json.JsonMap;
import com.urbanairship.json.JsonValue;
Expand Down Expand Up @@ -105,6 +108,9 @@ protected NotificationCompat.Builder onExtendBuilder(@NonNull Context context, @
builder.setChannelId(CHANNEL_MESSAGES_ID);
} else {
builder.setPriority(PRIORITY_MAX);
// Set sound for versions below Oreo
// for Oreo and above we set sound on the notification's channel level
builder.setSound(getSoundFile(context));
}

// Attempt to parse data and apply custom notification styling
Expand All @@ -130,6 +136,13 @@ private void createAndRegisterNotificationChannel(@NonNull Context context) {
NotificationChannelGroup channelGroup = new NotificationChannelGroup(NOTIFICATION_GROUP_CHATS, CHANNEL_GROUP_NAME);
NotificationChannel channel = new NotificationChannel(CHANNEL_MESSAGES_ID, CHANNEL_MESSAGES_NAME, NotificationManager.IMPORTANCE_HIGH);

AudioAttributes audioAttributes = new AudioAttributes.Builder()
.setContentType(AudioAttributes.CONTENT_TYPE_SONIFICATION)
.setUsage(AudioAttributes.USAGE_NOTIFICATION)
.build();

channel.setSound(getSoundFile(context), audioAttributes);

NotificationManager notificationManager = context.getSystemService(NotificationManager.class);
notificationManager.createNotificationChannelGroup(channelGroup);
notificationManager.createNotificationChannel(channel);
Expand Down Expand Up @@ -333,4 +346,8 @@ private Bitmap fetchIcon(@NonNull Context context, String urlString) {

return null;
}

private Uri getSoundFile(Context context) {
return Uri.parse("android.resource://" + context.getPackageName() + "/" + R.raw.receive);
}
}
1 change: 1 addition & 0 deletions assets/images/folder.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
58 changes: 58 additions & 0 deletions assets/images/product-illustrations/emptystate__expenses.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 075507a

Please sign in to comment.