Esempio n. 1
0
 public SAV_Link6(SaveFile sav)
 {
     InitializeComponent();
     WinFormsUtil.TranslateInterface(this, Main.CurrentLanguage);
     SAV = (ISaveBlock6Main)(Origin = sav).Clone();
     foreach (var cb in TAB_Items.Controls.OfType <ComboBox>())
     {
         cb.InitializeBinding();
         cb.DataSource = new BindingSource(GameInfo.ItemDataSource.Where(item => item.Value <= sav.MaxItemID).ToArray(), null);
     }
     LinkInfo = SAV.Link.GetLinkInfo();
     LoadLinkData();
 }
Esempio n. 2
0
        public SAV_Pokepuff(SaveFile sav)
        {
            InitializeComponent();
            WinFormsUtil.TranslateInterface(this, Main.CurrentLanguage);
            SAV = (ISaveBlock6Main)sav;

            var puffs = SAV.Puff.GetPuffs();

            Setup(puffs.Length);
            LoadPuffs(puffs);

            toolTip1.SetToolTip(B_Sort, "Hold CTRL to reverse sort.");
            toolTip2.SetToolTip(B_All, "Hold CTRL to best instead of varied.");
        }
Esempio n. 3
0
    public SAV_Link6(SaveFile sav)
    {
        InitializeComponent();
        WinFormsUtil.TranslateInterface(this, Main.CurrentLanguage);
        SAV = (ISaveBlock6Main)(Origin = sav).Clone();
        var filtered = GameInfo.FilteredSources;

        foreach (var cb in TAB_Items.Controls.OfType <ComboBox>())
        {
            cb.InitializeBinding();
            cb.DataSource = new BindingSource(filtered.Items, null);
        }
        LinkInfo = SAV.Link.GetLinkInfo();
        LoadLinkData();
    }
Esempio n. 4
0
        public SAV_OPower(ISaveBlock6Main sav)
        {
            InitializeComponent();
            WinFormsUtil.TranslateInterface(this, Main.CurrentLanguage);
            Origin = (SaveFile)sav;
            SAV    = Origin.Clone();
            Data   = ((ISaveBlock6Main)SAV).OPower;

            Current = Types[0];
            foreach (var z in Types)
            {
                CB_Type.Items.Add(z.ToString());
            }
            CB_Type.SelectedIndex = 0;
            CHK_Master.Checked    = Data.MasterFlag;
            LoadCurrent();

            CB_Type.SelectedIndexChanged += (s, e) => { SaveCurrent(); LoadCurrent(); };
            B_ClearAll.Click             += (s, e) => { Data.ClearAll(); LoadCurrent(); };
            B_GiveAll.Click    += (s, e) => { Data.UnlockRegular(); LoadCurrent(); };
            B_GiveAllMAX.Click += (s, e) => { Data.UnlockAll(); LoadCurrent(); };
        }