TROIS BOUTONS: STATE, RULES et DATA in a radio group (cleaning)

This commit is contained in:
Jean Sirmai 2024-06-14 07:48:24 +02:00
parent 4cd7a0215a
commit 981886d79b
Signed by: jean
GPG Key ID: FB3115C340E057E3
2 changed files with 13 additions and 7 deletions

View File

@ -167,7 +167,6 @@ void on_axis_value_change(GtkAdjustment *adjustment, gpointer data)
/* B U T T O N S */ /* B U T T O N S */
/******************************************************************************/ /******************************************************************************/
void on_toggle_model_exec (GtkWidget *btt_run_stop_model_exec, gpointer data) {} void on_toggle_model_exec (GtkWidget *btt_run_stop_model_exec, gpointer data) {}
void on_toggle_observ_interpret (GtkWidget *btt_toggle_observ_interpret, gpointer data) {}
void on_toggle_exec_edit (GtkWidget *btt_exec_xor_edit, GtkWidget *btt_run_stop_model_exec) { void on_toggle_exec_edit (GtkWidget *btt_exec_xor_edit, GtkWidget *btt_run_stop_model_exec) {
// gtk_button_set_icon_name (GTK_BUTTON (btt_exec_xor_edit), "power-profile-balanced-rtl-symbolic"); // gtk_button_set_icon_name (GTK_BUTTON (btt_exec_xor_edit), "power-profile-balanced-rtl-symbolic");
// gtk_button_set_label (GTK_BUTTON (btt_run_stop_model_exec), " run "); // gtk_button_set_label (GTK_BUTTON (btt_run_stop_model_exec), " run ");

View File

@ -177,14 +177,21 @@ void window_header_bar (GtkWindow *window, char *title){
GtkButton *run_stop_model_exec = GTK_BUTTON (gtk_button_new_with_label (" run ")); GtkButton *run_stop_model_exec = GTK_BUTTON (gtk_button_new_with_label (" run "));
g_signal_connect (run_stop_model_exec, "clicked", G_CALLBACK (on_toggle_model_exec), no_local_data); g_signal_connect (run_stop_model_exec, "clicked", G_CALLBACK (on_toggle_model_exec), no_local_data);
GtkButton *btt_open_STATE = GTK_BUTTON (gtk_button_new_with_label ("state")); GtkCheckButton *group_STATE_RULES_DATA = GTK_CHECK_BUTTON (gtk_check_button_new ());
g_signal_connect (btt_open_STATE, "clicked", G_CALLBACK (on_open_STATE), no_local_data);
GtkButton *btt_open_RULES = GTK_BUTTON (gtk_button_new_with_label ("rules")); GtkButton *btt_open_STATE = GTK_BUTTON (gtk_check_button_new_with_label ("state"));
g_signal_connect (btt_open_RULES, "clicked", G_CALLBACK (on_open_RULES), no_local_data); g_signal_connect (btt_open_STATE, "toggled", G_CALLBACK (on_open_STATE), no_local_data);
gtk_check_button_set_group (GTK_CHECK_BUTTON (btt_open_STATE), group_STATE_RULES_DATA);
GtkButton *btt_open_DATA = GTK_BUTTON (gtk_button_new_with_label ("data analysis")); GtkButton *btt_open_RULES = GTK_BUTTON (gtk_check_button_new_with_label ("rules"));
g_signal_connect (btt_open_DATA, "clicked", G_CALLBACK (on_open_DATA), no_local_data); g_signal_connect (btt_open_RULES, "toggled", G_CALLBACK (on_open_RULES), no_local_data);
gtk_check_button_set_group (GTK_CHECK_BUTTON (btt_open_RULES), group_STATE_RULES_DATA);
GtkButton *btt_open_DATA = GTK_BUTTON (gtk_check_button_new_with_label ("data analysis"));
g_signal_connect (btt_open_DATA, "toggled", G_CALLBACK (on_open_DATA), no_local_data);
gtk_check_button_set_group (GTK_CHECK_BUTTON (btt_open_DATA), group_STATE_RULES_DATA);
gtk_check_button_set_active (GTK_CHECK_BUTTON (btt_open_STATE), TRUE);
gtk_header_bar_pack_start (GTK_HEADER_BAR (header_bar), GTK_WIDGET (exec_xor_edit)); gtk_header_bar_pack_start (GTK_HEADER_BAR (header_bar), GTK_WIDGET (exec_xor_edit));
gtk_header_bar_pack_start (GTK_HEADER_BAR (header_bar), GTK_WIDGET (run_stop_model_exec)); gtk_header_bar_pack_start (GTK_HEADER_BAR (header_bar), GTK_WIDGET (run_stop_model_exec));