Exemplo n.º 1
0
        public static void ShowCallNotification(Contact contact, string UDPAddress, int Port)
        {
            SoundManager.VoiceRingingSound.PlayLooping();

            NotificationWindow wnd = new NotificationWindow(true);

            wnd.Left = (SystemParameters.FullPrimaryScreenWidth - wnd.Width) - 10;
            wnd.Top  = 10;
            wnd.txt_notificationtitle.Content = "Incoming Call From " + contact.NickName;
            wnd.txt_notificationcontent.Text  = "";

            wnd.btn_call_accept.Visibility = Visibility.Visible;
            wnd.btn_call_deny.Visibility   = Visibility.Visible;
            wnd.profile_image.Visibility   = Visibility.Visible;

            wnd.profile_image_source.ImageSource = new System.Windows.Media.Imaging.BitmapImage(new Uri("https://blaze-games.com/api/image/nocompress/?nickname=" + contact.NickName));

            wnd.UDPAddress = UDPAddress;
            wnd.Port       = Port;
            wnd.contact    = contact;

            wnd.Show();
            Windows.Add(wnd);
            ReDraw();
        }
Exemplo n.º 2
0
        public static void ShowNotification(string Title, string Message, Contact contact)
        {
            NotificationWindow wnd = new NotificationWindow();

            wnd.Left = (SystemParameters.FullPrimaryScreenWidth - wnd.Width) - 10;
            wnd.Top  = 10;
            wnd.txt_notificationtitle.Content = Title;
            wnd.txt_notificationcontent.Text  = Message;
            wnd.Show();
            Windows.Add(wnd);
            ReDraw();
        }