Exemple #1
0
 private void pictureBox7_MouseClick(object sender, MouseEventArgs e)
 {
     flowLayoutPanel1.Controls.Clear();
     if (historyThingPanels == null)
     {
         historyThingPanels = new List <TodayThingPanel>();
         TodayHistoryCrawler todayHistoryCrawler = new TodayHistoryCrawler();
         todayHistoryCrawler.Crawl();
         foreach (TodayHistory todayHistory in todayHistoryCrawler.list)
         {
             historyThingPanels.Add(new TodayThingPanel(todayHistory));
         }
     }
     foreach (TodayThingPanel thingPanel in historyThingPanels)
     {
         this.flowLayoutPanel1.Controls.Add(thingPanel);
     }
     if (historyThingPanels.Count == 0)
     {
         PictureBox picture = new PictureBox();
         picture.ImageLocation = "../../Resource/net.png";
         picture.SizeMode      = PictureBoxSizeMode.StretchImage;
         this.flowLayoutPanel1.Controls.Add(picture);
     }
     flowLayoutPanel1.Show();
 }
Exemple #2
0
 private void pictureBox7_MouseClick(object sender, MouseEventArgs e)
 {
     flowLayoutPanel1.Controls.Clear();
     if (historyThingPanels == null)
     {
         historyThingPanels = new List <ThingPanel>();
         TodayHistoryCrawler todayHistoryCrawler = new TodayHistoryCrawler();
         todayHistoryCrawler.Crawl();
         foreach (TodayHistory todayHistory in todayHistoryCrawler.list)
         {
             historyThingPanels.Add(new ThingPanel(todayHistory));
         }
     }
     foreach (ThingPanel thingPanel in historyThingPanels)
     {
         this.flowLayoutPanel1.Controls.Add(thingPanel);
     }
     flowLayoutPanel1.Show();
 }