Open a card from the lockscreen widget without unlock#3091
Open a card from the lockscreen widget without unlock#3091hipgnose wants to merge 4 commits intoCatimaLoyalty:mainfrom
Conversation
Yeah, known issue. See #2124 and #2460 Do you have any idea how I can test this change btw? Fairphone 6 doesn't seem to have lock screen widgets and neither does the Android 17 emulator in Android Studio. |
|
This is tricky and I still don't have a good answer for you, I'll add here what I found primarily for documentation.
So for now I can only test this with my device (GrapheneOS) and don't know how you can reproduce and test. I can try to run the GrapheneOS in the emulator, do you think it would work for you? I don't know another Android build with the lock screen widgets feature enable /: |
|
I was looking for a way to test but I don't think there is an emulator build available for GrapheneOS, so one step would be to actually build the image and I think it's too much to ask haha |
To open the activity over the lockscreen we can't use the
setShowWhenLocked(true), we need to define the activity manifest asshowWhenLocked=true, as stated in the Android Developers FAQ.This PR adds the manifest configuration needed to open the activity and disable/hide the activity if the user chose
DisableLockscreenWhileViewingCardsettingIn the first commit I was finishing the activity if
DisableLockscreenWhileViewingCardwas off and the lockscreen was up, but I figured out that we can just callshowWhenLocked(false)and the activity is sent to behind the lockscreen again.Notes:
startWithLoyaltyCardNoExpirySetExpiryis failing for me, it says it expected April 22 but receives April 21, I don't know why but maybe it 's something with my timezone?Fixes #2916