Some refactor before adjusting LinearLayout to enable recursion