summaryrefslogtreecommitdiff
path: root/gtksplash.c
diff options
context:
space:
mode:
authorRuss Allbery <rra@debian.org>2009-12-06 13:28:36 -0800
committerRuss Allbery <rra@debian.org>2009-12-06 13:28:36 -0800
commit2dc6c06022f278f944c8b502fbe8ced1c73811e4 (patch)
treee6290c6509342ccbfca8004b4295b9b8604c4594 /gtksplash.c
parentfe15fa62fee6fe5e5f09e2ad6156be97e2b4f357 (diff)
Imported Upstream version 0.90+20091206
Diffstat (limited to 'gtksplash.c')
-rw-r--r--gtksplash.c35
1 files changed, 10 insertions, 25 deletions
diff --git a/gtksplash.c b/gtksplash.c
index 3d9ec2f..91e3242 100644
--- a/gtksplash.c
+++ b/gtksplash.c
@@ -16,23 +16,14 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
- * $Id: gtksplash.c,v 1.23 2008/03/13 18:15:57 Superfly_Jon Exp $
+ * $Id: gtksplash.c,v 1.32 2009/10/01 21:05:54 c_anthon Exp $
*/
#include "config.h"
-#include <gtk/gtk.h>
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include "eval.h"
-#include "gtksplash.h"
-#include "gtktoolbar.h"
#include "gtkgame.h"
-#include <glib/gi18n.h>
-
+#include "util.h"
+#include "gtksplash.h"
typedef struct _gtksplash {
GtkWidget *pwWindow;
@@ -46,8 +37,8 @@ CreateSplash (void) {
gtksplash *pgs;
GtkWidget *pwvbox, *pwFrame, *pwb;
GtkWidget *pwImage;
+ gchar *fn;
int i;
-#include "xpm/gnubg-big.xpm"
pgs = (gtksplash *) g_malloc ( sizeof ( gtksplash ) );
@@ -71,7 +62,9 @@ CreateSplash (void) {
/* image */
- pwImage = image_from_xpm_d ( gnubg_big_xpm, GTK_WIDGET ( pgs->pwWindow ) );
+ fn = g_build_filename(getPkgDataDir(), "pixmaps", "gnubg-big.png", NULL);
+ pwImage = gtk_image_new_from_file(fn);
+ g_free(fn);
gtk_box_pack_start ( GTK_BOX ( pwvbox ), pwImage, FALSE, FALSE, 0 );
gtk_box_pack_start( GTK_BOX( pwvbox ),
@@ -97,7 +90,7 @@ CreateSplash (void) {
gtk_widget_show_all ( GTK_WIDGET ( pgs->pwWindow ) );
- ProcessGtkEvents();
+ ProcessEvents();
return pgs->pwWindow;
@@ -120,10 +113,7 @@ DestroySplash ( GtkWidget *pwSplash ) {
}
-extern void
-PushSplash ( GtkWidget *pwSplash,
- const gchar *szText0, const gchar *szText1,
- const unsigned long nMuSec )
+extern void PushSplash ( GtkWidget *pwSplash, const gchar *szText0, const gchar *szText1 )
{
gtksplash *pgs;
@@ -136,10 +126,5 @@ PushSplash ( GtkWidget *pwSplash,
gtk_label_set_text ( GTK_LABEL ( pgs->apwStatus[ 0 ] ), szText0 );
gtk_label_set_text ( GTK_LABEL ( pgs->apwStatus[ 1 ] ), szText1 );
- ProcessGtkEvents();
-
-#ifndef WIN32
- /* Don't bother with these pauses on windows? */
- g_usleep ( nMuSec * 1000 );
-#endif
+ ProcessEvents();
}