diff gui/skin/skin.c @ 33023:ba432e34dc7e

Add message showing function. In some cases it is necessary to show messages to the GUI users as well or they will wonder why the GUI didn't show up.
author ib
date Fri, 25 Mar 2011 10:33:48 +0000
parents 9abc0dbd6314
children 9684ad0e1291
line wrap: on
line diff
--- a/gui/skin/skin.c	Fri Mar 25 09:26:00 2011 +0000
+++ b/gui/skin/skin.c	Fri Mar 25 10:33:48 2011 +0000
@@ -23,6 +23,7 @@
 #include "cut.h"
 #include "font.h"
 #include "gui/app.h"
+#include "gui/interface.h"
 #include "gui/mplayer/widgets.h"
 
 #include "config.h"
@@ -49,19 +50,13 @@
 static void skin_error(const char *format, ...)
 {
     char p[512];
-    char tmp[512];
     va_list ap;
 
     va_start(ap, format);
     vsnprintf(p, sizeof(p), format, ap);
     va_end(ap);
 
-    mp_msg(MSGT_GPLAYER, MSGL_ERR, MSGTR_SKIN_ERRORMESSAGE, linenumber, p);
-
-    if (mp_msg_test(MSGT_GPLAYER, MSGL_ERR)) {
-        snprintf(tmp, sizeof(tmp), MSGTR_SKIN_ERRORMESSAGE, linenumber, p);
-        gtkMessageBox(GTK_MB_FATAL, tmp);
-    }
+    gmp_msg(MSGT_GPLAYER, MSGL_ERR, MSGTR_SKIN_ERRORMESSAGE, linenumber, p);
 }
 
 #define CHECKDEFLIST(str) \