Changed usage of ViewTreeObserver in favor of View.post()