Example #1
0
 public void addMdiChild(String username, String password, String region, bool autoConnect = false)
 {
     if(mdiChilds.Count<vClient>(u => u._username == username) > 0)
     {
         MessageBox.Show("This Client already exist.");
         return;
     }
     Image summonerIcon = Basic.returnIcon(0);
     vClient t = new vClient(username, password, region, this, autoConnect);
     exListBoxItem eLBI = new exListBoxItem(t._username, t._username, "Status: Waiting...", "", summonerIcon);
     t.addListBoxItem(eLBI);
     exListBox1.Items.Add(eLBI);
     mdiChilds.Add(t);
     t.MdiParent = this;
     t.Show();
     id++;
 }
Example #2
0
        public void addMdiChild(String username, String password, String region, bool autoConnect = false)
        {
            if (mdiChilds.Count <vClient>(u => u._username == username) > 0)
            {
                MessageBox.Show("This Client already exist.");
                return;
            }
            Image         summonerIcon = Basic.returnIcon(0);
            vClient       t            = new vClient(username, password, region, this, autoConnect);
            exListBoxItem eLBI         = new exListBoxItem(t._username, t._username, "Status: Waiting...", "", summonerIcon);

            t.addListBoxItem(eLBI);
            exListBox1.Items.Add(eLBI);
            mdiChilds.Add(t);
            t.MdiParent = this;
            t.Show();
            id++;
        }
Example #3
0
        public void addMdiChild(string username, string password, string region, bool autoConnect = false)
        {
            if (VoliBot.mdiChilds.Count((vClient u) => u._username == username) > 0)
            {
                MessageBox.Show("This Client already exist.");
                return;
            }
            Image         image         = Basic.returnIcon(0);
            vClient       vClient       = new vClient(username, password, region, this, autoConnect);
            exListBoxItem exListBoxItem = new exListBoxItem(vClient._username, vClient._username, "Status: Waiting...", "", image);

            vClient.addListBoxItem(exListBoxItem);
            this.exListBox1.Items.Add(exListBoxItem);
            VoliBot.mdiChilds.Add(vClient);
            vClient.MdiParent = this;
            vClient.Show();
            this.id++;
        }