Mercurial > audlegacy-plugins
changeset 2857:59727b85a091
Restart dialog
author | Paula Stanciu <paula.stanciu@gmail.com> |
---|---|
date | Fri, 01 Aug 2008 23:18:21 +0300 |
parents | 59ff744e1e23 |
children | 528d19a2ea3d |
files | src/bluetooth/bluetooth.c |
diffstat | 1 files changed, 15 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/bluetooth/bluetooth.c Fri Aug 01 22:55:49 2008 +0300 +++ b/src/bluetooth/bluetooth.c Fri Aug 01 23:18:21 2008 +0300 @@ -43,7 +43,7 @@ static void discovery_completed(DBusGProxy *object, gpointer user_data); void discover_devices(void); void disconnect_dbus_signals(void); - +static void show_restart_dialog(void); GeneralPlugin bluetooth_gp = { @@ -212,10 +212,23 @@ aud_cfg_db_close(cfgfile); printf("play callback\n"); + close_window(); + show_restart_dialog(); } - +static void show_restart_dialog() +{ +static GtkWidget *window = NULL; + GtkWidget *dialog; + dialog = gtk_message_dialog_new (GTK_WINDOW (window), + GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT, + GTK_MESSAGE_INFO, + GTK_BUTTONS_OK, + "Please restart the player to apply the bluetooth audio settings!"); + gtk_dialog_run (GTK_DIALOG (dialog)); + gtk_widget_destroy (dialog); +} static void remote_device_found(DBusGProxy *object, char *address, const unsigned int class, const int rssi, gpointer user_data) {