Esempio n. 1
0
        private void toolExchange_Click(object sender, EventArgs e)
        {
            String sss = String.Empty;
            sss = filenames[0];
            filenames[0] = filenames[1];
            filenames[1] = sss;

            pic[0] = new BPM(0, filenames[0], Const.clGreen);
            pic1loaded = true;
            pictureBox1.Image = pic[0].GetBitmap;
            pictureBox1.Refresh();
            st = false;
            pic[1] = new BPM(1, filenames[1], Const.clRed);
            pic2loaded = true;
            pictureBox1.Image = pic[1].GetBitmap;
            pictureBox1.Refresh();
            st = false;
            String ss = String.Empty;
            //foreach (String ssss in filenames)
            //{
            //	ss += ssss + "\r\n";
            //}
            //MessageBox.Show(ss);
        }
Esempio n. 2
0
 private void открыть2_Click(object sender, EventArgs e)
 {
     if (openFileDialog1.ShowDialog() != DialogResult.OK)
         return;
     pic[1] = new BPM(1, openFileDialog1.FileName, Const.clRed);
     pic2loaded = true;
     pictureBox1.Image = pic[1].GetBitmap;
     pictureBox1.Refresh();
     st = false;
 }
Esempio n. 3
0
 private void openToolStripMenuItem_Click(object sender, EventArgs e)
 {
     openFileDialog1.Multiselect = true;
     if (openFileDialog1.ShowDialog() != DialogResult.OK)
         return;
     if (openFileDialog1.FileNames.Length == 0)
         return;
     else if (openFileDialog1.FileNames.Length == 1)
     {
         if (filenames[0] == null)
         {
             filenames[0] = openFileDialog1.FileNames[0];
             pic[0] = new BPM(0, filenames[0], Const.clGreen);
             pic1loaded = true;
             pic2loaded = false;
             pictureBox1.Image = pic[0].GetBitmap;
             pictureBox1.Refresh();
             st = false;
         }
         else
         {
             filenames[1] = openFileDialog1.FileNames[0];
             pic[1] = new BPM(1, filenames[1], Const.clRed);
             pic1loaded = true;
             pic2loaded = true;
             pictureBox1.Image = pic[1].GetBitmap;
             pictureBox1.Refresh();
             st = false;
         }
     }
     else
     {
         filenames[0] = openFileDialog1.FileNames[0];
         filenames[1] = openFileDialog1.FileNames[1];
         pic[0] = new BPM(0, filenames[0], Const.clGreen);
         pic1loaded = true;
         pictureBox1.Image = pic[0].GetBitmap;
         pictureBox1.Refresh();
         st = false;
         pic[1] = new BPM(1, filenames[1], Const.clRed);
         pic2loaded = true;
         pictureBox1.Image = pic[1].GetBitmap;
         pictureBox1.Refresh();
         st = false;
     }
     //String ss = String.Empty;
     //foreach (String sss in openFileDialog1.FileNames)
     //{
     //	ss += sss + "\r\n";
     //}
     //MessageBox.Show(ss);
 }