Esempio n. 1
0
        private void ToastTask()
        {
            var newNotification = new Notification()
            {
                //ImgURL = "Resources\\blue3.jpg",
                Title   = "Machine error",
                Message = "Error!! Please check your Machine Code and Try Again"
            };

            for (; ;)
            {
                App.Current.Dispatcher?.Invoke(() =>
                {
                    _dailogService.ShowNotificationWindow(newNotification);
                });

                Thread.Sleep(5 * 1000);
            }
        }
Esempio n. 2
0
        public static void ShowDialog(this FrameworkElement element, string key)
        {
            element.Dispatcher.Invoke(() =>
            {
                var newNotification = new MyNotification()
                {
                    Title   = LocaleUtil.GetString("Tips"),
                    Content = LocaleUtil.GetString(key)
                };

                dailogService.ShowNotificationWindow(newNotification, configuration);
            });
        }