private void right_sound_Click(object sender, RoutedEventArgs e) { CmbObject lbr = fs.Find(v => v.Value == file_list.SelectedValue.ToString()); right_name.Content = lbr.Url; right_list.Items.Add(lbr.Value); }
/*--------------------------------------------------*/ /*コンボボックスの値が変更された時のイベントパンドラ*/ /*--------------------------------------------------*/ private void comboBox1_SelectedIndexChanged(object sender, EventArgs e) { CmbObject obj = (CmbObject)comboBox1.SelectedItem; label_width_ratio.Text = Convert.ToString(obj.width_ratio); label_height_ratio.Text = Convert.ToString(obj.height_ratio); label_image_count.Text = Convert.ToString(obj.image_count); pictureBox1.Width = obj.width_ratio; pictureBox1.Height = obj.height_ratio; }
/*コンボボックスの値を構造体に代入*/ private void button1_Click(object sender, EventArgs e) { // 返すコンボボックスの値を設定 CmbObject obj = (CmbObject)comboBox1.SelectedItem; this.ReturnValue.width_ratio = obj.width_ratio; this.ReturnValue.height_ratio = obj.height_ratio; this.ReturnValue.image_count = obj.image_count; past_index = comboBox1.SelectedIndex; // 返すカラーフラグを設定 color_flag[0] = checkBox1.Checked; color_flag[1] = checkBox2.Checked; color_flag[2] = checkBox3.Checked; color_flag[3] = checkBox4.Checked; color_flag[4] = checkBox5.Checked; color_flag[5] = checkBox6.Checked; if (color_flag[0] || color_flag[1] || color_flag[2] || color_flag[3] || color_flag[4] || color_flag[5]) { this.Close(); } }
private void comboBox2_SelectedIndexChanged(object sender, EventArgs e) { shin = (CmbObject)comboBox_s.SelectedItem; trackBar1.Value = shin.Div; textdiv1.Text = trackBar1.Value.ToString(); }
private void comboBox1_SelectedIndexChanged(object sender, EventArgs e) { boin = (CmbObject)comboBox_b.SelectedItem; }