Allow for continuous dials

Update gtk_dial_new_with_range() to set round_digits to -1 if step is
zero.

Update create_levels_controls() to set step to zero.
This commit is contained in:
Geoffrey D. Bennett
2024-01-16 07:22:59 +10:30
parent e40ce4d5ad
commit 1164845b3c
2 changed files with 4 additions and 3 deletions

View File

@@ -95,7 +95,7 @@ GtkWidget *create_levels_controls(struct alsa_card *card) {
count_labels[j] = add_count_label(grid, j);
// create the meter widget and attach to the grid
GtkWidget *meter = gtk_dial_new_with_range(-80, 0, 1);
GtkWidget *meter = gtk_dial_new_with_range(-80, 0, 0);
gtk_widget_set_sensitive(meter, FALSE);
card->meters[meter_num++] = meter;
gtk_grid_attach(GTK_GRID(grid), meter, j + 1, i + 1, 1, 1);