X-Git-Url: https://git.wpitchoune.net/gitweb/?p=psensor-pkg-ubuntu.git;a=blobdiff_plain;f=src%2Fui_graph.c;fp=src%2Fui_graph.c;h=e5e0e76f638dbfed0e9cc7f42cf96333fe4762ca;hp=0b9b41b7400eafdb78aa796eba668a371a868cb9;hb=5c1e07fec97e34a94331b6b47e25c98f2b2e4cce;hpb=4c50d430bea4b8462b0ae7ab70baf3f538f87718 diff --git a/src/ui_graph.c b/src/ui_graph.c index 0b9b41b..e5e0e76 100644 --- a/src/ui_graph.c +++ b/src/ui_graph.c @@ -45,6 +45,11 @@ on_expose_event(GtkWidget *widget, GdkEventExpose *event, gpointer data) return FALSE; } +void smooth_curves_enabled_changed_cbk(void *data) +{ + is_smooth_curves_enabled = config_is_smooth_curves_enabled(); +} + void ui_graph_create(struct ui_psensor *ui) { GtkWidget *w_graph; @@ -53,6 +58,12 @@ void ui_graph_create(struct ui_psensor *ui) w_graph = ui->w_graph; + is_smooth_curves_enabled = config_is_smooth_curves_enabled(); + g_signal_connect_after(config_get_GSettings(), + "changed::graph-smooth-curves-enabled", + G_CALLBACK(smooth_curves_enabled_changed_cbk), + NULL); + g_signal_connect(GTK_WIDGET(w_graph), "draw", G_CALLBACK(on_expose_event),