improved app structure and view handling