Exemplo n.º 1
0
        // si appuie sur la photo de l utilisateur
        private void ImgUser_MouseDown(object sender, MouseButtonEventArgs e)
        {
            Infos infoWindows = new Infos(User, User);

            infoWindows.ShowDialog();
            if (infoWindows.IsModified)
            {
                User = PersonneManager.GetUserLogin(User.Courriel, User.Password);
                this.ImgUser.Source  = new BitmapImage(new Uri(@"" + User.UrlPhoto, UriKind.RelativeOrAbsolute));
                this.NomUser.Content = User.Nom;
            }
        }
Exemplo n.º 2
0
        // Handler pour afficher info Contact
        private void InfoContact(object sender, RoutedEventArgs e)
        {
            Button   b       = (Button)sender;
            Personne contact = (Personne)b.DataContext;

            Infos infoWindows = new Infos(User, contact);

            infoWindows.ShowDialog();
            if (infoWindows.IsModified)
            {
                User.ListeContact   = ContactManager.GetListeContactsByUserId(User.Id);
                User.ListePersonnes = PersonneManager.GetListePersonnesByListeContacts(User.ListeContact);
                ListeContactVue.Children.Clear();
                //reafficher le stackPanel avec la nouvelle liste
                ajouterContactTrier(User.ListeContact, User.ListePersonnes);
            }
            infoWindows.Close();
        }