-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Icon rounding issue resolved #6770
Icon rounding issue resolved #6770
Conversation
CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅ |
@rafaysaleem89 Could you please sign the CLA? |
@Julesssss Could you please review this? i |
I have read the CLA Document and I hereby sign the CLA |
bitmap.getHeight(), Config.ARGB_8888); | ||
Canvas canvas = new Canvas(output); | ||
|
||
final int color = 0xff424242; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What colour? Improve var name please.
|
||
public Bitmap getCroppedBitmap(Bitmap bitmap) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add a comment to the function explaining what it's doing.
Updated |
Hi @rafaysaleem89, the code looks good but I struggled with building to native Android devices (some dependency issues, ect). I'll aim to build and confirm Monday morning. |
Sorry this code looks good but I'm not able to get push notifications working on Android at all and can't seem to figure out why. Also won't be able to get to this until next week. |
Guessing they are just not working on dev and need to use the staging server. |
Oh LOL I recently removed my SIM card so I think they can't work anymore. Going to unassign myself here as I'm unable to test. |
I had further trouble today and didn't get around to this, but I did resolve the release build issues. Back on this tomorrow! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not an Android guy but the code looks neat. and have one question. I leave reviewing and merging to @Julesssss. thanks.
bitmap.getHeight(), Config.ARGB_8888); | ||
Canvas canvas = new Canvas(output); | ||
|
||
final int defaultBackgroundColor = 0xff424242; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this color used only for masking? If this is shown on the notification then we need to make it theme-specific.
e.g. Dark mode
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This color is the fill color for the circle that will be drawn in the background. I don't think that it will ever be shown as there will always be a bitmap drawn on top of it. But we could make it theme specific just in case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was expecting to see the user's actual profile picture, but this isn't the case. Is that expected @rafaysaleem89?
Android 8
No profile image is displayed
Android 12
Profile image is displayed, but it is not the actual custom image
@Julesssss how do you want to proceed on this? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks fine to me.
Hi @rafaysaleem89, sorry for the delay, I have been off over Christmas and NY. I should have merged previously, as clearly the missing profile is an unrelated issue. |
@rafaysaleem89, Great job getting your first Expensify/App pull request over the finish line! 🎉 I know there's a lot of information in our contributing guidelines, so here are some points to take note of 📝:
So it might take a while before you're paid for your work, but we typically post multiple new jobs every day, so there's plenty of opportunity. I hope you've had a positive experience contributing to this repo! 😊 |
🚀 Deployed to staging by @Julesssss in version: 1.1.24-21 🚀
|
This failure is due to an existing issue that has now been fixed. At the time of the merge, main hadn't recieved the hotfix. |
@Julesssss @parasharrajat |
Hi @mvtglobally, just Android please. |
🚀 Deployed to production by @francoisl in version: 1.1.25-1 🚀
|
Heads up! This PR caused an issue related to Avatar images on android #12967. Note for me: Although, I am assigned to C+ here Neither I tested/approved it nor did I get paid for this. I handed it over to Jules #6770 (comment) due to unfamiliarity with the native code. |
Details
The android push notification icon will now be rounded. For some reason the push notifications weren't working on the debug build, so had to do my tests on release builds.
Fixed Issues
The Custom Notification Provider was being used to make a custom layout for notifications in which a bitmap was being used for user's avatar which was being displayed in a. square shape. I added the code to clip the bitmap over a circular path to fix this issue.
$ #6132
Tests
QA Steps
Add a numbered list of manual tests that can be performed by our QA engineers on the staging environment to validate that 1. Log in with account A on Android
2. Log in with account B on web
3. Send some message from account B to account A
4. Check the push notifications now the user avatar is rounded.
Tested On
Screenshots
Add screenshots for all platforms tested. Pull requests won't be merged unless the screenshots show the app was
tested on all platforms
(This was an Android only issue hence only added screen shot of Android)
Android