示例#1
0
        public Form1(String ime, PocetnaForma pf)
        {
            InitializeComponent();
            igracIme    = ime;
            this.igraci = pf.igraci;
            fruits      = new List <Fruit>();
            toolStripStatusLabel1.Text = "";
            this.DoubleBuffered        = true;
            selected = false;
            pf       = new PocetnaForma();
            this.pf  = pf;
            i1       = new Igrac(igracIme);


            timer1.Start();
            timer2.Start();


            //za kopceto  da bide okruglo i bez  border
            System.Drawing.Drawing2D.GraphicsPath ag = new System.Drawing.Drawing2D.GraphicsPath();
            ag.AddArc(0, 0, button1.Width, button1.Height, 0, 360);
            button1.Region    = new Region(ag);
            button1.TabStop   = false;
            button1.FlatStyle = FlatStyle.Flat;
            button1.FlatAppearance.BorderSize = 0;

            //za play kopceto
            System.Drawing.Drawing2D.GraphicsPath ag1 = new System.Drawing.Drawing2D.GraphicsPath();
            ag1.AddArc(0, 0, button2.Width, button2.Height, 0, 360);
            button2.Region    = new Region(ag1);
            button2.TabStop   = false;
            button2.FlatStyle = FlatStyle.Flat;
            button2.FlatAppearance.BorderSize = 0;
        }
示例#2
0
        private void CancelButton_Click(object sender, EventArgs e)
        {
            Form newform = new PocetnaForma();

            this.Hide();
            this.Close();
            newform.Show();
        }
示例#3
0
 private void btnLogIn_Click(object sender, EventArgs e)
 {
     zki.povezisesaserverom();
     BibliotekaKlasa.Zaposleni z = zki.login(txtUser, txtPass);
     if (z == null)
     {
         MessageBox.Show("Pogresan user ili pass");
     }
     else
     {
         PocetnaForma pf = new PocetnaForma(z);
         pf.ShowDialog();
     }
 }
示例#4
0
 private void btnPrijava_Click(object sender, EventArgs e)
 {
     if (ProvjeraKorisnika())
     {
         PocetnaForma pocetnaForma = new PocetnaForma();
         this.Hide();
         pocetnaForma.ShowDialog();
         this.Show();
         txtKorisnickoIme.Text = "";
         txtLozinka.Text       = "";
         SendKeys.Send("+{TAB}");
     }
     else
     {
         MessageBox.Show(PorukaPogreska.NeispravanUnosPodataka, PorukaPogreska.Zaglavlje, MessageBoxButtons.OK);
     }
 }