Exemplo n.º 1
0
 private void NapraviVest(string id, string link, int start, string naslov, string slika, string prio)
 {
     try
     {
         int     velicina = this.flowLayoutPanel1.Size.Height / 3;
         UVSvest svest    = new UVSvest {
             Size = new Size(this.flowLayoutPanel1.Size.Width - 40, (this.flowLayoutPanel1.Size.Height / 3) - 12)
         };
         svest.Pocetak(id, link, start, naslov, slika, velicina);
         this.flowLayoutPanel1.Controls.Add(svest);
         this.flowLayoutPanel1.ScrollControlIntoView(svest);
     }
     catch
     {
     }
 }
Exemplo n.º 2
0
 private void timerSkroling_Tick(object sender, EventArgs e)
 {
     try
     {
         this.PrivremenaVest = (UVSvest)this.flowLayoutPanel1.Controls[this.GledajVest];
         this.PrivremenaVest.PokreniAzuriranje();
     }
     catch
     {
     }
     this.flowLayoutPanel1.ScrollControlIntoView(this.flowLayoutPanel1.Controls[this.GledajVest]);
     if (this.GledajVest == this.MaxUcitanihVesti)
     {
         this.GledajVest = -1;
         this.ProlazakKrozSveVesti--;
     }
     this.GledajVest++;
     if (this.ProlazakKrozSveVesti < 1)
     {
         this.timerSkroling.Stop();
         this.timerSkroling.Enabled = false;
         this.SkidanjeVesti();
     }
 }