FredJul / Flym

Flym News Reader is a light Android feed reader (RSS/Atom)
Other
955 stars 405 forks source link

Update to API 30 and use new APIs for fullscreen/system bars #654

Closed fireph closed 3 years ago

fireph commented 3 years ago

API 30 deprecates a ton of things including the way to do fullscreen apps underneath the status bar/navigation bar. This updates the app to work on API 30 and adds if/else for these new inset/window APIs.

Also fixes a crash when swiping is disabled on entry fragment.

FredJul commented 3 years ago

Hi,

I can't really test because I have several others bugs with API 30 that I will try to fix before merging your PR. Does it fix issues that I mentioned into https://github.com/FredJul/Flym/pull/648 ?

fireph commented 3 years ago

@FredJul Ah I didn't think about that edge case 🤦‍♂️ my bad.

The easiest solution is probably to have the FAB buton disappear when scrolling down just like the BottomNavigationView

I added that to this PR (but there is a small alignment issue with the snackbar, maybe the snackbar should go at the top rather than the bottom since the bottom is kind of busy?)

So yes, this PR fixes the issues you mentioned in https://github.com/FredJul/Flym/pull/648

2020-08-31_17-39-37

FredJul commented 3 years ago

Great, that solution is OK for me. But now I have another issue: snackbars (like the "article is read" one) are now above the FAB and it's not pretty

fireph commented 3 years ago

I can probably fix that, but I will need a create a custom behavior for the FAB to put the snackbars below the FAB. I can probably get a PR out for it tomorrow :)

FredJul commented 3 years ago

And for information I still have a bug where the bottom bar sometimes does not reappear (even with a scroll up). That one is a bit problematic and I'm not sure why it appears exactly.

FredJul commented 3 years ago

Actually I just found a way to reproduce: 1/ scroll down the list: the bottom bar disapeared 2/ press the android home button and relaunch the app by pressing the Flym icon on the launcher 3/ scroll up: the bottom bar does not reappear 4/ scroll down and up again: then it reappears (but it should have reappear from the first scroll up)

fireph commented 3 years ago

I'll try to debug why the bottom bar doesn't appear when relaunching the app... Might be an issue with the support library behavior and I might have to make a custom one

fireph commented 3 years ago

I fixed the issue with the bottom bar not appearing when scrolling up, just need to figure out a good spot for the snackbar

fireph commented 3 years ago

I finally figured out how to fix all the issues with the snackbar not showing up in the right spot. It all works perfectly now :)

2020-09-08_15-31-50

FredJul commented 3 years ago

Great job 👍 seems to work very well