diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2020-08-08 11:53:12 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2020-08-08 11:53:12 +0200 |
commit | e50482f994b6ebcce864a412111d376e99205cdb (patch) | |
tree | ff3192c6aaf213c4922521bed988e4ed4147f537 /app/wlib/gtklib/splash.c | |
parent | d3897ce090dbeb220ed2c782f095597e417cf3cc (diff) | |
parent | b623f5953691b2a0614e6f1f4def86bdbb9a4113 (diff) |
Update upstream source from tag 'upstream/5.2.0Beta2.1'
Update to upstream version '5.2.0Beta2.1'
with Debian dir 1576f25f4c1496abfed44af31ead67d32c7be650
Diffstat (limited to 'app/wlib/gtklib/splash.c')
-rw-r--r-- | app/wlib/gtklib/splash.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/app/wlib/gtklib/splash.c b/app/wlib/gtklib/splash.c index 0d5be50..5d56e9f 100644 --- a/app/wlib/gtklib/splash.c +++ b/app/wlib/gtklib/splash.c @@ -63,7 +63,7 @@ wCreateSplash(char *appName, char *appVer) gtk_window_set_position(GTK_WINDOW(window), GTK_WIN_POS_CENTER); gtk_window_set_resizable(GTK_WINDOW(window), FALSE); gtk_window_set_type_hint(GTK_WINDOW(window), GDK_WINDOW_TYPE_HINT_SPLASHSCREEN); -#if GTK_MINOR_VERSION > 5 +#if GTK_MAJOR_VERSION > 1 || GTK_MINOR_VERSION > 5 gtk_window_set_focus_on_map(GTK_WINDOW(window), FALSE); #endif @@ -108,7 +108,6 @@ wCreateSplash(char *appName, char *appVer) message = label; gtk_widget_show(window); - return (TRUE); } @@ -121,8 +120,9 @@ wCreateSplash(char *appName, char *appVer) int wSetSplashInfo(char *msg) { - if (msg) { - gtk_label_set_text((GtkLabel *)message, msg); + if (!window) return FALSE; + if (msg && message) { + gtk_label_set_text(GTK_LABEL(message), msg); wFlush(); return TRUE; } @@ -139,6 +139,8 @@ void wDestroySplash(void) { /* kill window */ - gtk_widget_destroy(window); + if (window) gtk_widget_destroy(window); + window = NULL; + return; } |