OlivierTD / team-rocket

Team Rocket working on OSS AntennaPod
MIT License
1 stars 1 forks source link

Homepage now redirects to a new search page for the centralized search + random episode button #153

Closed batoulyehia closed 3 years ago

batoulyehia commented 6 years ago

In this pull request, I fixed the redirect to home page when the app is first launched, and it leads to another page when you press on the search button on top.

batoulyehia commented 6 years ago

UI tests have now been modified to be consistent with new design

SaiShan commented 6 years ago

Functionality works fine for me. The log.d that i pointed out can be remove. Good job.

batoulyehia commented 6 years ago

I know that the idea was to have a button on the action bar for the random podcast button, however, when I tried implementing it, the application would crash because I removed the centralized search fragment from the homepage fragment. It only worked when both the centralized fragment and the random episode button were on the same page. I'm looking into modifying it though and try to get it work the other way. Thank you for review Olivier, I'll do my best to make it work.

OlivierTD commented 6 years ago

I do not see how both these buttons should be clashing. Try to talk to whoever implemented the code if you can't figure it out.

batoulyehia commented 6 years ago

The functionality now works!!!!! 😄 I found a way around having to deal with fixing the random button issue. I made it so that when you get redirected to the next page, the keyboard appears and the view of the action bar is expanded. So, the user doesn't have to click twice on the search button, it won't bug them.

batoulyehia commented 6 years ago

The issue with keeping the random button is that if the random button stays on the home page, it won't work. The application will crash as long as the search results aren't loaded on the homepage itself. That was my solution to it. Nothing else worked. And if you press on the back button, the keyboard will disappear, but if you press it again then you'll be redirected to the homepage.

batoulyehia commented 6 years ago

Functionality working now like how we discussed it before. Ready for merge.

batoulyehia commented 6 years ago

I did some refactoring, and now what it does when you press back is that it returns you to the previous search you made. I'll fix the title right away though

OlivierTD commented 6 years ago

Tests are failing on your branch and codeclimate has issues for you to address.

OlivierTD commented 6 years ago

You have conflicts with the master branch now.

OlivierTD commented 6 years ago

if I perform multiple searches and then press back really fast it crashes the app.

I do not think we should be "stacking" the searches that a user does. I think that whenever a user presses back, it should bring them back to the homepage, no matter the amount of search they did. It would probably not make the app crash like it is doing right now.