Tag Archives: OnGlobalLayoutListener

Android: Get the size of a custom view before display.

When developing applications or simple games for Android where you are drawing or writing to a view, an issue arises upon startup of the view. In my case I had a game where I wanted to calculate screen tile size before the game view starts, but with most tutorials I had seen everything happened after the view was fully running. That turned into a chicken and the egg scenario. I … Continue reading

Posted in Android, Java | Tagged , , , , | Comments