public SearchCategoryView()
        {
            InitializeComponent();

            DataContextChanged += (sender, args) =>
            {
                var viewModel = args.NewValue as CategoriesViewModel;
                if (viewModel != null)
                {
                    viewModel.Closed += () => _dialog?.Close();
                    viewModel.SelectedSearchResults = SearchResultsList.SelectedItems as ObservableCollection <object>;
                }
                PopupContent.DataContext = args.NewValue;
            };
        }
Ejemplo n.º 2
0
 public void Close()
 {
     _dialog?.Close();
 }