smarter method to inflate views

Signed-off-by: ChampionSwimmer <android@championswimmer.tk>