Refactored WP application to follow MVVM pattern