예제 #1
0
 public void AddBehideDesign(Bitmap bm)
 {
     if (bm != null && Style.ishavebehide)
     {
         if (AddBehidepic == null)
         {
             AddBehidepic          = new DesignView(bm);
             AddBehidepic.Location = new Point(0, 0);
             AddBehidepic.Size     = new Size(50, 50);
             AddBehidepic.BackgroundImageLayout = ImageLayout.Stretch;
             AddBehidepic.setmainHeight(this.Height);
             AddBehidepic.setmainWidth(this.Width);
             Stylepic.Controls.Add(AddBehidepic);
             AddBehidepic.BackgroundImage = bm;
             if (!IsBehide)
             {
                 AddBehidepic.Visible = false;
             }
         }
         else
         {
             AddBehidepic.BackgroundImage = bm;
         }
     }
     else
     {
         //TODO
     }
 }
예제 #2
0
 public void AddBehideDesign(string FileName)
 {
     if (File.Exists(FileName) && Style.ishavebehide)
     {
         if (AddBehidepic == null)
         {
             AddBehidepic          = new DesignView(Image.FromFile(FileName));
             AddBehidepic.Location = new Point(0, 0);
             AddBehidepic.Size     = new Size(50, 50);
             AddBehidepic.BackgroundImageLayout = ImageLayout.Stretch;
             AddBehidepic.setmainHeight(this.Height);
             AddBehidepic.setmainWidth(this.Width);
             Stylepic.Controls.Add(AddBehidepic);
             AddBehidepic.BackgroundImage = Image.FromFile(FileName);
             if (!IsBehide)
             {
                 AddBehidepic.Visible = false;
             }
         }
         else
         {
             AddBehidepic.BackgroundImage = Image.FromFile(FileName);
         }
     }
     else
     {
         //TODO
     }
 }
예제 #3
0
 public void RemoveBehideDesign()
 {
     if (AddBehidepic != null)
     {
         this.Controls.Remove(AddBehidepic);
         AddBehidepic.Dispose();
         AddBehidepic = null;
     }
 }
예제 #4
0
 public void RemoveFrontDesign()
 {
     if (AddFrontpic != null)
     {
         this.Controls.Remove(AddFrontpic);
         AddFrontpic.Dispose();
         AddFrontpic = null;
     }
 }