/* ----------------------------------------------------------------- */
        ///
        /// Open
        ///
        /// <summary>
        /// Opens the first item of the specified collection.
        /// </summary>
        ///
        /// <param name="src">Facade object.</param>
        /// <param name="files">File collection.</param>
        ///
        /* ----------------------------------------------------------------- */
        public static void Open(this MainFacade src, IEnumerable <string> files)
        {
            var path = src.GetFirst(files);

            if (path.HasValue())
            {
                src.Open(path);
            }
        }
        /* ----------------------------------------------------------------- */
        ///
        /// Setup
        ///
        /// <summary>
        /// Invokes some actions through the specified arguments.
        /// </summary>
        ///
        /// <param name="src">Facade object.</param>
        /// <param name="args">User arguments.</param>
        ///
        /* ----------------------------------------------------------------- */
        public static void Setup(this MainFacade src, IEnumerable <string> args)
        {
            foreach (var ps in src.Settings.GetSplashProcesses())
            {
                ps.Kill();
            }
            var path = src.GetFirst(args);

            if (path.HasValue())
            {
                src.Open(path);
            }
            src.Backup.Cleanup();
        }
 /* ----------------------------------------------------------------- */
 ///
 /// OpenLink
 ///
 /// <summary>
 /// Opens a PDF document with the specified link.
 /// </summary>
 ///
 /// <param name="src">Facade object.</param>
 /// <param name="link">Information for the link.</param>
 ///
 /* ----------------------------------------------------------------- */
 public static void OpenLink(this MainFacade src, Information link)
 {
     try { src.Open(Shortcut.Resolve(link?.FullName)?.Target); }
     catch (Exception e)
     {
         var cancel = e is OperationCanceledException ||
                      e is TwiceException;
         if (!cancel)
         {
             src.Bindable.IO.TryDelete(link?.FullName);
         }
         throw;
     }
 }