Exit after launching unless we're being compiled in applet mode (which

isn't fully reinstated yet anyway).


git-svn-id: https://samskivert.googlecode.com/svn/trunk@95 6335cc39-0255-0410-8fd6-9bcaacd3b74c
This commit is contained in:
mdb
2001-03-10 20:43:57 +00:00
parent d7ad411c11
commit 0b7a29c7ed
+9 -1
View File
@@ -1,5 +1,5 @@
/** /**
* $Id: querybox.c,v 1.4 2001/03/10 20:30:58 mdb Exp $ * $Id: querybox.c,v 1.5 2001/03/10 20:43:57 mdb Exp $
*/ */
#include <config.h> #include <config.h>
@@ -71,8 +71,12 @@ key_pressed (GtkWidget* widget, GdkEvent* event, gpointer callback_data)
/* launch the appropriate thing */ /* launch the appropriate thing */
lk_launcher_launch(binding, search_text); lk_launcher_launch(binding, search_text);
g_free(search_text); g_free(search_text);
#ifdef APPLET_MODE
/* clear out the contents of the entry box */ /* clear out the contents of the entry box */
gtk_entry_set_text(GTK_ENTRY(widget), ""); gtk_entry_set_text(GTK_ENTRY(widget), "");
#else
gtk_exit(0);
#endif
handled = TRUE; handled = TRUE;
break; break;
} }
@@ -99,8 +103,12 @@ launch (GtkWidget* widget, gpointer data)
lk_launcher_launch(NULL, search_text); lk_launcher_launch(NULL, search_text);
g_free(search_text); g_free(search_text);
#ifdef APPLET_MODE
/* clear out the contents of the entry box */ /* clear out the contents of the entry box */
gtk_entry_set_text(GTK_ENTRY(widget), ""); gtk_entry_set_text(GTK_ENTRY(widget), "");
#else
gtk_exit(0);
#endif
} }
GtkWidget* GtkWidget*