changeset 2449:48c352f89a4e trunk

[svn] - avoid multiple open of filebrowser
author yaz
date Wed, 31 Jan 2007 01:48:50 -0800
parents ff135e2ba10e
children 617d5cc31d95
files ChangeLog src/audacious/ui_fileopener.c
diffstat 2 files changed, 13 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Tue Jan 30 14:21:06 2007 -0800
+++ b/ChangeLog	Wed Jan 31 01:48:50 2007 -0800
@@ -1,3 +1,11 @@
+2007-01-30 22:21:06 +0000  William Pitcock <nenolod@sacredspiral.co.uk>
+  revision [3906]
+  - mark some strings used by GOption as translatable
+  
+  trunk/src/audacious/main.c |   30 +++++++++++++++---------------
+  1 file changed, 15 insertions(+), 15 deletions(-)
+
+
 2007-01-30 21:45:10 +0000  Derek Pomery <nemo@m8y.org>
   revision [3904]
   Translation tweak by Thierry Vignaud
--- a/src/audacious/ui_fileopener.c	Tue Jan 30 14:21:06 2007 -0800
+++ b/src/audacious/ui_fileopener.c	Wed Jan 31 01:48:50 2007 -0800
@@ -92,7 +92,6 @@
     if (play_button)
         playback_initiate();
 
-
     if (cfg.close_dialog_open)
         gtk_widget_destroy(window);
 }
@@ -110,7 +109,7 @@
                         gpointer data)
 {
     if (event->keyval == GDK_Escape) {
-	gtk_widget_destroy(browser);
+        gtk_widget_destroy(browser);
         return TRUE;
     }
 
@@ -120,12 +119,15 @@
 void
 util_run_filebrowser_gtk2style(gboolean play_button)
 {
-    GtkWidget *window;
+    static GtkWidget *window = NULL;
     GtkWidget *vbox, *hbox, *bbox;
     GtkWidget *chooser;
     GtkWidget *action_button, *close_button;
     GtkWidget *toggle;
 
+    if(window) /* avoid multiple open of filebrowser */
+        return;
+    
     gchar *window_title = play_button ? _("Open Files") : _("Add Files");
     gchar *toggle_text = play_button ?
         _("Close dialog on Open") : _("Close dialog on Add");