Ejemplo n.º 1
0
        private void DetectPs3DiscGame(object sender, DoWorkEventArgs doWorkEventArgs)
        {
            var dumper = (Dumper)doWorkEventArgs.Argument;

            try
            {
                dumper.DetectDisc(d =>
                {
                    var items = new NameValueCollection
                    {
                        [Patterns.ProductCode]        = d.ProductCode,
                        [Patterns.ProductCodeLetters] = d.ProductCode?.Substring(0, 4),
                        [Patterns.ProductCodeNumbers] = d.ProductCode?.Substring(4),
                        [Patterns.Title]  = d.Title,
                        [Patterns.Region] = RegionMapping[d.ProductCode?.Substring(2, 1) ?? ""],
                    };
                    return(PatternFormatter.Format(settings.DumpNameTemplate, items));
                });
            }
            catch { }
            doWorkEventArgs.Result = dumper;
        }
Ejemplo n.º 2
0
 private void namePatternTextBox_TextChanged(object sender = null, EventArgs e = null)
 {
     namePatternExampleLabel.Text = PatternFormatter.Format(namePatternTextBox.Text.Trim(), TestItems);
 }