コード例 #1
0
        private void listView_MouseDoubleClick(object sender, MouseButtonEventArgs e)
        {
            CheckoutProfileManagerViewModel manager = DataContext as CheckoutProfileManagerViewModel;

            if (manager.Edit.CanExecute(null))
            {
                manager.Edit.Execute(null);
            }
        }
コード例 #2
0
        private void listView_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            CheckoutProfileManagerViewModel manager = DataContext as CheckoutProfileManagerViewModel;

            foreach (CheckoutProfileRecordViewModel profile in e.AddedItems)
            {
                manager.SelectedProfiles.Add(profile);
            }

            foreach (CheckoutProfileRecordViewModel profile in e.RemovedItems)
            {
                manager.SelectedProfiles.Remove(profile);
            }
        }