8
#include "itick_dbox.h"
16
gint tmp_cyclerate, tmp_tickrate, tmp_itick;
18
gint display_tickrate_dbox()
22
gchar buffer[MAXCHARS];
24
dbox = create_tickrate_dbox();
26
user_data = gtk_object_get_data(GTK_OBJECT(dbox), "entry7");
27
tmp_tickrate = (options.params)->tick_rate;
28
g_snprintf(buffer, MAXCHARS, "%lu", (options.params)->tick_rate);
29
gtk_entry_set_text((GtkEntry *)user_data, buffer);
31
gtk_widget_show_all(dbox);
37
on_entry7_changed (GtkEditable *editable,
42
s = gtk_editable_get_chars((GtkEditable *)(user_data), 0, -1);
43
if(sscanf(s, "%i", &tmp_tickrate) < 1)
50
on_button33_clicked (GtkButton *button,
53
(options.params)->tick_rate = tmp_tickrate;
54
gtk_widget_destroy(user_data);
59
on_button34_clicked (GtkButton *button,
62
gtk_widget_destroy(user_data);
67
on_tickrate_dbox_destroy (GtkObject *object,
75
gint display_cyclerate_dbox()
79
gchar buffer[MAXCHARS];
81
dbox = create_cyclerate_dbox();
83
user_data = gtk_object_get_data(GTK_OBJECT(dbox), "entry8");
84
tmp_cyclerate = (options.params)->cycle_rate;
85
g_snprintf(buffer, MAXCHARS, "%lu", (options.params)->cycle_rate);
86
gtk_entry_set_text((GtkEntry *)user_data, buffer);
88
gtk_widget_show_all(dbox);
94
on_entry8_changed (GtkEditable *editable,
99
s = gtk_editable_get_chars((GtkEditable *)(user_data), 0, -1);
100
if(sscanf(s, "%i", &tmp_cyclerate) < 1)
101
tmp_cyclerate = 40000;
108
on_button35_clicked (GtkButton *button,
111
(options.params)->cycle_rate = tmp_cyclerate;
113
gtk_widget_destroy(user_data);
118
on_button36_clicked (GtkButton *button,
121
gtk_widget_destroy(user_data);
126
on_cyclerate_dbox_destroy (GtkObject *object,
134
gint display_itick_dbox()
138
gchar buffer[MAXCHARS];
140
dbox = create_itick_dbox();
142
user_data = gtk_object_get_data(GTK_OBJECT(dbox), "entry9");
143
tmp_itick = (options.params)->i_tick;
144
g_snprintf(buffer, MAXCHARS, "%i", (options.params)->i_tick);
145
gtk_entry_set_text((GtkEntry *)user_data, buffer);
147
gtk_widget_show_all(dbox);
153
on_entry9_changed (GtkEditable *editable,
158
s = gtk_editable_get_chars((GtkEditable *)(user_data), 0, -1);
159
if(sscanf(s, "%i", &tmp_itick) < 1)
167
on_button41_clicked (GtkButton *button,
170
(options.params)->i_tick = tmp_itick;
172
gtk_widget_destroy(user_data);
177
on_button42_clicked (GtkButton *button,
180
gtk_widget_destroy(user_data);
185
on_itick_dbox_destroy (GtkObject *object,