private PinnedApp BuildPinnedApp(string filename, string arguments)
        {
            var name = System.Diagnostics.FileVersionInfo.GetVersionInfo(filename).FileDescription;
            var path = FormatShortcutName(name);

            if (!Directory.Exists(_userDataPath))
            {
                Directory.CreateDirectory(_userDataPath);
            }

            ShortcutUtil.CreateShortcut(filename, arguments, path);

            return(CreateShortCutAndBuildApp(path));
        }
        private PinnedApp BuildPinnedApp(Process process)
        {
            var fi   = new FileInfo(process.MainModule.FileName);
            var name = System.Diagnostics.FileVersionInfo.GetVersionInfo(process.MainModule.FileName).FileDescription;
            var path = FormatShortcutName(name);

            if (!Directory.Exists(_userDataPath))
            {
                Directory.CreateDirectory(_userDataPath);
            }

            // try to get full path including arguments
            string arguments = ProcessUtil.GetCommandLineArguments(process.MainModule.ModuleName);

            ShortcutUtil.CreateShortcut(process.MainModule.FileName, arguments, path);

            return(CreateShortCutAndBuildApp(path));
        }