Customized Display
This in an Android app that shows the current time, day and date with an ever changing background colour. I had an old Android tablet lying around and wanted a convenient digital clock that displays time and date in a format I liked. The app automatically puts the device in landscape mode when started and hides the navigation buttons going into fullscreen mode. The background was a bit too plain, hence I made a function to have the colour change constantly in a cycle that’s completely random.
So to have a smooth transition of colours, the method (generateNew) accepts the previous colour and sets that as the starting point of the colour cycle while adding three additional colours. The method colorAnimations cycles through the colours creating a nice appealing look on the screen.
Source Code on GitHub