aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab+samsung@kernel.org>2018-09-05 22:39:56 -0300
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>2018-09-07 11:36:56 -0300
commita9cf1845c57c60239a3ccd150812ba7eff5fda4f (patch)
treeb61d075c660f5292be2132d9be26a04350c3909e /src
parentbad7d0926ca7f83cc7529f4de2a6d392262ada42 (diff)
Change GtkHScale to GtkScale
GtkHScale doesn't exist on Gtk 4. As GtkScale works fine since Gtk 2, use it. Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'src')
-rw-r--r--src/callbacks.c10
-rw-r--r--src/callbacks.h12
2 files changed, 11 insertions, 11 deletions
diff --git a/src/callbacks.c b/src/callbacks.c
index a35cee4..c8a9d4c 100644
--- a/src/callbacks.c
+++ b/src/callbacks.c
@@ -764,35 +764,35 @@ gint timeout_capture_func(cam_t *cam)
return 1;
}
-void contrast_change(GtkHScale *sc1, cam_t *cam)
+void contrast_change(GtkScale *sc1, cam_t *cam)
{
cam->contrast = 256 * (int)gtk_range_get_value((GtkRange *) sc1);
v4l2_set_control(cam->dev, V4L2_CID_CONTRAST, cam->contrast);
}
-void brightness_change(GtkHScale *sc1, cam_t *cam)
+void brightness_change(GtkScale *sc1, cam_t *cam)
{
cam->brightness = 256 * (int)gtk_range_get_value((GtkRange *) sc1);
v4l2_set_control(cam->dev, V4L2_CID_BRIGHTNESS, cam->brightness);
}
-void colour_change(GtkHScale *sc1, cam_t *cam)
+void colour_change(GtkScale *sc1, cam_t *cam)
{
cam->colour = 256 * (int)gtk_range_get_value((GtkRange *) sc1);
v4l2_set_control(cam->dev, V4L2_CID_SATURATION, cam->colour);
}
-void hue_change(GtkHScale *sc1, cam_t *cam)
+void hue_change(GtkScale *sc1, cam_t *cam)
{
cam->hue = 256 * (int)gtk_range_get_value((GtkRange *) sc1);
v4l2_set_control(cam->dev, V4L2_CID_HUE, cam->hue);
}
-void wb_change(GtkHScale *sc1, cam_t *cam)
+void wb_change(GtkScale *sc1, cam_t *cam)
{
cam->whiteness = 256 * (int)gtk_range_get_value((GtkRange *) sc1);
diff --git a/src/callbacks.h b/src/callbacks.h
index a55105f..a768f7f 100644
--- a/src/callbacks.h
+++ b/src/callbacks.h
@@ -59,13 +59,13 @@ void reichardt_func(GtkToggleButton *, gpointer);
void colour_func(GtkToggleButton *, gpointer);
void smooth_func(GtkToggleButton *, gpointer);
void negative_func(GtkToggleButton *, gpointer);
-void on_scale1_drag_data_received(GtkHScale *, cam_t *);
+void on_scale1_drag_data_received(GtkScale *, cam_t *);
void on_status_show(GtkWidget *, cam_t *);
-void contrast_change(GtkHScale *, cam_t *);
-void brightness_change(GtkHScale *, cam_t *);
-void colour_change(GtkHScale *, cam_t *);
-void hue_change(GtkHScale *, cam_t *);
-void wb_change(GtkHScale *, cam_t *);
+void contrast_change(GtkScale *, cam_t *);
+void brightness_change(GtkScale *, cam_t *);
+void colour_change(GtkScale *, cam_t *);
+void hue_change(GtkScale *, cam_t *);
+void wb_change(GtkScale *, cam_t *);
gboolean on_drawingarea_expose_event(GtkWidget *, GdkEventExpose *,
cam_t *);
void set_image_scale(cam_t *cam);

Privacy Policy