void hideWidgets() { hbox_error.Hide(); entry.Hide(); hbox_entry2.Hide(); hbox_entry3.Hide(); hbox_spin_int.Hide(); hbox_spin_int2.Hide(); hbox_spin_int3.Hide(); spin_double.Hide(); hbox_spin_double2.Hide(); hbox_height_metric.Hide(); hbox_edit_row.Hide(); hbox_all_none_selected.Hide(); hbox_combo_all_none_selected.Hide(); hbuttonbox_middle.Hide(); scrolled_window_textview.Hide(); scrolled_window_treeview.Hide(); }
protected void fillDialog(Event myEvent) { fillWindowTitleAndLabelHeader(); string id = myEvent.UniqueID.ToString(); if (myEvent.Simulated == Constants.Simulated) { label_simulated.Show(); } label_event_id_value.Text = id; label_event_id_value.UseMarkup = true; if (showTv) { fillTv(myEvent); } else { label_tv_title.Hide(); entry_tv_value.Hide(); label_tv_units.Hide(); } if (showTc) { fillTc(myEvent); } else { label_tc_title.Hide(); entry_tc_value.Hide(); label_tc_units.Hide(); } if (showFall) { fillFall(myEvent); } else { label_fall_title.Hide(); entry_fall_value.Hide(); label_fall_units.Hide(); } if (showDistance) { fillDistance(myEvent); } else { label_distance_title.Hide(); entry_distance_value.Hide(); label_distance_units.Hide(); } if (showTime) { fillTime(myEvent); } else { label_time_title.Hide(); entry_time_value.Hide(); label_time_units.Hide(); } if (showSpeed) { fillSpeed(myEvent); } else { label_speed_title.Hide(); label_speed_value.Hide(); label_speed_units.Hide(); } if (showWeight) { fillWeight(myEvent); } else { label_weight_title.Hide(); entry_weight_value.Hide(); label_weight_units.Hide(); } if (showLimited) { fillLimited(myEvent); } else { label_limited_title.Hide(); label_limited_value.Hide(); } if (showAngle) { fillAngle(myEvent); } else { label_angle_title.Hide(); entry_angle_value.Hide(); label_angle_units.Hide(); } if (!showMistakes) { label_mistakes.Hide(); spin_mistakes.Hide(); } //also remove new line for old descriptions that used a textview string temp = Util.RemoveTildeAndColonAndDot(myEvent.Description); entry_description.Text = Util.RemoveNewLine(temp, true); createComboEventType(myEvent); if (!showType) { label_type_title.Hide(); combo_eventType.Hide(); } if (showRunStart) { fillRunStart(myEvent); } else { label_run_start_title.Hide(); label_run_start_value.Hide(); } ArrayList persons = SqlitePersonSession.SelectCurrentSessionPersons( myEvent.SessionID, false); //means: do not returnPersonAndPSlist string [] personsStrings = new String[persons.Count]; int i = 0; foreach (Person person in persons) { personsStrings[i++] = person.IDAndName(":"); } combo_persons = ComboBox.NewText(); UtilGtk.ComboUpdate(combo_persons, personsStrings, ""); combo_persons.Active = UtilGtk.ComboMakeActive(personsStrings, myEvent.PersonID + ":" + myEvent.PersonName); oldPersonID = myEvent.PersonID; hbox_combo_person.PackStart(combo_persons, true, true, 0); hbox_combo_person.ShowAll(); //show video if available videoFileName = Util.GetVideoFileName(myEvent.SessionID, typeOfTest, myEvent.UniqueID); if (File.Exists(videoFileName)) { label_video_yes.Visible = true; label_video_no.Visible = false; button_video_watch.Sensitive = true; button_video_url.Sensitive = true; } else { label_video_yes.Visible = false; label_video_no.Visible = true; button_video_watch.Sensitive = false; button_video_url.Sensitive = false; } }