예제 #1
0
        public async Task Execute()
        {
            var efiEspVolume = await phone.GetVolumeByPartitionName(PartitionName.EfiEsp);

            efiEspPath        = efiEspVolume.Root;
            destinationFolder = Path.Combine(efiEspVolume.Root, "Windows", "System32", "BOOT");
            bcdPath           = efiEspVolume.Root.CombineRelativeBcdPath();
            bcdInvoker        = bcdInvokerFactory.Create(bcdPath);

            var shouldInstall = !IsAlreadyInstalled();

            if (shouldInstall)
            {
                await CopyDevMenuFiles();
            }

            ConfigureBcd();

            if (shouldInstall)
            {
                await prompt.PickOptions(Resources.DeveloperMenuInstalled, new List <Option>()
                {
                    new Option("Continue", DialogValue.OK),
                });
            }
        }
 public async Task Execute()
 {
     var msg = File.ReadAllText(path);
     await dialog.PickOptions(msg, new List <Option>()
     {
         new Option("Close", DialogValue.OK),
     });
 }
        public async Task Execute()
        {
            var msg    = File.ReadAllText(path);
            var result = await dialog.PickOptions(msg, new List <Option>()
            {
                new Option("Accept", DialogValue.OK),
                new Option("Decline", DialogValue.Cancel),
            });

            if (result.DialogValue == DialogValue.Cancel)
            {
                throw new LicenseAgreementDeclinedException("The license has been declined. Deployment canceled.");
            }
        }