/// <summary>
        /// Initializes a new instance of the Add Download window.
        /// </summary>
        public static AddDownload Instance(ClosingCallback callback)
        {
            AddDownload NewForm = new AddDownload();

            NewForm.callback = callback;
            SessionCore.Instance.Windows.Show(NewForm);
            return(NewForm);
        }
 /// <summary>
 /// Displays a window to edit specified video.
 /// </summary>
 public static EditVideoWindow Instance(Guid? videoId, string fileName, IMediaPlayerBusiness player, ClosingCallback callback) {
     EditVideoWindow NewForm = new EditVideoWindow();
     if (videoId != null && videoId != Guid.Empty)
         NewForm.videoId = videoId;
     else
         NewForm.fileName = fileName;
     NewForm.player = player;
     NewForm.callback = callback;
     SessionCore.Instance.Windows.Show(NewForm);
     return NewForm;
 }
 /// <summary>
 /// Displays a popup containing the FileBinding menu features.
 /// </summary>
 public static EditVideoWindow InstancePopup(UIElement target, PlacementMode placement, Guid? videoId, string fileName, IMediaPlayerBusiness player, ClosingCallback callback) {
     EditVideoWindow NewForm = new EditVideoWindow();
     NewForm.isPopup = true;
     NewForm.videoId = videoId;
     if (videoId != null && videoId != Guid.Empty)
         NewForm.videoId = videoId;
     else
         NewForm.fileName = fileName;
     NewForm.player = player;
     NewForm.callback = callback;
     WindowHelper.SetScale(NewForm.FileBindingButton.ContextMenu);
     NewForm.Window_Loaded(null, null);
     NewForm.ShowFileBindingMenu(target, placement);
     return NewForm;
 }
        /// <summary>
        /// Displays a window to edit specified video.
        /// </summary>
        public static EditVideoWindow Instance(Guid?videoId, string fileName, ClosingCallback callback)
        {
            EditVideoWindow NewForm = new EditVideoWindow();

            if (videoId != null && videoId != Guid.Empty)
            {
                NewForm.videoId = videoId;
            }
            else
            {
                NewForm.fileName = fileName;
            }
            NewForm.callback = callback;
            SessionCore.Instance.Windows.Show(NewForm);
            return(NewForm);
        }
        /// <summary>
        /// Displays a popup containing the FileBinding menu features.
        /// </summary>
        public static EditVideoWindow InstancePopup(UIElement target, PlacementMode placement, Guid?videoId, string fileName, ClosingCallback callback)
        {
            EditVideoWindow NewForm = new EditVideoWindow();

            NewForm.isPopup = true;
            NewForm.videoId = videoId;
            if (videoId != null && videoId != Guid.Empty)
            {
                NewForm.videoId = videoId;
            }
            else
            {
                NewForm.fileName = fileName;
            }
            NewForm.callback = callback;
            WindowHelper.SetScale(NewForm.FileBindingButton.ContextMenu);
            NewForm.Window_Loaded(null, null);
            NewForm.ShowFileBindingMenu(target, placement);
            return(NewForm);
        }
 /// <summary>
 /// Initializes a new instance of the Add Download window.
 /// </summary>
 public static AddDownload Instance(ClosingCallback callback) {
     AddDownload NewForm = new AddDownload();
     NewForm.callback = callback;
     SessionCore.Instance.Windows.Show(NewForm);
     return NewForm;
 }