From b3892cf644c693fef44b5daf55a0b66a667ac147 Mon Sep 17 00:00:00 2001 From: rbuj Date: Mon, 13 Dec 2021 23:18:26 +0100 Subject: Fix some -Wfloat-conversion warnings --- stickynotes/stickynotes_applet.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'stickynotes/stickynotes_applet.c') diff --git a/stickynotes/stickynotes_applet.c b/stickynotes/stickynotes_applet.c index c697151e..fd903e1e 100644 --- a/stickynotes/stickynotes_applet.c +++ b/stickynotes/stickynotes_applet.c @@ -166,6 +166,7 @@ stickynotes_applet_init (MatePanelApplet *mate_panel_applet) { cairo_t *cr; gint size, scale; + int screen_height; stickynotes = g_new (StickyNotes, 1); @@ -208,8 +209,8 @@ stickynotes_applet_init (MatePanelApplet *mate_panel_applet) G_CALLBACK (preferences_apply_cb), NULL); /* Max height for large notes*/ - stickynotes->max_height = - 0.8 * HeightOfScreen (gdk_x11_screen_get_xscreen (gdk_screen_get_default ())); + screen_height = HeightOfScreen (gdk_x11_screen_get_xscreen (gdk_screen_get_default ())); + stickynotes->max_height = (int) (0.8 * (double) screen_height); /* Load sticky notes */ stickynotes_load (gtk_widget_get_screen (GTK_WIDGET (mate_panel_applet))); -- cgit v1.2.1