예제 #1
0
        public static bool?Show(string message, string title, bool showCancelButton, DialogWinImage image, UIElement relative)
        {
            DialogWin win   = new DialogWin();
            Window    owner = FindTopWin(relative);

            if (owner != null)
            {
                win.Owner = owner;
                win.WindowStartupLocation = WindowStartupLocation.CenterOwner;
            }
            else
            {
                win.WindowStartupLocation = WindowStartupLocation.CenterScreen;
            }
            win.ViewModel.Content = message;
            win.ViewModel.Image   = image;
            if (title != null)
            {
                win.ViewModel.Title = title;
            }
            win.ViewModel.ButtonCancelVisible = showCancelButton ? Visibility.Visible : Visibility.Collapsed;
            SplitScreenControl.SetCoverVisible(true);
            bool?flag = win.ShowDialog();

            SplitScreenControl.SetCoverVisible(false);
            return(flag);
        }
예제 #2
0
        public static bool?Show(System.Drawing.Image img, string videoName)
        {
            PreviewWin win = new PreviewWin();

            win.ViewModel.VideoName = videoName;
            win.ViewModel.LoadImage(img);
            SplitScreenControl.SetCoverVisible(true);
            bool?flag = win.ShowDialog();

            SplitScreenControl.SetCoverVisible(false);
            return(flag);
        }