Refactored window xaml