refactored the getLayoutValue() method for re-use across
@AndroidActivity and @AndroidFragment