summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorGravatar Alexey Yakovenko <wakeroid@gmail.com>2010-01-29 23:14:15 +0100
committerGravatar Alexey Yakovenko <wakeroid@gmail.com>2010-01-29 23:14:15 +0100
commit9460844e2a1598dfe24a72dd2a283d02b57caddc (patch)
tree0ec32a2b5453d3e5d299aa325b3c5a3be964092a /plugins
parente09556d82ca4b470dc8f5904a1080dffe2ffeb7b (diff)
parentfeecc0214decb6d1b9911aafe140034449266430 (diff)
Merge branch 'master' into devel
Conflicts: plugins/vorbis/vorbis.c streamer.c
Diffstat (limited to 'plugins')
-rw-r--r--plugins/alsa/alsa.c46
-rw-r--r--plugins/gtkui/Makefile.am1
-rw-r--r--plugins/gtkui/callbacks.c200
-rw-r--r--plugins/gtkui/deadbeef.glade2043
-rw-r--r--plugins/gtkui/gtkui.c2
-rw-r--r--plugins/gtkui/gtkui.h28
-rw-r--r--plugins/gtkui/interface.c1019
-rw-r--r--plugins/gtkui/interface.h2
-rw-r--r--plugins/gtkui/pluginconf.c242
-rw-r--r--plugins/lastfm/lastfm.c3
-rw-r--r--plugins/vorbis/vorbis.c5
11 files changed, 1818 insertions, 1773 deletions
diff --git a/plugins/alsa/alsa.c b/plugins/alsa/alsa.c
index 0137b29a..2017907c 100644
--- a/plugins/alsa/alsa.c
+++ b/plugins/alsa/alsa.c
@@ -32,7 +32,6 @@ static DB_output_t plugin;
DB_functions_t *deadbeef;
static snd_pcm_t *audio;
-//static int bufsize = -1;
static int alsa_terminate;
static int requested_rate = -1;
static int alsa_rate = 44100;
@@ -43,6 +42,9 @@ static intptr_t alsa_tid;
static snd_pcm_uframes_t buffer_size;
static snd_pcm_uframes_t period_size;
+static snd_pcm_uframes_t req_buffer_size;
+static snd_pcm_uframes_t req_period_size;
+
static int conf_alsa_resample = 0;
static char conf_alsa_soundcard[100] = "default";
@@ -176,28 +178,15 @@ palsa_set_hw_params (int samplerate) {
snd_pcm_hw_params_get_channels (hw_params, &nchan);
trace ("alsa channels: %d\n", nchan);
- buffer_size = 1024;
- period_size = 64;
+ req_buffer_size = deadbeef->conf_get_int ("alsa.buffer", 1024);
+ req_period_size = deadbeef->conf_get_int ("alsa.period", 512);
+ trace ("trying buffer size: %d frames\n", req_buffer_size);
+ trace ("trying period size: %d frames\n", req_period_size);
snd_pcm_hw_params_set_buffer_size_near (audio, hw_params, &buffer_size);
snd_pcm_hw_params_set_period_size_near (audio, hw_params, &period_size, NULL);
trace ("alsa buffer size: %d frames\n", buffer_size);
trace ("alsa period size: %d frames\n", period_size);
-// unsigned int buffer_time = 100000;
-// int dir;
-// if ((err = snd_pcm_hw_params_set_buffer_time_min (audio, hw_params, &buffer_time, &dir)) < 0) {
-// trace ("Unable to set buffer time %i for playback: %s\n", buffer_time, snd_strerror(err));
-// goto error;
-// }
-// trace ("alsa buffer time: %d usec\n", buffer_time);
-// snd_pcm_uframes_t size;
-// if ((err = snd_pcm_hw_params_get_buffer_size (hw_params, &size)) < 0) {
-// trace ("Unable to get buffer size for playback: %s\n", snd_strerror(err));
-// goto error;
-// }
-// trace ("alsa buffer size: %d frames\n", (int)size);
-// bufsize = size;
-
if ((err = snd_pcm_hw_params (audio, hw_params)) < 0) {
trace ("cannot set parameters (%s)\n",
snd_strerror (err));
@@ -585,18 +574,23 @@ palsa_callback (char *stream, int len) {
static int
palsa_configchanged (DB_event_t *ev, uintptr_t data) {
- trace ("alsa: config option changed, restarting\n");
int alsa_resample = deadbeef->conf_get_int ("alsa.resample", 0);
const char *alsa_soundcard = deadbeef->conf_get_str ("alsa_soundcard", "default");
- if (alsa_resample != conf_alsa_resample
- || strcmp (alsa_soundcard, conf_alsa_soundcard)) {
+ int buffer = deadbeef->conf_get_int ("alsa.buffer", 1024);
+ int period = deadbeef->conf_get_int ("alsa.period", 512);
+ if (audio &&
+ (alsa_resample != conf_alsa_resample
+ || strcmp (alsa_soundcard, conf_alsa_soundcard)
+ || buffer != req_buffer_size
+ || period != req_period_size)) {
+ trace ("alsa: config option changed, restarting\n");
deadbeef->sendmessage (M_REINIT_SOUND, 0, 0, 0);
}
return 0;
}
// derived from alsa-utils/aplay.c
-void
+static void
palsa_enum_soundcards (void (*callback)(const char *name, const char *desc, void *), void *userdata) {
void **hints, **n;
char *name, *descr, *io;
@@ -624,18 +618,18 @@ palsa_enum_soundcards (void (*callback)(const char *name, const char *desc, void
snd_device_name_free_hint(hints);
}
-int
+static int
palsa_get_state (void) {
return state;
}
-int
+static int
alsa_start (void) {
deadbeef->ev_subscribe (DB_PLUGIN (&plugin), DB_EV_CONFIGCHANGED, DB_CALLBACK (palsa_configchanged), 0);
return 0;
}
-int
+static int
alsa_stop (void) {
deadbeef->ev_unsubscribe (DB_PLUGIN (&plugin), DB_EV_CONFIGCHANGED, DB_CALLBACK (palsa_configchanged), 0);
return 0;
@@ -650,6 +644,8 @@ alsa_load (DB_functions_t *api) {
static const char settings_dlg[] =
"property \"Use ALSA resampling\" checkbox alsa.resample 0;\n"
"property \"Release device while stopped\" checkbox alsa.freeonstop 0;\n"
+ "property \"Preferred buffer size\" entry alsa.buffer 1024;\n"
+ "property \"Preferred period size\" entry alsa.period 512;\n"
;
// define plugin interface
diff --git a/plugins/gtkui/Makefile.am b/plugins/gtkui/Makefile.am
index 504984e0..aaf9c56a 100644
--- a/plugins/gtkui/Makefile.am
+++ b/plugins/gtkui/Makefile.am
@@ -8,6 +8,7 @@ gtkui_la_SOURCES = gtkui.c gtkui.h\
progress.c progress.h\
search.c search.h\
fileman.c\
+ pluginconf.c\
parser.c parser.h
gtkui_la_LDFLAGS = -module
diff --git a/plugins/gtkui/callbacks.c b/plugins/gtkui/callbacks.c
index d1e2871f..3e9e8538 100644
--- a/plugins/gtkui/callbacks.c
+++ b/plugins/gtkui/callbacks.c
@@ -1513,12 +1513,11 @@ on_plugin_active_toggled (GtkCellRendererToggle *cell_renderer, gchar *path, Gtk
void
preferences_fill_soundcards (void) {
- GtkWidget *w = prefwin;
if (!prefwin) {
return;
}
const char *s = deadbeef->conf_get_str ("alsa_soundcard", "default");
- GtkComboBox *combobox = GTK_COMBO_BOX (lookup_widget (w, "pref_soundcard"));
+ GtkComboBox *combobox = GTK_COMBO_BOX (lookup_widget (prefwin, "pref_soundcard"));
GtkTreeModel *mdl = gtk_combo_box_get_model (combobox);
gtk_list_store_clear (GTK_LIST_STORE (mdl));
@@ -1541,10 +1540,13 @@ void
on_preferences_activate (GtkMenuItem *menuitem,
gpointer user_data)
{
+ if (prefwin) {
+ return;
+ }
GtkWidget *w = prefwin = create_prefwin ();
gtk_window_set_transient_for (GTK_WINDOW (w), GTK_WINDOW (mainwin));
- GtkComboBox *combobox = NULL;;
+ GtkComboBox *combobox = NULL;
// output plugin selection
const char *outplugname = deadbeef->conf_get_str ("output_plugin", "ALSA output plugin");
@@ -1561,6 +1563,13 @@ on_preferences_activate (GtkMenuItem *menuitem,
// soundcard (output device) selection
preferences_fill_soundcards ();
+ g_signal_connect ((gpointer) combobox, "changed",
+ G_CALLBACK (on_pref_output_plugin_changed),
+ NULL);
+ GtkWidget *pref_soundcard = lookup_widget (prefwin, "pref_soundcard");
+ g_signal_connect ((gpointer) pref_soundcard, "changed",
+ G_CALLBACK (on_pref_soundcard_changed),
+ NULL);
// alsa resampling
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (lookup_widget (w, "pref_dynsamplerate")), deadbeef->conf_get_int ("playback.dynsamplerate", 0));
@@ -1638,8 +1647,11 @@ on_preferences_activate (GtkMenuItem *menuitem,
#endif
gtk_tree_view_set_model (tree, GTK_TREE_MODEL (store));
- gtk_widget_show (w);
gtk_widget_set_sensitive (lookup_widget (prefwin, "configure_plugin"), FALSE);
+// gtk_widget_show (w);
+ gtk_dialog_run (GTK_DIALOG (prefwin));
+ gtk_widget_destroy (prefwin);
+ prefwin = NULL;
}
@@ -2027,186 +2039,6 @@ on_addlocation_key_press_event (GtkWidget *widget,
return FALSE;
}
-
-void
-on_prop_entry_changed(GtkEditable *editable, gpointer user_data) {
- const char *key = g_object_get_data (G_OBJECT (editable), "key");
- if (key) {
- deadbeef->conf_set_str (key, gtk_entry_get_text (GTK_ENTRY (editable)));
- deadbeef->sendmessage (M_CONFIGCHANGED, 0, 0, 0);
- }
-}
-
-void
-on_prop_checkbox_clicked (GtkButton *button, gpointer user_data) {
- const char *key = g_object_get_data (G_OBJECT (button), "key");
- if (key) {
- deadbeef->conf_set_int (key, gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (button)));
- deadbeef->sendmessage (M_CONFIGCHANGED, 0, 0, 0);
- }
-}
-
-void
-on_prop_browse_file (GtkButton *button, gpointer user_data) {
- GtkWidget *dlg = gtk_file_chooser_dialog_new ("Open file...", GTK_WINDOW (mainwin), GTK_FILE_CHOOSER_ACTION_OPEN, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, GTK_STOCK_OPEN, GTK_RESPONSE_OK, NULL);
-
- gtk_file_chooser_set_select_multiple (GTK_FILE_CHOOSER (dlg), FALSE);
- // restore folder
- gtk_file_chooser_set_current_folder_uri (GTK_FILE_CHOOSER (dlg), deadbeef->conf_get_str ("filechooser.lastdir", ""));
- int response = gtk_dialog_run (GTK_DIALOG (dlg));
- // store folder
- gchar *folder = gtk_file_chooser_get_current_folder_uri (GTK_FILE_CHOOSER (dlg));
- if (folder) {
- deadbeef->conf_set_str ("filechooser.lastdir", folder);
- g_free (folder);
- deadbeef->sendmessage (M_CONFIGCHANGED, 0, 0, 0);
- }
- if (response == GTK_RESPONSE_OK) {
- gchar *file = gtk_file_chooser_get_filename (GTK_FILE_CHOOSER (dlg));
- gtk_widget_destroy (dlg);
- if (file) {
- GtkWidget *entry = GTK_WIDGET (user_data);
- gtk_entry_set_text (GTK_ENTRY (entry), file);
- g_free (file);
- }
- }
- else {
- gtk_widget_destroy (dlg);
- }
-}
-
-gboolean
-on_plug_prefwin_key_press_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data) {
- if (event->keyval == GDK_Escape) {
- gtk_widget_destroy (widget);
- }
- return FALSE;
-}
-
-void
-plugin_configure (GtkWidget *parentwin, DB_plugin_t *p) {
- // create window
- GtkWidget *win = gtk_window_new (GTK_WINDOW_TOPLEVEL);
- gtk_container_set_border_width (GTK_CONTAINER(win), 12);
-// gtk_widget_set_events (win, GDK_KEY_PRESS_MASK);
- gtk_widget_set_size_request (win, 300, -1);
- g_signal_connect ((gpointer) win, "key_press_event", G_CALLBACK (on_plug_prefwin_key_press_event), NULL);
- char title[200];
- snprintf (title, sizeof (title), "Setup %s", p->name);
- gtk_window_set_title (GTK_WINDOW (win), title);
- gtk_window_set_modal (GTK_WINDOW (win), TRUE);
- gtk_window_set_transient_for (GTK_WINDOW (win), GTK_WINDOW (parentwin));
- GtkWidget *vbox;
- vbox = gtk_vbox_new (FALSE, 8);
- gtk_widget_show (vbox);
- gtk_container_add (GTK_CONTAINER (win), vbox);
-// GtkWidget *tbl;
-// tbl = gtk_table_new (1, 2, FALSE);
-// gtk_container_set_border_width (GTK_CONTAINER (tbl), 3);
-// gtk_table_set_col_spacings (GTK_TABLE (tbl), 3);
-// gtk_container_add (GTK_CONTAINER (win), tbl);
-
- int nrows = 0;
- // parse script
- char token[MAX_TOKEN];
- const char *script = p->configdialog;
- parser_line = 1;
- while (script = gettoken (script, token)) {
- if (strcmp (token, "property")) {
- fprintf (stderr, "invalid token while loading plugin %s config dialog: %s at line %d\n", p->name, token, parser_line);
- break;
- }
- char labeltext[MAX_TOKEN];
- script = gettoken_warn_eof (script, labeltext);
- if (!script) {
- break;
- }
- char type[MAX_TOKEN];
- script = gettoken_warn_eof (script, type);
- if (!script) {
- break;
- }
- char key[MAX_TOKEN];
- script = gettoken_warn_eof (script, key);
- if (!script) {
- break;
- }
- char def[MAX_TOKEN];
- script = gettoken_warn_eof (script, def);
- if (!script) {
- break;
- }
- script = gettoken_warn_eof (script, token);
- if (!script) {
- break;
- }
- if (strcmp (token, ";")) {
- fprintf (stderr, "expected `;' while loading plugin %s config dialog: %s at line %d\n", p->name, token, parser_line);
- break;
- }
-
- // add to dialog
- nrows++;
- //gtk_table_resize (GTK_TABLE (tbl), nrows, 2);
- GtkWidget *label = NULL;
- GtkWidget *prop = NULL;
- if (!strcmp (type, "entry") || !strcmp (type, "password")) {
- label = gtk_label_new (labeltext);
- prop = gtk_entry_new ();
- gtk_entry_set_text (GTK_ENTRY (prop), deadbeef->conf_get_str (key, def));
- g_signal_connect ((gpointer) prop, "changed",
- G_CALLBACK (on_prop_entry_changed),
- NULL);
- }
- else if (!strcmp (type, "checkbox")) {
- prop = gtk_check_button_new_with_label (labeltext);
- int val = deadbeef->conf_get_int (key, atoi (def));
- gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (prop), val);
- g_signal_connect ((gpointer) prop, "clicked",
- G_CALLBACK (on_prop_checkbox_clicked),
- NULL);
- }
- else if (!strcmp (type, "file")) {
- GtkWidget *cont = NULL;
- label = gtk_label_new (labeltext);
- cont = gtk_hbox_new (FALSE, 2);
- prop = gtk_entry_new ();
- gtk_editable_set_editable (GTK_EDITABLE (prop), FALSE);
- g_signal_connect ((gpointer) prop, "changed",
- G_CALLBACK (on_prop_entry_changed),
- NULL);
- gtk_entry_set_text (GTK_ENTRY (prop), deadbeef->conf_get_str (key, def));
- gtk_box_pack_start (GTK_BOX (cont), prop, TRUE, TRUE, 0);
- GtkWidget *btn = gtk_button_new_with_label ("…");
- gtk_box_pack_start (GTK_BOX (cont), btn, FALSE, FALSE, 0);
- g_signal_connect (G_OBJECT (btn), "clicked", G_CALLBACK (on_prop_browse_file), prop);
- prop = cont;
- }
- if (!strcmp (type, "password")) {
- gtk_entry_set_visibility (GTK_ENTRY (prop), FALSE);
- }
- if (label && prop) {
- GtkWidget *hbox = NULL;
- hbox = gtk_hbox_new (FALSE, 8);
- gtk_widget_show (hbox);
- gtk_box_pack_start (GTK_BOX (hbox), label, FALSE, FALSE, 0);
- gtk_box_pack_start (GTK_BOX (hbox), prop, TRUE, TRUE, 0);
- prop = hbox;
- }
- if (prop) {
- char *keydup = strdup (key);
- g_object_set_data_full (G_OBJECT (prop), "key", keydup, (GDestroyNotify)free);
- gtk_box_pack_start (GTK_BOX (vbox), prop, FALSE, FALSE, 0);
-// gtk_table_attach (GTK_TABLE (tbl), label, 0, 1, nrows-1, nrows, (GtkAttachOptions) (GTK_FILL), (GtkAttachOptions)0, 0, 0);
-// gtk_misc_set_alignment (GTK_MISC (label), 0, 0.5);
-// gtk_table_attach (GTK_TABLE (tbl), cont, 1, 2, nrows-1, nrows, (GtkAttachOptions) (GTK_EXPAND | GTK_FILL), (GtkAttachOptions)0, 0, 0);
- }
- }
-
-
- gtk_widget_show_all (win);
-}
-
void
on_configure_plugin_clicked (GtkButton *button,
gpointer user_data)
diff --git a/plugins/gtkui/deadbeef.glade b/plugins/gtkui/deadbeef.glade
index 0f63d898..239398b9 100644
--- a/plugins/gtkui/deadbeef.glade
+++ b/plugins/gtkui/deadbeef.glade
@@ -1283,6 +1283,7 @@
</widget>
<widget class="GtkWindow" id="addprogress">
+ <property name="border_width">12</property>
<property name="visible">True</property>
<property name="title" translatable="yes">Adding files...</property>
<property name="type">GTK_WINDOW_TOPLEVEL</property>
@@ -1301,10 +1302,9 @@
<child>
<widget class="GtkVBox" id="vbox6">
- <property name="border_width">4</property>
<property name="visible">True</property>
<property name="homogeneous">False</property>
- <property name="spacing">0</property>
+ <property name="spacing">8</property>
<child>
<widget class="GtkEntry" id="progresstitle">
@@ -1435,17 +1435,147 @@
</child>
</widget>
-<widget class="GtkWindow" id="prefwin">
+<widget class="GtkMenu" id="headermenu">
+
+ <child>
+ <widget class="GtkMenuItem" id="add_column">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Add column</property>
+ <property name="use_underline">True</property>
+ <signal name="activate" handler="on_add_column_activate" last_modification_time="Sat, 02 Jan 2010 15:30:54 GMT"/>
+ </widget>
+ </child>
+
+ <child>
+ <widget class="GtkMenuItem" id="edit_column">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Edit column</property>
+ <property name="use_underline">True</property>
+ <signal name="activate" handler="on_edit_column_activate" last_modification_time="Sat, 02 Jan 2010 15:30:54 GMT"/>
+ </widget>
+ </child>
+
+ <child>
+ <widget class="GtkMenuItem" id="remove_column">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Remove column</property>
+ <property name="use_underline">True</property>
+ <signal name="activate" handler="on_remove_column_activate" last_modification_time="Mon, 19 Oct 2009 19:30:04 GMT"/>
+ </widget>
+ </child>
+</widget>
+
+<widget class="GtkWindow" id="addlocation">
<property name="border_width">12</property>
- <property name="width_request">642</property>
- <property name="height_request">372</property>
<property name="visible">True</property>
- <property name="title" translatable="yes">Preferences</property>
+ <property name="title" translatable="yes">Add Location</property>
<property name="type">GTK_WINDOW_TOPLEVEL</property>
<property name="window_position">GTK_WIN_POS_NONE</property>
<property name="modal">True</property>
<property name="resizable">True</property>
- <property name="destroy_with_parent">False</property>
+ <property name="destroy_with_parent">True</property>
+ <property name="decorated">True</property>
+ <property name="skip_taskbar_hint">True</property>
+ <property name="skip_pager_hint">True</property>
+ <property name="type_hint">GDK_WINDOW_TYPE_HINT_NORMAL</property>
+ <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
+ <property name="focus_on_map">True</property>
+ <property name="urgency_hint">False</property>
+ <signal name="key_press_event" handler="on_addlocation_key_press_event" last_modification_time="Sat, 07 Nov 2009 17:25:40 GMT"/>
+
+ <child>
+ <widget class="GtkVBox" id="vbox7">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkEntry" id="addlocation_entry">
+ <property name="width_request">346</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">True</property>
+ <property name="visibility">True</property>
+ <property name="max_length">0</property>
+ <property name="text" translatable="yes"></property>
+ <property name="has_frame">True</property>
+ <property name="invisible_char">•</property>
+ <property name="activates_default">False</property>
+ <signal name="activate" handler="on_addlocation_entry_activate" last_modification_time="Sat, 07 Nov 2009 18:13:04 GMT"/>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkHBox" id="hbox8">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">0</property>
+
+ <child>
+ <widget class="GtkLabel" id="label21">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes"></property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkButton" id="addlocation_ok">
+ <property name="width_request">83</property>
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">OK</property>
+ <property name="use_underline">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ <signal name="clicked" handler="on_addlocation_ok_clicked" last_modification_time="Sat, 07 Nov 2009 18:12:00 GMT"/>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">2</property>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ </child>
+</widget>
+
+<widget class="GtkWindow" id="trackproperties">
+ <property name="visible">True</property>
+ <property name="title" translatable="yes">Track Properties</property>
+ <property name="type">GTK_WINDOW_TOPLEVEL</property>
+ <property name="window_position">GTK_WIN_POS_NONE</property>
+ <property name="modal">False</property>
+ <property name="resizable">True</property>
+ <property name="destroy_with_parent">True</property>
<property name="decorated">True</property>
<property name="skip_taskbar_hint">True</property>
<property name="skip_pager_hint">True</property>
@@ -1453,16 +1583,884 @@
<property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
<property name="focus_on_map">True</property>
<property name="urgency_hint">False</property>
- <signal name="key_press_event" handler="on_prefwin_key_press_event" last_modification_time="Sat, 07 Nov 2009 15:47:40 GMT"/>
- <signal name="delete_event" handler="on_prefwin_delete_event" last_modification_time="Tue, 22 Dec 2009 20:16:22 GMT"/>
+ <signal name="key_press_event" handler="on_trackproperties_key_press_event" last_modification_time="Thu, 31 Dec 2009 13:46:40 GMT"/>
+ <signal name="delete_event" handler="on_trackproperties_delete_event" last_modification_time="Sat, 02 Jan 2010 21:38:32 GMT"/>
<child>
- <widget class="GtkVBox" id="pref_vbox">
+ <widget class="GtkVBox" id="vbox13">
+ <property name="border_width">12</property>
<property name="visible">True</property>
<property name="homogeneous">False</property>
<property name="spacing">8</property>
<child>
+ <widget class="GtkHBox" id="hbox23">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkLabel" id="label27">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Location:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkEntry" id="location">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="visibility">True</property>
+ <property name="max_length">0</property>
+ <property name="text" translatable="yes"></property>
+ <property name="has_frame">True</property>
+ <property name="invisible_char">•</property>
+ <property name="activates_default">False</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkHBox" id="hbox24">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkLabel" id="label28">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Title:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkEntry" id="title">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="visibility">True</property>
+ <property name="max_length">0</property>
+ <property name="text" translatable="yes"></property>
+ <property name="has_frame">True</property>
+ <property name="invisible_char">•</property>
+ <property name="activates_default">False</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkHBox" id="hbox25">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkLabel" id="label29">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Artist:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkEntry" id="artist">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="visibility">True</property>
+ <property name="max_length">0</property>
+ <property name="text" translatable="yes"></property>
+ <property name="has_frame">True</property>
+ <property name="invisible_char">•</property>
+ <property name="activates_default">False</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkHBox" id="hbox26">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkLabel" id="label30">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Album:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkEntry" id="album">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="visibility">True</property>
+ <property name="max_length">0</property>
+ <property name="text" translatable="yes"></property>
+ <property name="has_frame">True</property>
+ <property name="invisible_char">•</property>
+ <property name="activates_default">False</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkHBox" id="hbox27">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkLabel" id="label35">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Genre:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkEntry" id="genre">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="visibility">True</property>
+ <property name="max_length">0</property>
+ <property name="text" translatable="yes"></property>
+ <property name="has_frame">True</property>
+ <property name="invisible_char">•</property>
+ <property name="activates_default">False</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkTable" id="table8">
+ <property name="visible">True</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">2</property>
+ <property name="homogeneous">False</property>
+ <property name="row_spacing">8</property>
+ <property name="column_spacing">8</property>
+
+ <child>
+ <widget class="GtkLabel" id="label31">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Year:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">True</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="right_attach">1</property>
+ <property name="top_attach">0</property>
+ <property name="bottom_attach">1</property>
+ <property name="x_options">fill</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkLabel" id="label33">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Track:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">True</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">0</property>
+ <property name="bottom_attach">1</property>
+ <property name="x_options">fill</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkEntry" id="year">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="visibility">True</property>
+ <property name="max_length">0</property>
+ <property name="text" translatable="yes"></property>
+ <property name="has_frame">True</property>
+ <property name="invisible_char">•</property>
+ <property name="activates_default">False</property>
+ </widget>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="right_attach">1</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkEntry" id="track">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="visibility">True</property>
+ <property name="max_length">0</property>
+ <property name="text" translatable="yes"></property>
+ <property name="has_frame">True</property>
+ <property name="invisible_char">•</property>
+ <property name="activates_default">False</property>
+ </widget>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkHBox" id="hbox28">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkLabel" id="label36">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Comment:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkScrolledWindow" id="scrolledwindow4">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
+ <property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
+ <property name="shadow_type">GTK_SHADOW_IN</property>
+ <property name="window_placement">GTK_CORNER_TOP_LEFT</property>
+
+ <child>
+ <widget class="GtkTextView" id="comment">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="overwrite">False</property>
+ <property name="accepts_tab">True</property>
+ <property name="justification">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap_mode">GTK_WRAP_NONE</property>
+ <property name="cursor_visible">True</property>
+ <property name="pixels_above_lines">0</property>
+ <property name="pixels_below_lines">0</property>
+ <property name="pixels_inside_wrap">0</property>
+ <property name="left_margin">0</property>
+ <property name="right_margin">0</property>
+ <property name="indent">0</property>
+ <property name="text" translatable="yes"></property>
+ </widget>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ </child>
+</widget>
+
+<widget class="GtkDialog" id="editcolumndlg">
+ <property name="border_width">12</property>
+ <property name="visible">True</property>
+ <property name="title" translatable="yes">dialog1</property>
+ <property name="type">GTK_WINDOW_TOPLEVEL</property>
+ <property name="window_position">GTK_WIN_POS_NONE</property>
+ <property name="modal">True</property>
+ <property name="resizable">True</property>
+ <property name="destroy_with_parent">False</property>
+ <property name="decorated">True</property>
+ <property name="skip_taskbar_hint">False</property>
+ <property name="skip_pager_hint">False</property>
+ <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property>
+ <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
+ <property name="focus_on_map">True</property>
+ <property name="urgency_hint">False</property>
+ <property name="has_separator">True</property>
+
+ <child internal-child="vbox">
+ <widget class="GtkVBox" id="dialog-vbox1">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">0</property>
+
+ <child internal-child="action_area">
+ <widget class="GtkHButtonBox" id="dialog-action_area1">
+ <property name="visible">True</property>
+ <property name="layout_style">GTK_BUTTONBOX_END</property>
+
+ <child>
+ <widget class="GtkButton" id="cancelbutton1">
+ <property name="visible">True</property>
+ <property name="can_default">True</property>
+ <property name="can_focus">True</property>
+ <property name="label">_Cancel</property>
+ <property name="use_underline">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ <property name="response_id">-6</property>
+ </widget>
+ </child>
+
+ <child>
+ <widget class="GtkButton" id="okbutton1">
+ <property name="visible">True</property>
+ <property name="can_default">True</property>
+ <property name="can_focus">True</property>
+ <property name="label">_OK</property>
+ <property name="use_underline">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ <property name="response_id">-5</property>
+ </widget>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">GTK_PACK_END</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkVBox" id="vbox14">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkHBox" id="hbox29">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkLabel" id="label26">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Title:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkEntry" id="title">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">True</property>
+ <property name="visibility">True</property>
+ <property name="max_length">0</property>
+ <property name="text" translatable="yes">Enter new column title here</property>
+ <property name="has_frame">True</property>
+ <property name="invisible_char">●</property>
+ <property name="activates_default">True</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkHBox" id="hbox30">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkLabel" id="label37">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Type:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkComboBox" id="id">
+ <property name="visible">True</property>
+ <property name="items" translatable="yes">File number
+Playing
+Artist - Album
+Artist
+Album
+Title
+Length
+Track
+Custom</property>
+ <property name="add_tearoffs">False</property>
+ <property name="focus_on_click">True</property>
+ <signal name="changed" handler="on_column_id_changed" last_modification_time="Mon, 04 Jan 2010 17:31:44 GMT"/>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkHBox" id="hbox31">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkLabel" id="fmtlabel">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Format:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkEntry" id="format">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">True</property>
+ <property name="visibility">True</property>
+ <property name="max_length">0</property>
+ <property name="text" translatable="yes"></property>
+ <property name="has_frame">True</property>
+ <property name="invisible_char">●</property>
+ <property name="activates_default">True</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkHBox" id="hbox32">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child>
+ <widget class="GtkLabel" id="label38">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Alignment:</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkComboBox" id="align">
+ <property name="visible">True</property>
+ <property name="items" translatable="yes">Left
+Right</property>
+ <property name="add_tearoffs">False</property>
+ <property name="focus_on_click">True</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkLabel" id="label25">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="label" translatable="yes">Format conversions (start with %):
+ [a]rtist, [t]itle, al[b]um, track[n]umber,
+ [l]ength, [y]ear, [g]enre, [c]omment,
+ copy[r]ight, [f]ilename
+Example: %a - %t [%l]</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">True</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">True</property>
+ <property name="xalign">0.10000000149</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </widget>
+ </child>
+</widget>
+
+<widget class="GtkDialog" id="prefwin">
+ <property name="border_width">12</property>
+ <property name="width_request">630</property>
+ <property name="height_request">400</property>
+ <property name="visible">True</property>
+ <property name="title" translatable="yes">Preferences</property>
+ <property name="type">GTK_WINDOW_TOPLEVEL</property>
+ <property name="window_position">GTK_WIN_POS_NONE</property>
+ <property name="modal">False</property>
+ <property name="default_width">630</property>
+ <property name="default_height">400</property>
+ <property name="resizable">True</property>
+ <property name="destroy_with_parent">False</property>
+ <property name="decorated">True</property>
+ <property name="skip_taskbar_hint">False</property>
+ <property name="skip_pager_hint">False</property>
+ <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property>
+ <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
+ <property name="focus_on_map">True</property>
+ <property name="urgency_hint">False</property>
+ <property name="has_separator">True</property>
+
+ <child internal-child="vbox">
+ <widget class="GtkVBox" id="dialog-vbox2">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">8</property>
+
+ <child internal-child="action_area">
+ <widget class="GtkHButtonBox" id="dialog-action_area2">
+ <property name="visible">True</property>
+ <property name="layout_style">GTK_BUTTONBOX_END</property>
+
+ <child>
+ <widget class="GtkButton" id="closebutton1">
+ <property name="visible">True</property>
+ <property name="can_default">True</property>
+ <property name="can_focus">True</property>
+ <property name="label">gtk-close</property>
+ <property name="use_stock">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ <property name="response_id">-7</property>
+ </widget>
+ </child>
+ </widget>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">GTK_PACK_END</property>
+ </packing>
+ </child>
+
+ <child>
<widget class="GtkNotebook" id="notebook2">
<property name="visible">True</property>
<property name="can_focus">True</property>
@@ -1515,7 +2513,6 @@
<property name="visible">True</property>
<property name="add_tearoffs">False</property>
<property name="focus_on_click">True</property>
- <signal name="changed" handler="on_pref_output_plugin_changed" last_modification_time="Fri, 11 Dec 2009 21:05:28 GMT"/>
</widget>
<packing>
<property name="padding">0</property>
@@ -1567,7 +2564,6 @@
<property name="visible">True</property>
<property name="add_tearoffs">False</property>
<property name="focus_on_click">True</property>
- <signal name="changed" handler="on_pref_soundcard_changed" last_modification_time="Sat, 07 Nov 2009 14:12:28 GMT"/>
</widget>
<packing>
<property name="padding">0</property>
@@ -2432,1029 +3428,6 @@ SOCKS5_HOSTNAME</property>
<property name="fill">True</property>
</packing>
</child>
-
- <child>
- <widget class="GtkHBox" id="hbox21">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">0</property>
-
- <child>
- <widget class="GtkLabel" id="filler">
- <property name="visible">True</property>
- <property name="label" translatable="yes"></property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0.5</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkButton" id="pref_close">
- <property name="width_request">76</property>
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- <property name="focus_on_click">True</property>
- <signal name="clicked" handler="on_pref_close_clicked" last_modification_time="Thu, 28 Jan 2010 20:09:43 GMT"/>
-
- <child>
- <widget class="GtkAlignment" id="alignment1">
- <property name="visible">True</property>
- <property name="xalign">0.5</property>
- <property name="yalign">0.5</property>
- <property name="xscale">0</property>
- <property name="yscale">0</property>
- <property name="top_padding">0</property>
- <property name="bottom_padding">0</property>
- <property name="left_padding">0</property>
- <property name="right_padding">0</property>
-
- <child>
- <widget class="GtkHBox" id="hbox22">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">2</property>
-
- <child>
- <widget class="GtkImage" id="image321">
- <property name="visible">True</property>
- <property name="stock">gtk-close</property>
- <property name="icon_size">4</property>
- <property name="xalign">0.5</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label40">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Close</property>
- <property name="use_underline">True</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0.5</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
- </widget>
- </child>
- </widget>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
- </child>
- </widget>
- </child>
-</widget>
-
-<widget class="GtkMenu" id="headermenu">
-
- <child>
- <widget class="GtkMenuItem" id="add_column">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Add column</property>
- <property name="use_underline">True</property>
- <signal name="activate" handler="on_add_column_activate" last_modification_time="Sat, 02 Jan 2010 15:30:54 GMT"/>
- </widget>
- </child>
-
- <child>
- <widget class="GtkMenuItem" id="edit_column">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Edit column</property>
- <property name="use_underline">True</property>
- <signal name="activate" handler="on_edit_column_activate" last_modification_time="Sat, 02 Jan 2010 15:30:54 GMT"/>
- </widget>
- </child>
-
- <child>
- <widget class="GtkMenuItem" id="remove_column">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Remove column</property>
- <property name="use_underline">True</property>
- <signal name="activate" handler="on_remove_column_activate" last_modification_time="Mon, 19 Oct 2009 19:30:04 GMT"/>
- </widget>
- </child>
-</widget>
-
-<widget class="GtkWindow" id="addlocation">
- <property name="visible">True</property>
- <property name="title" translatable="yes">Add Location</property>
- <property name="type">GTK_WINDOW_TOPLEVEL</property>
- <property name="window_position">GTK_WIN_POS_NONE</property>
- <property name="modal">True</property>
- <property name="resizable">True</property>
- <property name="destroy_with_parent">True</property>
- <property name="decorated">True</property>
- <property name="skip_taskbar_hint">True</property>
- <property name="skip_pager_hint">True</property>
- <property name="type_hint">GDK_WINDOW_TYPE_HINT_NORMAL</property>
- <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
- <property name="focus_on_map">True</property>
- <property name="urgency_hint">False</property>
- <signal name="key_press_event" handler="on_addlocation_key_press_event" last_modification_time="Sat, 07 Nov 2009 17:25:40 GMT"/>
-
- <child>
- <widget class="GtkVBox" id="vbox7">
- <property name="border_width">4</property>
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">0</property>
-
- <child>
- <widget class="GtkEntry" id="addlocation_entry">
- <property name="width_request">346</property>
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">True</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char">•</property>
- <property name="activates_default">False</property>
- <signal name="activate" handler="on_addlocation_entry_activate" last_modification_time="Sat, 07 Nov 2009 18:13:04 GMT"/>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkHBox" id="hbox8">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">0</property>
-
- <child>
- <widget class="GtkLabel" id="label21">
- <property name="visible">True</property>
- <property name="label" translatable="yes"></property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0.5</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">True</property>
- <property name="fill">False</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkButton" id="addlocation_ok">
- <property name="width_request">83</property>
- <property name="visible">True</property>
- <property name="label" translatable="yes">OK</property>
- <property name="use_underline">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- <property name="focus_on_click">True</property>
- <signal name="clicked" handler="on_addlocation_ok_clicked" last_modification_time="Sat, 07 Nov 2009 18:12:00 GMT"/>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="padding">2</property>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
- </child>
- </widget>
- </child>
-</widget>
-
-<widget class="GtkWindow" id="trackproperties">
- <property name="visible">True</property>
- <property name="title" translatable="yes">Track Properties</property>
- <property name="type">GTK_WINDOW_TOPLEVEL</property>
- <property name="window_position">GTK_WIN_POS_NONE</property>
- <property name="modal">False</property>
- <property name="resizable">True</property>
- <property name="destroy_with_parent">True</property>
- <property name="decorated">True</property>
- <property name="skip_taskbar_hint">True</property>
- <property name="skip_pager_hint">True</property>
- <property name="type_hint">GDK_WINDOW_TYPE_HINT_NORMAL</property>
- <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
- <property name="focus_on_map">True</property>
- <property name="urgency_hint">False</property>
- <signal name="key_press_event" handler="on_trackproperties_key_press_event" last_modification_time="Thu, 31 Dec 2009 13:46:40 GMT"/>
- <signal name="delete_event" handler="on_trackproperties_delete_event" last_modification_time="Sat, 02 Jan 2010 21:38:32 GMT"/>
-
- <child>
- <widget class="GtkTable" id="table7">
- <property name="border_width">3</property>
- <property name="visible">True</property>
- <property name="n_rows">7</property>
- <property name="n_columns">2</property>
- <property name="homogeneous">False</property>
- <property name="row_spacing">4</property>
- <property name="column_spacing">4</property>
-
- <child>
- <widget class="GtkLabel" id="label27">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Location</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">0</property>
- <property name="bottom_attach">1</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="location">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">False</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char">•</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">0</property>
- <property name="bottom_attach">1</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label28">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Title</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label29">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Artist</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label30">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Album</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">3</property>
- <property name="bottom_attach">4</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="title">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">False</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char">•</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="artist">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">False</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char">•</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="album">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">False</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char">•</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">3</property>
- <property name="bottom_attach">4</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label35">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Genre</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">4</property>
- <property name="bottom_attach">5</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="genre">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">False</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char">•</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">4</property>
- <property name="bottom_attach">5</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label36">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Comment</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">6</property>
- <property name="bottom_attach">7</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkTable" id="table8">
- <property name="visible">True</property>
- <property name="n_rows">2</property>
- <property name="n_columns">2</property>
- <property name="homogeneous">False</property>
- <property name="row_spacing">0</property>
- <property name="column_spacing">3</property>
-
- <child>
- <widget class="GtkLabel" id="label31">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Year</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">True</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">0</property>
- <property name="bottom_attach">1</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label33">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Track</property>
- <property name="use_underline">False</property>
- <property name="use_markup">True</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">0</property>
- <property name="bottom_attach">1</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="year">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">False</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char">•</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="track">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">False</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char">•</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="y_options"></property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">2</property>
- <property name="top_attach">5</property>
- <property name="bottom_attach">6</property>
- <property name="x_options">fill</property>
- <property name="y_options">fill</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkScrolledWindow" id="scrolledwindow4">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
- <property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
- <property name="shadow_type">GTK_SHADOW_IN</property>
- <property name="window_placement">GTK_CORNER_TOP_LEFT</property>
-
- <child>
- <widget class="GtkTextView" id="comment">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">False</property>
- <property name="overwrite">False</property>
- <property name="accepts_tab">True</property>
- <property name="justification">GTK_JUSTIFY_LEFT</property>
- <property name="wrap_mode">GTK_WRAP_NONE</property>
- <property name="cursor_visible">True</property>
- <property name="pixels_above_lines">0</property>
- <property name="pixels_below_lines">0</property>
- <property name="pixels_inside_wrap">0</property>
- <property name="left_margin">0</property>
- <property name="right_margin">0</property>
- <property name="indent">0</property>
- <property name="text" translatable="yes"></property>
- </widget>
- </child>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">6</property>
- <property name="bottom_attach">7</property>
- <property name="x_options">fill</property>
- </packing>
- </child>
- </widget>
- </child>
-</widget>
-
-<widget class="GtkDialog" id="editcolumndlg">
- <property name="visible">True</property>
- <property name="title" translatable="yes">dialog1</property>
- <property name="type">GTK_WINDOW_TOPLEVEL</property>
- <property name="window_position">GTK_WIN_POS_NONE</property>
- <property name="modal">True</property>
- <property name="resizable">True</property>
- <property name="destroy_with_parent">False</property>
- <property name="decorated">True</property>
- <property name="skip_taskbar_hint">False</property>
- <property name="skip_pager_hint">False</property>
- <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property>
- <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
- <property name="focus_on_map">True</property>
- <property name="urgency_hint">False</property>
- <property name="has_separator">True</property>
-
- <child internal-child="vbox">
- <widget class="GtkVBox" id="dialog-vbox1">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">0</property>
-
- <child internal-child="action_area">
- <widget class="GtkHButtonBox" id="dialog-action_area1">
- <property name="visible">True</property>
- <property name="layout_style">GTK_BUTTONBOX_END</property>
-
- <child>
- <widget class="GtkButton" id="cancelbutton1">
- <property name="visible">True</property>
- <property name="can_default">True</property>
- <property name="can_focus">True</property>
- <property name="label">_Cancel</property>
- <property name="use_underline">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- <property name="focus_on_click">True</property>
- <property name="response_id">-6</property>
- </widget>
- </child>
-
- <child>
- <widget class="GtkButton" id="okbutton1">
- <property name="visible">True</property>
- <property name="can_default">True</property>
- <property name="can_focus">True</property>
- <property name="label">_OK</property>
- <property name="use_underline">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- <property name="focus_on_click">True</property>
- <property name="response_id">-5</property>
- </widget>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="pack_type">GTK_PACK_END</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkTable" id="table9">
- <property name="border_width">3</property>
- <property name="visible">True</property>
- <property name="n_rows">5</property>
- <property name="n_columns">2</property>
- <property name="homogeneous">False</property>
- <property name="row_spacing">0</property>
- <property name="column_spacing">3</property>
-
- <child>
- <widget class="GtkLabel" id="label26">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Title</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">0</property>
- <property name="bottom_attach">1</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="title">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">True</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes">Enter new column title here</property>
- <property name="has_frame">True</property>
- <property name="invisible_char">●</property>
- <property name="activates_default">True</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">0</property>
- <property name="bottom_attach">1</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label37">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Type</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkComboBox" id="id">
- <property name="visible">True</property>
- <property name="items" translatable="yes">File number
-Playing
-Artist - Album
-Artist
-Album
-Title
-Length
-Track
-Custom</property>
- <property name="add_tearoffs">False</property>
- <property name="focus_on_click">True</property>
- <signal name="changed" handler="on_column_id_changed" last_modification_time="Mon, 04 Jan 2010 17:31:44 GMT"/>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="x_options">fill</property>
- <property name="y_options">fill</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="fmtlabel">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Format</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="format">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">True</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char">●</property>
- <property name="activates_default">True</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label25">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">Format conversions (start with %):
- [a]rtist, [t]itle, al[b]um, track[n]umber,
- [l]ength, [y]ear, [g]enre, [c]omment,
- copy[r]ight, [f]ilename
-Example: %a - %t [%l]</property>
- <property name="use_underline">False</property>
- <property name="use_markup">True</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">True</property>
- <property name="xalign">0.10000000149</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">2</property>
- <property name="top_attach">4</property>
- <property name="bottom_attach">5</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label38">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Alignment</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">3</property>
- <property name="bottom_attach">4</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkComboBox" id="align">
- <property name="visible">True</property>
- <property name="items" translatable="yes">Left
-Right</property>
- <property name="add_tearoffs">False</property>
- <property name="focus_on_click">True</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">3</property>
- <property name="bottom_attach">4</property>
- <property name="x_options">fill</property>
- <property name="y_options">fill</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
- </child>
</widget>
</child>
</widget>
diff --git a/plugins/gtkui/gtkui.c b/plugins/gtkui/gtkui.c
index 69dec742..c05cbdad 100644
--- a/plugins/gtkui/gtkui.c
+++ b/plugins/gtkui/gtkui.c
@@ -21,6 +21,7 @@
#include <string.h>
#include <stdlib.h>
#include <math.h>
+#include "gtkui.h"
#include "gtkplaylist.h"
#include "search.h"
#include "progress.h"
@@ -347,7 +348,6 @@ gtkui_on_configchanged (DB_event_t *ev, uintptr_t data) {
static gboolean
outputchanged_cb (gpointer nothing) {
- void preferences_fill_soundcards (void);
preferences_fill_soundcards ();
return FALSE;
}
diff --git a/plugins/gtkui/gtkui.h b/plugins/gtkui/gtkui.h
index ae88ecff..fd8e1166 100644
--- a/plugins/gtkui/gtkui.h
+++ b/plugins/gtkui/gtkui.h
@@ -1,3 +1,21 @@
+/*
+ DeaDBeeF - ultimate music player for GNU/Linux systems with X11
+ Copyright (C) 2009-2010 Alexey Yakovenko <waker@users.sourceforge.net>
+
+ This program is free software; you can redistribute it and/or
+ modify it under the terms of the GNU General Public License
+ as published by the Free Software Foundation; either version 2
+ of the License, or (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+*/
#ifndef __GTKUI_H
#define __GTKUI_H
@@ -5,6 +23,8 @@ extern DB_functions_t *deadbeef;
struct _GSList;
+// misc utility functions
+
void
gtkui_add_dirs (struct _GSList *lst);
@@ -17,4 +37,12 @@ gtkui_open_files (struct _GSList *lst);
void
gtkui_receive_fm_drop (char *mem, int length, int drop_y);
+// plugin configuration dialogs
+
+void
+plugin_configure (GtkWidget *parentwin, DB_plugin_t *p);
+
+void
+preferences_fill_soundcards (void);
+
#endif
diff --git a/plugins/gtkui/interface.c b/plugins/gtkui/interface.c
index 4a00e621..797186a7 100644
--- a/plugins/gtkui/interface.c
+++ b/plugins/gtkui/interface.c
@@ -1165,16 +1165,16 @@ create_addprogress (void)
GtkWidget *button1;
addprogress = gtk_window_new (GTK_WINDOW_TOPLEVEL);
+ gtk_container_set_border_width (GTK_CONTAINER (addprogress), 12);
gtk_window_set_title (GTK_WINDOW (addprogress), "Adding files...");
gtk_window_set_position (GTK_WINDOW (addprogress), GTK_WIN_POS_CENTER_ON_PARENT);
gtk_window_set_modal (GTK_WINDOW (addprogress), TRUE);
gtk_window_set_skip_taskbar_hint (GTK_WINDOW (addprogress), TRUE);
gtk_window_set_skip_pager_hint (GTK_WINDOW (addprogress), TRUE);
- vbox6 = gtk_vbox_new (FALSE, 0);
+ vbox6 = gtk_vbox_new (FALSE, 8);
gtk_widget_show (vbox6);
gtk_container_add (GTK_CONTAINER (addprogress), vbox6);
- gtk_container_set_border_width (GTK_CONTAINER (vbox6), 4);
progresstitle = gtk_entry_new ();
gtk_widget_show (progresstitle);
@@ -1258,10 +1258,480 @@ create_helpwindow (void)
}
GtkWidget*
+create_headermenu (void)
+{
+ GtkWidget *headermenu;
+ GtkWidget *add_column;
+ GtkWidget *edit_column;
+ GtkWidget *remove_column;
+
+ headermenu = gtk_menu_new ();
+
+ add_column = gtk_menu_item_new_with_mnemonic ("Add column");
+ gtk_widget_show (add_column);
+ gtk_container_add (GTK_CONTAINER (headermenu), add_column);
+
+ edit_column = gtk_menu_item_new_with_mnemonic ("Edit column");
+ gtk_widget_show (edit_column);
+ gtk_container_add (GTK_CONTAINER (headermenu), edit_column);
+
+ remove_column = gtk_menu_item_new_with_mnemonic ("Remove column");
+ gtk_widget_show (remove_column);
+ gtk_container_add (GTK_CONTAINER (headermenu), remove_column);
+
+ g_signal_connect ((gpointer) add_column, "activate",
+ G_CALLBACK (on_add_column_activate),
+ NULL);
+ g_signal_connect ((gpointer) edit_column, "activate",
+ G_CALLBACK (on_edit_column_activate),
+ NULL);
+ g_signal_connect ((gpointer) remove_column, "activate",
+ G_CALLBACK (on_remove_column_activate),
+ NULL);
+
+ /* Store pointers to all widgets, for use by lookup_widget(). */
+ GLADE_HOOKUP_OBJECT_NO_REF (headermenu, headermenu, "headermenu");
+ GLADE_HOOKUP_OBJECT (headermenu, add_column, "add_column");
+ GLADE_HOOKUP_OBJECT (headermenu, edit_column, "edit_column");
+ GLADE_HOOKUP_OBJECT (headermenu, remove_column, "remove_column");
+
+ return headermenu;
+}
+
+GtkWidget*
+create_addlocation (void)
+{
+ GtkWidget *addlocation;
+ GtkWidget *vbox7;
+ GtkWidget *addlocation_entry;
+ GtkWidget *hbox8;
+ GtkWidget *label21;
+ GtkWidget *addlocation_ok;
+
+ addlocation = gtk_window_new (GTK_WINDOW_TOPLEVEL);
+ gtk_container_set_border_width (GTK_CONTAINER (addlocation), 12);
+ gtk_window_set_title (GTK_WINDOW (addlocation), "Add Location");
+ gtk_window_set_modal (GTK_WINDOW (addlocation), TRUE);
+ gtk_window_set_destroy_with_parent (GTK_WINDOW (addlocation), TRUE);
+ gtk_window_set_skip_taskbar_hint (GTK_WINDOW (addlocation), TRUE);
+ gtk_window_set_skip_pager_hint (GTK_WINDOW (addlocation), TRUE);
+
+ vbox7 = gtk_vbox_new (FALSE, 8);
+ gtk_widget_show (vbox7);
+ gtk_container_add (GTK_CONTAINER (addlocation), vbox7);
+
+ addlocation_entry = gtk_entry_new ();
+ gtk_widget_show (addlocation_entry);
+ gtk_box_pack_start (GTK_BOX (vbox7), addlocation_entry, FALSE, FALSE, 0);
+ gtk_widget_set_size_request (addlocation_entry, 346, -1);
+ gtk_entry_set_invisible_char (GTK_ENTRY (addlocation_entry), 8226);
+
+ hbox8 = gtk_hbox_new (FALSE, 0);
+ gtk_widget_show (hbox8);
+ gtk_box_pack_start (GTK_BOX (vbox7), hbox8, FALSE, TRUE, 2);
+
+ label21 = gtk_label_new ("");
+ gtk_widget_show (label21);
+ gtk_box_pack_start (GTK_BOX (hbox8), label21, TRUE, FALSE, 0);
+
+ addlocation_ok = gtk_button_new_with_mnemonic ("OK");
+ gtk_widget_show (addlocation_ok);
+ gtk_box_pack_start (GTK_BOX (hbox8), addlocation_ok, FALSE, FALSE, 0);
+ gtk_widget_set_size_request (addlocation_ok, 83, -1);
+ GTK_WIDGET_UNSET_FLAGS (addlocation_ok, GTK_CAN_FOCUS);
+
+ g_signal_connect ((gpointer) addlocation, "key_press_event",
+ G_CALLBACK (on_addlocation_key_press_event),
+ NULL);
+ g_signal_connect ((gpointer) addlocation_entry, "activate",
+ G_CALLBACK (on_addlocation_entry_activate),
+ NULL);
+ g_signal_connect ((gpointer) addlocation_ok, "clicked",
+ G_CALLBACK (on_addlocation_ok_clicked),
+ NULL);
+
+ /* Store pointers to all widgets, for use by lookup_widget(). */
+ GLADE_HOOKUP_OBJECT_NO_REF (addlocation, addlocation, "addlocation");
+ GLADE_HOOKUP_OBJECT (addlocation, vbox7, "vbox7");
+ GLADE_HOOKUP_OBJECT (addlocation, addlocation_entry, "addlocation_entry");
+ GLADE_HOOKUP_OBJECT (addlocation, hbox8, "hbox8");
+ GLADE_HOOKUP_OBJECT (addlocation, label21, "label21");
+ GLADE_HOOKUP_OBJECT (addlocation, addlocation_ok, "addlocation_ok");
+
+ return addlocation;
+}
+
+GtkWidget*
+create_trackproperties (void)
+{
+ GtkWidget *trackproperties;
+ GtkWidget *vbox13;
+ GtkWidget *hbox23;
+ GtkWidget *label27;
+ GtkWidget *location;
+ GtkWidget *hbox24;
+ GtkWidget *label28;
+ GtkWidget *title;
+ GtkWidget *hbox25;
+ GtkWidget *label29;
+ GtkWidget *artist;
+ GtkWidget *hbox26;
+ GtkWidget *label30;
+ GtkWidget *album;
+ GtkWidget *hbox27;
+ GtkWidget *label35;
+ GtkWidget *genre;
+ GtkWidget *table8;
+ GtkWidget *label31;
+ GtkWidget *label33;
+ GtkWidget *year;
+ GtkWidget *track;
+ GtkWidget *hbox28;
+ GtkWidget *label36;
+ GtkWidget *scrolledwindow4;
+ GtkWidget *comment;
+
+ trackproperties = gtk_window_new (GTK_WINDOW_TOPLEVEL);
+ gtk_window_set_title (GTK_WINDOW (trackproperties), "Track Properties");
+ gtk_window_set_destroy_with_parent (GTK_WINDOW (trackproperties), TRUE);
+ gtk_window_set_skip_taskbar_hint (GTK_WINDOW (trackproperties), TRUE);
+ gtk_window_set_skip_pager_hint (GTK_WINDOW (trackproperties), TRUE);
+
+ vbox13 = gtk_vbox_new (FALSE, 8);
+ gtk_widget_show (vbox13);
+ gtk_container_add (GTK_CONTAINER (trackproperties), vbox13);
+ gtk_container_set_border_width (GTK_CONTAINER (vbox13), 12);
+
+ hbox23 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox23);
+ gtk_box_pack_start (GTK_BOX (vbox13), hbox23, FALSE, FALSE, 0);
+
+ label27 = gtk_label_new ("Location:");
+ gtk_widget_show (label27);
+ gtk_box_pack_start (GTK_BOX (hbox23), label27, FALSE, FALSE, 0);
+ gtk_misc_set_alignment (GTK_MISC (label27), 0, 0.5);
+
+ location = gtk_entry_new ();
+ gtk_widget_show (location);
+ gtk_box_pack_start (GTK_BOX (hbox23), location, TRUE, TRUE, 0);
+ gtk_editable_set_editable (GTK_EDITABLE (location), FALSE);
+ gtk_entry_set_invisible_char (GTK_ENTRY (location), 8226);
+
+ hbox24 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox24);
+ gtk_box_pack_start (GTK_BOX (vbox13), hbox24, FALSE, FALSE, 0);
+
+ label28 = gtk_label_new ("Title:");
+ gtk_widget_show (label28);
+ gtk_box_pack_start (GTK_BOX (hbox24), label28, FALSE, FALSE, 0);
+ gtk_misc_set_alignment (GTK_MISC (label28), 0, 0.5);
+
+ title = gtk_entry_new ();
+ gtk_widget_show (title);
+ gtk_box_pack_start (GTK_BOX (hbox24), title, TRUE, TRUE, 0);
+ gtk_editable_set_editable (GTK_EDITABLE (title), FALSE);
+ gtk_entry_set_invisible_char (GTK_ENTRY (title), 8226);
+
+ hbox25 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox25);
+ gtk_box_pack_start (GTK_BOX (vbox13), hbox25, FALSE, FALSE, 0);
+
+ label29 = gtk_label_new ("Artist:");
+ gtk_widget_show (label29);
+ gtk_box_pack_start (GTK_BOX (hbox25), label29, FALSE, FALSE, 0);
+ gtk_misc_set_alignment (GTK_MISC (label29), 0, 0.5);
+
+ artist = gtk_entry_new ();
+ gtk_widget_show (artist);
+ gtk_box_pack_start (GTK_BOX (hbox25), artist, TRUE, TRUE, 0);
+ gtk_editable_set_editable (GTK_EDITABLE (artist), FALSE);
+ gtk_entry_set_invisible_char (GTK_ENTRY (artist), 8226);
+
+ hbox26 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox26);
+ gtk_box_pack_start (GTK_BOX (vbox13), hbox26, FALSE, FALSE, 0);
+
+ label30 = gtk_label_new ("Album:");
+ gtk_widget_show (label30);
+ gtk_box_pack_start (GTK_BOX (hbox26), label30, FALSE, FALSE, 0);
+ gtk_misc_set_alignment (GTK_MISC (label30), 0, 0.5);
+
+ album = gtk_entry_new ();
+ gtk_widget_show (album);
+ gtk_box_pack_start (GTK_BOX (hbox26), album, TRUE, TRUE, 0);
+ gtk_editable_set_editable (GTK_EDITABLE (album), FALSE);
+ gtk_entry_set_invisible_char (GTK_ENTRY (album), 8226);
+
+ hbox27 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox27);
+ gtk_box_pack_start (GTK_BOX (vbox13), hbox27, FALSE, FALSE, 0);
+
+ label35 = gtk_label_new ("Genre:");
+ gtk_widget_show (label35);
+ gtk_box_pack_start (GTK_BOX (hbox27), label35, FALSE, FALSE, 0);
+ gtk_misc_set_alignment (GTK_MISC (label35), 0, 0.5);
+
+ genre = gtk_entry_new ();
+ gtk_widget_show (genre);
+ gtk_box_pack_start (GTK_BOX (hbox27), genre, TRUE, TRUE, 0);
+ gtk_editable_set_editable (GTK_EDITABLE (genre), FALSE);
+ gtk_entry_set_invisible_char (GTK_ENTRY (genre), 8226);
+
+ table8 = gtk_table_new (2, 2, FALSE);
+ gtk_widget_show (table8);
+ gtk_box_pack_start (GTK_BOX (vbox13), table8, FALSE, FALSE, 0);
+ gtk_table_set_row_spacings (GTK_TABLE (table8), 8);
+ gtk_table_set_col_spacings (GTK_TABLE (table8), 8);
+
+ label31 = gtk_label_new ("Year:");
+ gtk_widget_show (label31);
+ gtk_table_attach (GTK_TABLE (table8), label31, 0, 1, 0, 1,
+ (GtkAttachOptions) (GTK_FILL),
+ (GtkAttachOptions) (0), 0, 0);
+ gtk_label_set_line_wrap (GTK_LABEL (label31), TRUE);
+ gtk_misc_set_alignment (GTK_MISC (label31), 0, 0.5);
+
+ label33 = gtk_label_new ("Track:");
+ gtk_widget_show (label33);
+ gtk_table_attach (GTK_TABLE (table8), label33, 1, 2, 0, 1,
+ (GtkAttachOptions) (GTK_FILL),
+ (GtkAttachOptions) (0), 0, 0);
+ gtk_label_set_use_markup (GTK_LABEL (label33), TRUE);
+ gtk_misc_set_alignment (GTK_MISC (label33), 0, 0.5);
+
+ year = gtk_entry_new ();
+ gtk_widget_show (year);
+ gtk_table_attach (GTK_TABLE (table8), year, 0, 1, 1, 2,
+ (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
+ (GtkAttachOptions) (0), 0, 0);
+ gtk_editable_set_editable (GTK_EDITABLE (year), FALSE);
+ gtk_entry_set_invisible_char (GTK_ENTRY (year), 8226);
+
+ track = gtk_entry_new ();
+ gtk_widget_show (track);
+ gtk_table_attach (GTK_TABLE (table8), track, 1, 2, 1, 2,
+ (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
+ (GtkAttachOptions) (0), 0, 0);
+ gtk_editable_set_editable (GTK_EDITABLE (track), FALSE);
+ gtk_entry_set_invisible_char (GTK_ENTRY (track), 8226);
+
+ hbox28 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox28);
+ gtk_box_pack_start (GTK_BOX (vbox13), hbox28, TRUE, TRUE, 0);
+
+ label36 = gtk_label_new ("Comment:");
+ gtk_widget_show (label36);
+ gtk_box_pack_start (GTK_BOX (hbox28), label36, FALSE, FALSE, 0);
+ gtk_misc_set_alignment (GTK_MISC (label36), 0, 0.5);
+
+ scrolledwindow4 = gtk_scrolled_window_new (NULL, NULL);
+ gtk_widget_show (scrolledwindow4);
+ gtk_box_pack_start (GTK_BOX (hbox28), scrolledwindow4, TRUE, TRUE, 0);
+ gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolledwindow4), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
+ gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (scrolledwindow4), GTK_SHADOW_IN);
+
+ comment = gtk_text_view_new ();
+ gtk_widget_show (comment);
+ gtk_container_add (GTK_CONTAINER (scrolledwindow4), comment);
+ gtk_text_view_set_editable (GTK_TEXT_VIEW (comment), FALSE);
+
+ g_signal_connect ((gpointer) trackproperties, "key_press_event",
+ G_CALLBACK (on_trackproperties_key_press_event),
+ NULL);
+ g_signal_connect ((gpointer) trackproperties, "delete_event",
+ G_CALLBACK (on_trackproperties_delete_event),
+ NULL);
+
+ /* Store pointers to all widgets, for use by lookup_widget(). */
+ GLADE_HOOKUP_OBJECT_NO_REF (trackproperties, trackproperties, "trackproperties");
+ GLADE_HOOKUP_OBJECT (trackproperties, vbox13, "vbox13");
+ GLADE_HOOKUP_OBJECT (trackproperties, hbox23, "hbox23");
+ GLADE_HOOKUP_OBJECT (trackproperties, label27, "label27");
+ GLADE_HOOKUP_OBJECT (trackproperties, location, "location");
+ GLADE_HOOKUP_OBJECT (trackproperties, hbox24, "hbox24");
+ GLADE_HOOKUP_OBJECT (trackproperties, label28, "label28");
+ GLADE_HOOKUP_OBJECT (trackproperties, title, "title");
+ GLADE_HOOKUP_OBJECT (trackproperties, hbox25, "hbox25");
+ GLADE_HOOKUP_OBJECT (trackproperties, label29, "label29");
+ GLADE_HOOKUP_OBJECT (trackproperties, artist, "artist");
+ GLADE_HOOKUP_OBJECT (trackproperties, hbox26, "hbox26");
+ GLADE_HOOKUP_OBJECT (trackproperties, label30, "label30");
+ GLADE_HOOKUP_OBJECT (trackproperties, album, "album");
+ GLADE_HOOKUP_OBJECT (trackproperties, hbox27, "hbox27");
+ GLADE_HOOKUP_OBJECT (trackproperties, label35, "label35");
+ GLADE_HOOKUP_OBJECT (trackproperties, genre, "genre");
+ GLADE_HOOKUP_OBJECT (trackproperties, table8, "table8");
+ GLADE_HOOKUP_OBJECT (trackproperties, label31, "label31");
+ GLADE_HOOKUP_OBJECT (trackproperties, label33, "label33");
+ GLADE_HOOKUP_OBJECT (trackproperties, year, "year");
+ GLADE_HOOKUP_OBJECT (trackproperties, track, "track");
+ GLADE_HOOKUP_OBJECT (trackproperties, hbox28, "hbox28");
+ GLADE_HOOKUP_OBJECT (trackproperties, label36, "label36");
+ GLADE_HOOKUP_OBJECT (trackproperties, scrolledwindow4, "scrolledwindow4");
+ GLADE_HOOKUP_OBJECT (trackproperties, comment, "comment");
+
+ return trackproperties;
+}
+
+GtkWidget*
+create_editcolumndlg (void)
+{
+ GtkWidget *editcolumndlg;
+ GtkWidget *dialog_vbox1;
+ GtkWidget *vbox14;
+ GtkWidget *hbox29;
+ GtkWidget *label26;
+ GtkWidget *title;
+ GtkWidget *hbox30;
+ GtkWidget *label37;
+ GtkWidget *id;
+ GtkWidget *hbox31;
+ GtkWidget *fmtlabel;
+ GtkWidget *format;
+ GtkWidget *hbox32;
+ GtkWidget *label38;
+ GtkWidget *align;
+ GtkWidget *label25;
+ GtkWidget *dialog_action_area1;
+ GtkWidget *cancelbutton1;
+ GtkWidget *okbutton1;
+
+ editcolumndlg = gtk_dialog_new ();
+ gtk_container_set_border_width (GTK_CONTAINER (editcolumndlg), 12);
+ gtk_window_set_title (GTK_WINDOW (editcolumndlg), "dialog1");
+ gtk_window_set_modal (GTK_WINDOW (editcolumndlg), TRUE);
+ gtk_window_set_type_hint (GTK_WINDOW (editcolumndlg), GDK_WINDOW_TYPE_HINT_DIALOG);
+
+ dialog_vbox1 = GTK_DIALOG (editcolumndlg)->vbox;
+ gtk_widget_show (dialog_vbox1);
+
+ vbox14 = gtk_vbox_new (FALSE, 8);
+ gtk_widget_show (vbox14);
+ gtk_box_pack_start (GTK_BOX (dialog_vbox1), vbox14, TRUE, TRUE, 0);
+
+ hbox29 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox29);
+ gtk_box_pack_start (GTK_BOX (vbox14), hbox29, FALSE, FALSE, 0);
+
+ label26 = gtk_label_new ("Title:");
+ gtk_widget_show (label26);
+ gtk_box_pack_start (GTK_BOX (hbox29), label26, FALSE, FALSE, 0);
+ gtk_misc_set_alignment (GTK_MISC (label26), 0, 0.5);
+
+ title = gtk_entry_new ();
+ gtk_widget_show (title);
+ gtk_box_pack_start (GTK_BOX (hbox29), title, TRUE, TRUE, 0);
+ gtk_entry_set_text (GTK_ENTRY (title), "Enter new column title here");
+ gtk_entry_set_invisible_char (GTK_ENTRY (title), 9679);
+ gtk_entry_set_activates_default (GTK_ENTRY (title), TRUE);
+
+ hbox30 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox30);
+ gtk_box_pack_start (GTK_BOX (vbox14), hbox30, FALSE, FALSE, 0);
+
+ label37 = gtk_label_new ("Type:");
+ gtk_widget_show (label37);
+ gtk_box_pack_start (GTK_BOX (hbox30), label37, FALSE, FALSE, 0);
+ gtk_misc_set_alignment (GTK_MISC (label37), 0, 0.5);
+
+ id = gtk_combo_box_new_text ();
+ gtk_widget_show (id);
+ gtk_box_pack_start (GTK_BOX (hbox30), id, TRUE, TRUE, 0);
+ gtk_combo_box_append_text (GTK_COMBO_BOX (id), "File number");
+ gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Playing");
+ gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Artist - Album");
+ gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Artist");
+ gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Album");
+ gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Title");
+ gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Length");
+ gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Track");
+ gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Custom");
+
+ hbox31 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox31);
+ gtk_box_pack_start (GTK_BOX (vbox14), hbox31, FALSE, FALSE, 0);
+
+ fmtlabel = gtk_label_new ("Format:");
+ gtk_widget_show (fmtlabel);
+ gtk_box_pack_start (GTK_BOX (hbox31), fmtlabel, FALSE, FALSE, 0);
+ gtk_misc_set_alignment (GTK_MISC (fmtlabel), 0, 0.5);
+
+ format = gtk_entry_new ();
+ gtk_widget_show (format);
+ gtk_box_pack_start (GTK_BOX (hbox31), format, TRUE, TRUE, 0);
+ gtk_entry_set_invisible_char (GTK_ENTRY (format), 9679);
+ gtk_entry_set_activates_default (GTK_ENTRY (format), TRUE);
+
+ hbox32 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox32);
+ gtk_box_pack_start (GTK_BOX (vbox14), hbox32, FALSE, FALSE, 0);
+
+ label38 = gtk_label_new ("Alignment:");
+ gtk_widget_show (label38);
+ gtk_box_pack_start (GTK_BOX (hbox32), label38, FALSE, FALSE, 0);
+ gtk_misc_set_alignment (GTK_MISC (label38), 0, 0.5);
+
+ align = gtk_combo_box_new_text ();
+ gtk_widget_show (align);
+ gtk_box_pack_start (GTK_BOX (hbox32), align, TRUE, TRUE, 0);
+ gtk_combo_box_append_text (GTK_COMBO_BOX (align), "Left");
+ gtk_combo_box_append_text (GTK_COMBO_BOX (align), "Right");
+
+ label25 = gtk_label_new ("Format conversions (start with %):\n [a]rtist, [t]itle, al[b]um, track[n]umber,\n [l]ength, [y]ear, [g]enre, [c]omment,\n copy[r]ight, [f]ilename\nExample: %a - %t [%l]");
+ gtk_widget_show (label25);
+ gtk_box_pack_start (GTK_BOX (vbox14), label25, TRUE, TRUE, 0);
+ GTK_WIDGET_SET_FLAGS (label25, GTK_CAN_FOCUS);
+ gtk_label_set_use_markup (GTK_LABEL (label25), TRUE);
+ gtk_label_set_selectable (GTK_LABEL (label25), TRUE);
+ gtk_misc_set_alignment (GTK_MISC (label25), 0.1, 0.5);
+
+ dialog_action_area1 = GTK_DIALOG (editcolumndlg)->action_area;
+ gtk_widget_show (dialog_action_area1);
+ gtk_button_box_set_layout (GTK_BUTTON_BOX (dialog_action_area1), GTK_BUTTONBOX_END);
+
+ cancelbutton1 = gtk_button_new_with_mnemonic ("_Cancel");
+ gtk_widget_show (cancelbutton1);
+ gtk_dialog_add_action_widget (GTK_DIALOG (editcolumndlg), cancelbutton1, GTK_RESPONSE_CANCEL);
+ GTK_WIDGET_SET_FLAGS (cancelbutton1, GTK_CAN_DEFAULT);
+
+ okbutton1 = gtk_button_new_with_mnemonic ("_OK");
+ gtk_widget_show (okbutton1);
+ gtk_dialog_add_action_widget (GTK_DIALOG (editcolumndlg), okbutton1, GTK_RESPONSE_OK);
+ GTK_WIDGET_SET_FLAGS (okbutton1, GTK_CAN_DEFAULT);
+
+ g_signal_connect ((gpointer) id, "changed",
+ G_CALLBACK (on_column_id_changed),
+ NULL);
+
+ /* Store pointers to all widgets, for use by lookup_widget(). */
+ GLADE_HOOKUP_OBJECT_NO_REF (editcolumndlg, editcolumndlg, "editcolumndlg");
+ GLADE_HOOKUP_OBJECT_NO_REF (editcolumndlg, dialog_vbox1, "dialog_vbox1");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, vbox14, "vbox14");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, hbox29, "hbox29");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, label26, "label26");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, title, "title");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, hbox30, "hbox30");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, label37, "label37");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, id, "id");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, hbox31, "hbox31");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, fmtlabel, "fmtlabel");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, format, "format");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, hbox32, "hbox32");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, label38, "label38");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, align, "align");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, label25, "label25");
+ GLADE_HOOKUP_OBJECT_NO_REF (editcolumndlg, dialog_action_area1, "dialog_action_area1");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, cancelbutton1, "cancelbutton1");
+ GLADE_HOOKUP_OBJECT (editcolumndlg, okbutton1, "okbutton1");
+
+ return editcolumndlg;
+}
+
+GtkWidget*
create_prefwin (void)
{
GtkWidget *prefwin;
- GtkWidget *pref_vbox;
+ GtkWidget *dialog_vbox2;
GtkWidget *notebook2;
GtkWidget *vbox10;
GtkWidget *hbox11;
@@ -1315,29 +1785,22 @@ create_prefwin (void)
GtkWidget *hbox20;
GtkWidget *configure_plugin;
GtkWidget *label3;
- GtkWidget *hbox21;
- GtkWidget *filler;
- GtkWidget *pref_close;
- GtkWidget *alignment1;
- GtkWidget *hbox22;
- GtkWidget *image321;
- GtkWidget *label40;
-
- prefwin = gtk_window_new (GTK_WINDOW_TOPLEVEL);
- gtk_widget_set_size_request (prefwin, 642, 372);
+ GtkWidget *dialog_action_area2;
+ GtkWidget *closebutton1;
+
+ prefwin = gtk_dialog_new ();
+ gtk_widget_set_size_request (prefwin, 630, 400);
gtk_container_set_border_width (GTK_CONTAINER (prefwin), 12);
gtk_window_set_title (GTK_WINDOW (prefwin), "Preferences");
- gtk_window_set_modal (GTK_WINDOW (prefwin), TRUE);
- gtk_window_set_skip_taskbar_hint (GTK_WINDOW (prefwin), TRUE);
- gtk_window_set_skip_pager_hint (GTK_WINDOW (prefwin), TRUE);
+ gtk_window_set_default_size (GTK_WINDOW (prefwin), 630, 400);
+ gtk_window_set_type_hint (GTK_WINDOW (prefwin), GDK_WINDOW_TYPE_HINT_DIALOG);
- pref_vbox = gtk_vbox_new (FALSE, 8);
- gtk_widget_show (pref_vbox);
- gtk_container_add (GTK_CONTAINER (prefwin), pref_vbox);
+ dialog_vbox2 = GTK_DIALOG (prefwin)->vbox;
+ gtk_widget_show (dialog_vbox2);
notebook2 = gtk_notebook_new ();
gtk_widget_show (notebook2);
- gtk_box_pack_start (GTK_BOX (pref_vbox), notebook2, TRUE, TRUE, 0);
+ gtk_box_pack_start (GTK_BOX (dialog_vbox2), notebook2, TRUE, TRUE, 0);
vbox10 = gtk_vbox_new (FALSE, 8);
gtk_widget_show (vbox10);
@@ -1596,47 +2059,15 @@ create_prefwin (void)
gtk_widget_show (label3);
gtk_notebook_set_tab_label (GTK_NOTEBOOK (notebook2), gtk_notebook_get_nth_page (GTK_NOTEBOOK (notebook2), 4), label3);
- hbox21 = gtk_hbox_new (FALSE, 0);
- gtk_widget_show (hbox21);
- gtk_box_pack_start (GTK_BOX (pref_vbox), hbox21, FALSE, TRUE, 0);
-
- filler = gtk_label_new ("");
- gtk_widget_show (filler);
- gtk_box_pack_start (GTK_BOX (hbox21), filler, TRUE, TRUE, 0);
-
- pref_close = gtk_button_new ();
- gtk_widget_show (pref_close);
- gtk_box_pack_start (GTK_BOX (hbox21), pref_close, FALSE, FALSE, 0);
- gtk_widget_set_size_request (pref_close, 76, -1);
-
- alignment1 = gtk_alignment_new (0.5, 0.5, 0, 0);
- gtk_widget_show (alignment1);
- gtk_container_add (GTK_CONTAINER (pref_close), alignment1);
-
- hbox22 = gtk_hbox_new (FALSE, 2);
- gtk_widget_show (hbox22);
- gtk_container_add (GTK_CONTAINER (alignment1), hbox22);
+ dialog_action_area2 = GTK_DIALOG (prefwin)->action_area;
+ gtk_widget_show (dialog_action_area2);
+ gtk_button_box_set_layout (GTK_BUTTON_BOX (dialog_action_area2), GTK_BUTTONBOX_END);
- image321 = gtk_image_new_from_stock ("gtk-close", GTK_ICON_SIZE_BUTTON);
- gtk_widget_show (image321);
- gtk_box_pack_start (GTK_BOX (hbox22), image321, FALSE, FALSE, 0);
+ closebutton1 = gtk_button_new_from_stock ("gtk-close");
+ gtk_widget_show (closebutton1);
+ gtk_dialog_add_action_widget (GTK_DIALOG (prefwin), closebutton1, GTK_RESPONSE_CLOSE);
+ GTK_WIDGET_SET_FLAGS (closebutton1, GTK_CAN_DEFAULT);
- label40 = gtk_label_new_with_mnemonic ("Close");
- gtk_widget_show (label40);
- gtk_box_pack_start (GTK_BOX (hbox22), label40, FALSE, FALSE, 0);
-
- g_signal_connect ((gpointer) prefwin, "key_press_event",
- G_CALLBACK (on_prefwin_key_press_event),
- NULL);
- g_signal_connect ((gpointer) prefwin, "delete_event",
- G_CALLBACK (on_prefwin_delete_event),
- NULL);
- g_signal_connect ((gpointer) pref_output_plugin, "changed",
- G_CALLBACK (on_pref_output_plugin_changed),
- NULL);
- g_signal_connect ((gpointer) pref_soundcard, "changed",
- G_CALLBACK (on_pref_soundcard_changed),
- NULL);
g_signal_connect ((gpointer) pref_dynsamplerate, "clicked",
G_CALLBACK (on_pref_dynsamplerate_clicked),
NULL);
@@ -1670,13 +2101,10 @@ create_prefwin (void)
g_signal_connect ((gpointer) configure_plugin, "clicked",
G_CALLBACK (on_configure_plugin_clicked),
NULL);
- g_signal_connect ((gpointer) pref_close, "clicked",
- G_CALLBACK (on_pref_close_clicked),
- NULL);
/* Store pointers to all widgets, for use by lookup_widget(). */
GLADE_HOOKUP_OBJECT_NO_REF (prefwin, prefwin, "prefwin");
- GLADE_HOOKUP_OBJECT (prefwin, pref_vbox, "pref_vbox");
+ GLADE_HOOKUP_OBJECT_NO_REF (prefwin, dialog_vbox2, "dialog_vbox2");
GLADE_HOOKUP_OBJECT (prefwin, notebook2, "notebook2");
GLADE_HOOKUP_OBJECT (prefwin, vbox10, "vbox10");
GLADE_HOOKUP_OBJECT (prefwin, hbox11, "hbox11");
@@ -1730,470 +2158,9 @@ create_prefwin (void)
GLADE_HOOKUP_OBJECT (prefwin, hbox20, "hbox20");
GLADE_HOOKUP_OBJECT (prefwin, configure_plugin, "configure_plugin");
GLADE_HOOKUP_OBJECT (prefwin, label3, "label3");
- GLADE_HOOKUP_OBJECT (prefwin, hbox21, "hbox21");
- GLADE_HOOKUP_OBJECT (prefwin, filler, "filler");
- GLADE_HOOKUP_OBJECT (prefwin, pref_close, "pref_close");
- GLADE_HOOKUP_OBJECT (prefwin, alignment1, "alignment1");
- GLADE_HOOKUP_OBJECT (prefwin, hbox22, "hbox22");
- GLADE_HOOKUP_OBJECT (prefwin, image321, "image321");
- GLADE_HOOKUP_OBJECT (prefwin, label40, "label40");
+ GLADE_HOOKUP_OBJECT_NO_REF (prefwin, dialog_action_area2, "dialog_action_area2");
+ GLADE_HOOKUP_OBJECT (prefwin, closebutton1, "closebutton1");
return prefwin;
}
-GtkWidget*
-create_headermenu (void)
-{
- GtkWidget *headermenu;
- GtkWidget *add_column;
- GtkWidget *edit_column;
- GtkWidget *remove_column;
-
- headermenu = gtk_menu_new ();
-
- add_column = gtk_menu_item_new_with_mnemonic ("Add column");
- gtk_widget_show (add_column);
- gtk_container_add (GTK_CONTAINER (headermenu), add_column);
-
- edit_column = gtk_menu_item_new_with_mnemonic ("Edit column");
- gtk_widget_show (edit_column);
- gtk_container_add (GTK_CONTAINER (headermenu), edit_column);
-
- remove_column = gtk_menu_item_new_with_mnemonic ("Remove column");
- gtk_widget_show (remove_column);
- gtk_container_add (GTK_CONTAINER (headermenu), remove_column);
-
- g_signal_connect ((gpointer) add_column, "activate",
- G_CALLBACK (on_add_column_activate),
- NULL);
- g_signal_connect ((gpointer) edit_column, "activate",
- G_CALLBACK (on_edit_column_activate),
- NULL);
- g_signal_connect ((gpointer) remove_column, "activate",
- G_CALLBACK (on_remove_column_activate),
- NULL);
-
- /* Store pointers to all widgets, for use by lookup_widget(). */
- GLADE_HOOKUP_OBJECT_NO_REF (headermenu, headermenu, "headermenu");
- GLADE_HOOKUP_OBJECT (headermenu, add_column, "add_column");
- GLADE_HOOKUP_OBJECT (headermenu, edit_column, "edit_column");
- GLADE_HOOKUP_OBJECT (headermenu, remove_column, "remove_column");
-
- return headermenu;
-}
-
-GtkWidget*
-create_addlocation (void)
-{
- GtkWidget *addlocation;
- GtkWidget *vbox7;
- GtkWidget *addlocation_entry;
- GtkWidget *hbox8;
- GtkWidget *label21;
- GtkWidget *addlocation_ok;
-
- addlocation = gtk_window_new (GTK_WINDOW_TOPLEVEL);
- gtk_window_set_title (GTK_WINDOW (addlocation), "Add Location");
- gtk_window_set_modal (GTK_WINDOW (addlocation), TRUE);
- gtk_window_set_destroy_with_parent (GTK_WINDOW (addlocation), TRUE);
- gtk_window_set_skip_taskbar_hint (GTK_WINDOW (addlocation), TRUE);
- gtk_window_set_skip_pager_hint (GTK_WINDOW (addlocation), TRUE);
-
- vbox7 = gtk_vbox_new (FALSE, 0);
- gtk_widget_show (vbox7);
- gtk_container_add (GTK_CONTAINER (addlocation), vbox7);
- gtk_container_set_border_width (GTK_CONTAINER (vbox7), 4);
-
- addlocation_entry = gtk_entry_new ();
- gtk_widget_show (addlocation_entry);
- gtk_box_pack_start (GTK_BOX (vbox7), addlocation_entry, FALSE, FALSE, 0);
- gtk_widget_set_size_request (addlocation_entry, 346, -1);
- gtk_entry_set_invisible_char (GTK_ENTRY (addlocation_entry), 8226);
-
- hbox8 = gtk_hbox_new (FALSE, 0);
- gtk_widget_show (hbox8);
- gtk_box_pack_start (GTK_BOX (vbox7), hbox8, FALSE, TRUE, 2);
-
- label21 = gtk_label_new ("");
- gtk_widget_show (label21);
- gtk_box_pack_start (GTK_BOX (hbox8), label21, TRUE, FALSE, 0);
-
- addlocation_ok = gtk_button_new_with_mnemonic ("OK");
- gtk_widget_show (addlocation_ok);
- gtk_box_pack_start (GTK_BOX (hbox8), addlocation_ok, FALSE, FALSE, 0);
- gtk_widget_set_size_request (addlocation_ok, 83, -1);
- GTK_WIDGET_UNSET_FLAGS (addlocation_ok, GTK_CAN_FOCUS);
-
- g_signal_connect ((gpointer) addlocation, "key_press_event",
- G_CALLBACK (on_addlocation_key_press_event),
- NULL);
- g_signal_connect ((gpointer) addlocation_entry, "activate",
- G_CALLBACK (on_addlocation_entry_activate),
- NULL);
- g_signal_connect ((gpointer) addlocation_ok, "clicked",
- G_CALLBACK (on_addlocation_ok_clicked),
- NULL);
-
- /* Store pointers to all widgets, for use by lookup_widget(). */
- GLADE_HOOKUP_OBJECT_NO_REF (addlocation, addlocation, "addlocation");
- GLADE_HOOKUP_OBJECT (addlocation, vbox7, "vbox7");
- GLADE_HOOKUP_OBJECT (addlocation, addlocation_entry, "addlocation_entry");
- GLADE_HOOKUP_OBJECT (addlocation, hbox8, "hbox8");
- GLADE_HOOKUP_OBJECT (addlocation, label21, "label21");
- GLADE_HOOKUP_OBJECT (addlocation, addlocation_ok, "addlocation_ok");
-
- return addlocation;
-}
-
-GtkWidget*
-create_trackproperties (void)
-{
- GtkWidget *trackproperties;
- GtkWidget *table7;
- GtkWidget *label27;
- GtkWidget *location;
- GtkWidget *label28;
- GtkWidget *label29;
- GtkWidget *label30;
- GtkWidget *title;
- GtkWidget *artist;
- GtkWidget *album;
- GtkWidget *label35;
- GtkWidget *genre;
- GtkWidget *label36;
- GtkWidget *table8;
- GtkWidget *label31;
- GtkWidget *label33;
- GtkWidget *year;
- GtkWidget *track;
- GtkWidget *scrolledwindow4;
- GtkWidget *comment;
-
- trackproperties = gtk_window_new (GTK_WINDOW_TOPLEVEL);
- gtk_window_set_title (GTK_WINDOW (trackproperties), "Track Properties");
- gtk_window_set_destroy_with_parent (GTK_WINDOW (trackproperties), TRUE);
- gtk_window_set_skip_taskbar_hint (GTK_WINDOW (trackproperties), TRUE);
- gtk_window_set_skip_pager_hint (GTK_WINDOW (trackproperties), TRUE);
-
- table7 = gtk_table_new (7, 2, FALSE);
- gtk_widget_show (table7);
- gtk_container_add (GTK_CONTAINER (trackproperties), table7);
- gtk_container_set_border_width (GTK_CONTAINER (table7), 3);
- gtk_table_set_row_spacings (GTK_TABLE (table7), 4);
- gtk_table_set_col_spacings (GTK_TABLE (table7), 4);
-
- label27 = gtk_label_new ("Location");
- gtk_widget_show (label27);
- gtk_table_attach (GTK_TABLE (table7), label27, 0, 1, 0, 1,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_misc_set_alignment (GTK_MISC (label27), 0, 0.5);
-
- location = gtk_entry_new ();
- gtk_widget_show (location);
- gtk_table_attach (GTK_TABLE (table7), location, 1, 2, 0, 1,
- (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_editable_set_editable (GTK_EDITABLE (location), FALSE);
- gtk_entry_set_invisible_char (GTK_ENTRY (location), 8226);
-
- label28 = gtk_label_new ("Title");
- gtk_widget_show (label28);
- gtk_table_attach (GTK_TABLE (table7), label28, 0, 1, 1, 2,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_misc_set_alignment (GTK_MISC (label28), 0, 0.5);
-
- label29 = gtk_label_new ("Artist");
- gtk_widget_show (label29);
- gtk_table_attach (GTK_TABLE (table7), label29, 0, 1, 2, 3,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_misc_set_alignment (GTK_MISC (label29), 0, 0.5);
-
- label30 = gtk_label_new ("Album");
- gtk_widget_show (label30);
- gtk_table_attach (GTK_TABLE (table7), label30, 0, 1, 3, 4,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_misc_set_alignment (GTK_MISC (label30), 0, 0.5);
-
- title = gtk_entry_new ();
- gtk_widget_show (title);
- gtk_table_attach (GTK_TABLE (table7), title, 1, 2, 1, 2,
- (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_editable_set_editable (GTK_EDITABLE (title), FALSE);
- gtk_entry_set_invisible_char (GTK_ENTRY (title), 8226);
-
- artist = gtk_entry_new ();
- gtk_widget_show (artist);
- gtk_table_attach (GTK_TABLE (table7), artist, 1, 2, 2, 3,
- (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_editable_set_editable (GTK_EDITABLE (artist), FALSE);
- gtk_entry_set_invisible_char (GTK_ENTRY (artist), 8226);
-
- album = gtk_entry_new ();
- gtk_widget_show (album);
- gtk_table_attach (GTK_TABLE (table7), album, 1, 2, 3, 4,
- (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_editable_set_editable (GTK_EDITABLE (album), FALSE);
- gtk_entry_set_invisible_char (GTK_ENTRY (album), 8226);
-
- label35 = gtk_label_new ("Genre");
- gtk_widget_show (label35);
- gtk_table_attach (GTK_TABLE (table7), label35, 0, 1, 4, 5,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_misc_set_alignment (GTK_MISC (label35), 0, 0.5);
-
- genre = gtk_entry_new ();
- gtk_widget_show (genre);
- gtk_table_attach (GTK_TABLE (table7), genre, 1, 2, 4, 5,
- (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_editable_set_editable (GTK_EDITABLE (genre), FALSE);
- gtk_entry_set_invisible_char (GTK_ENTRY (genre), 8226);
-
- label36 = gtk_label_new ("Comment");
- gtk_widget_show (label36);
- gtk_table_attach (GTK_TABLE (table7), label36, 0, 1, 6, 7,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_misc_set_alignment (GTK_MISC (label36), 0, 0.5);
-
- table8 = gtk_table_new (2, 2, FALSE);
- gtk_widget_show (table8);
- gtk_table_attach (GTK_TABLE (table7), table8, 0, 2, 5, 6,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (GTK_FILL), 0, 0);
- gtk_table_set_col_spacings (GTK_TABLE (table8), 3);
-
- label31 = gtk_label_new ("Year");
- gtk_widget_show (label31);
- gtk_table_attach (GTK_TABLE (table8), label31, 0, 1, 0, 1,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_label_set_line_wrap (GTK_LABEL (label31), TRUE);
- gtk_misc_set_alignment (GTK_MISC (label31), 0, 0.5);
-
- label33 = gtk_label_new ("Track");
- gtk_widget_show (label33);
- gtk_table_attach (GTK_TABLE (table8), label33, 1, 2, 0, 1,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_label_set_use_markup (GTK_LABEL (label33), TRUE);
- gtk_misc_set_alignment (GTK_MISC (label33), 0, 0.5);
-
- year = gtk_entry_new ();
- gtk_widget_show (year);
- gtk_table_attach (GTK_TABLE (table8), year, 0, 1, 1, 2,
- (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_editable_set_editable (GTK_EDITABLE (year), FALSE);
- gtk_entry_set_invisible_char (GTK_ENTRY (year), 8226);
-
- track = gtk_entry_new ();
- gtk_widget_show (track);
- gtk_table_attach (GTK_TABLE (table8), track, 1, 2, 1, 2,
- (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_editable_set_editable (GTK_EDITABLE (track), FALSE);
- gtk_entry_set_invisible_char (GTK_ENTRY (track), 8226);
-
- scrolledwindow4 = gtk_scrolled_window_new (NULL, NULL);
- gtk_widget_show (scrolledwindow4);
- gtk_table_attach (GTK_TABLE (table7), scrolledwindow4, 1, 2, 6, 7,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (GTK_EXPAND | GTK_FILL), 0, 0);
- gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolledwindow4), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
- gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (scrolledwindow4), GTK_SHADOW_IN);
-
- comment = gtk_text_view_new ();
- gtk_widget_show (comment);
- gtk_container_add (GTK_CONTAINER (scrolledwindow4), comment);
- gtk_text_view_set_editable (GTK_TEXT_VIEW (comment), FALSE);
-
- g_signal_connect ((gpointer) trackproperties, "key_press_event",
- G_CALLBACK (on_trackproperties_key_press_event),
- NULL);
- g_signal_connect ((gpointer) trackproperties, "delete_event",
- G_CALLBACK (on_trackproperties_delete_event),
- NULL);
-
- /* Store pointers to all widgets, for use by lookup_widget(). */
- GLADE_HOOKUP_OBJECT_NO_REF (trackproperties, trackproperties, "trackproperties");
- GLADE_HOOKUP_OBJECT (trackproperties, table7, "table7");
- GLADE_HOOKUP_OBJECT (trackproperties, label27, "label27");
- GLADE_HOOKUP_OBJECT (trackproperties, location, "location");
- GLADE_HOOKUP_OBJECT (trackproperties, label28, "label28");
- GLADE_HOOKUP_OBJECT (trackproperties, label29, "label29");
- GLADE_HOOKUP_OBJECT (trackproperties, label30, "label30");
- GLADE_HOOKUP_OBJECT (trackproperties, title, "title");
- GLADE_HOOKUP_OBJECT (trackproperties, artist, "artist");
- GLADE_HOOKUP_OBJECT (trackproperties, album, "album");
- GLADE_HOOKUP_OBJECT (trackproperties, label35, "label35");
- GLADE_HOOKUP_OBJECT (trackproperties, genre, "genre");
- GLADE_HOOKUP_OBJECT (trackproperties, label36, "label36");
- GLADE_HOOKUP_OBJECT (trackproperties, table8, "table8");
- GLADE_HOOKUP_OBJECT (trackproperties, label31, "label31");
- GLADE_HOOKUP_OBJECT (trackproperties, label33, "label33");
- GLADE_HOOKUP_OBJECT (trackproperties, year, "year");
- GLADE_HOOKUP_OBJECT (trackproperties, track, "track");
- GLADE_HOOKUP_OBJECT (trackproperties, scrolledwindow4, "scrolledwindow4");
- GLADE_HOOKUP_OBJECT (trackproperties, comment, "comment");
-
- return trackproperties;
-}
-
-GtkWidget*
-create_editcolumndlg (void)
-{
- GtkWidget *editcolumndlg;
- GtkWidget *dialog_vbox1;
- GtkWidget *table9;
- GtkWidget *label26;
- GtkWidget *title;
- GtkWidget *label37;
- GtkWidget *id;
- GtkWidget *fmtlabel;
- GtkWidget *format;
- GtkWidget *label25;
- GtkWidget *label38;
- GtkWidget *align;
- GtkWidget *dialog_action_area1;
- GtkWidget *cancelbutton1;
- GtkWidget *okbutton1;
-
- editcolumndlg = gtk_dialog_new ();
- gtk_window_set_title (GTK_WINDOW (editcolumndlg), "dialog1");
- gtk_window_set_modal (GTK_WINDOW (editcolumndlg), TRUE);
- gtk_window_set_type_hint (GTK_WINDOW (editcolumndlg), GDK_WINDOW_TYPE_HINT_DIALOG);
-
- dialog_vbox1 = GTK_DIALOG (editcolumndlg)->vbox;
- gtk_widget_show (dialog_vbox1);
-
- table9 = gtk_table_new (5, 2, FALSE);
- gtk_widget_show (table9);
- gtk_box_pack_start (GTK_BOX (dialog_vbox1), table9, TRUE, TRUE, 0);
- gtk_container_set_border_width (GTK_CONTAINER (table9), 3);
- gtk_table_set_col_spacings (GTK_TABLE (table9), 3);
-
- label26 = gtk_label_new ("Title");
- gtk_widget_show (label26);
- gtk_table_attach (GTK_TABLE (table9), label26, 0, 1, 0, 1,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_misc_set_alignment (GTK_MISC (label26), 0, 0.5);
-
- title = gtk_entry_new ();
- gtk_widget_show (title);
- gtk_table_attach (GTK_TABLE (table9), title, 1, 2, 0, 1,
- (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_entry_set_text (GTK_ENTRY (title), "Enter new column title here");
- gtk_entry_set_invisible_char (GTK_ENTRY (title), 9679);
- gtk_entry_set_activates_default (GTK_ENTRY (title), TRUE);
-
- label37 = gtk_label_new ("Type");
- gtk_widget_show (label37);
- gtk_table_attach (GTK_TABLE (table9), label37, 0, 1, 1, 2,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_misc_set_alignment (GTK_MISC (label37), 0, 0.5);
-
- id = gtk_combo_box_new_text ();
- gtk_widget_show (id);
- gtk_table_attach (GTK_TABLE (table9), id, 1, 2, 1, 2,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (GTK_FILL), 0, 0);
- gtk_combo_box_append_text (GTK_COMBO_BOX (id), "File number");
- gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Playing");
- gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Artist - Album");
- gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Artist");
- gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Album");
- gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Title");
- gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Length");
- gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Track");
- gtk_combo_box_append_text (GTK_COMBO_BOX (id), "Custom");
-
- fmtlabel = gtk_label_new ("Format");
- gtk_widget_show (fmtlabel);
- gtk_table_attach (GTK_TABLE (table9), fmtlabel, 0, 1, 2, 3,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_misc_set_alignment (GTK_MISC (fmtlabel), 0, 0.5);
-
- format = gtk_entry_new ();
- gtk_widget_show (format);
- gtk_table_attach (GTK_TABLE (table9), format, 1, 2, 2, 3,
- (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_entry_set_invisible_char (GTK_ENTRY (format), 9679);
- gtk_entry_set_activates_default (GTK_ENTRY (format), TRUE);
-
- label25 = gtk_label_new ("Format conversions (start with %):\n [a]rtist, [t]itle, al[b]um, track[n]umber,\n [l]ength, [y]ear, [g]enre, [c]omment,\n copy[r]ight, [f]ilename\nExample: %a - %t [%l]");
- gtk_widget_show (label25);
- gtk_table_attach (GTK_TABLE (table9), label25, 0, 2, 4, 5,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- GTK_WIDGET_SET_FLAGS (label25, GTK_CAN_FOCUS);
- gtk_label_set_use_markup (GTK_LABEL (label25), TRUE);
- gtk_label_set_selectable (GTK_LABEL (label25), TRUE);
- gtk_misc_set_alignment (GTK_MISC (label25), 0.1, 0.5);
-
- label38 = gtk_label_new ("Alignment");
- gtk_widget_show (label38);
- gtk_table_attach (GTK_TABLE (table9), label38, 0, 1, 3, 4,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (0), 0, 0);
- gtk_misc_set_alignment (GTK_MISC (label38), 0, 0.5);
-
- align = gtk_combo_box_new_text ();
- gtk_widget_show (align);
- gtk_table_attach (GTK_TABLE (table9), align, 1, 2, 3, 4,
- (GtkAttachOptions) (GTK_FILL),
- (GtkAttachOptions) (GTK_FILL), 0, 0);
- gtk_combo_box_append_text (GTK_COMBO_BOX (align), "Left");
- gtk_combo_box_append_text (GTK_COMBO_BOX (align), "Right");
-
- dialog_action_area1 = GTK_DIALOG (editcolumndlg)->action_area;
- gtk_widget_show (dialog_action_area1);
- gtk_button_box_set_layout (GTK_BUTTON_BOX (dialog_action_area1), GTK_BUTTONBOX_END);
-
- cancelbutton1 = gtk_button_new_with_mnemonic ("_Cancel");
- gtk_widget_show (cancelbutton1);
- gtk_dialog_add_action_widget (GTK_DIALOG (editcolumndlg), cancelbutton1, GTK_RESPONSE_CANCEL);
- GTK_WIDGET_SET_FLAGS (cancelbutton1, GTK_CAN_DEFAULT);
-
- okbutton1 = gtk_button_new_with_mnemonic ("_OK");
- gtk_widget_show (okbutton1);
- gtk_dialog_add_action_widget (GTK_DIALOG (editcolumndlg), okbutton1, GTK_RESPONSE_OK);
- GTK_WIDGET_SET_FLAGS (okbutton1, GTK_CAN_DEFAULT);
-
- g_signal_connect ((gpointer) id, "changed",
- G_CALLBACK (on_column_id_changed),
- NULL);
-
- /* Store pointers to all widgets, for use by lookup_widget(). */
- GLADE_HOOKUP_OBJECT_NO_REF (editcolumndlg, editcolumndlg, "editcolumndlg");
- GLADE_HOOKUP_OBJECT_NO_REF (editcolumndlg, dialog_vbox1, "dialog_vbox1");
- GLADE_HOOKUP_OBJECT (editcolumndlg, table9, "table9");
- GLADE_HOOKUP_OBJECT (editcolumndlg, label26, "label26");
- GLADE_HOOKUP_OBJECT (editcolumndlg, title, "title");
- GLADE_HOOKUP_OBJECT (editcolumndlg, label37, "label37");
- GLADE_HOOKUP_OBJECT (editcolumndlg, id, "id");
- GLADE_HOOKUP_OBJECT (editcolumndlg, fmtlabel, "fmtlabel");
- GLADE_HOOKUP_OBJECT (editcolumndlg, format, "format");
- GLADE_HOOKUP_OBJECT (editcolumndlg, label25, "label25");
- GLADE_HOOKUP_OBJECT (editcolumndlg, label38, "label38");
- GLADE_HOOKUP_OBJECT (editcolumndlg, align, "align");
- GLADE_HOOKUP_OBJECT_NO_REF (editcolumndlg, dialog_action_area1, "dialog_action_area1");
- GLADE_HOOKUP_OBJECT (editcolumndlg, cancelbutton1, "cancelbutton1");
- GLADE_HOOKUP_OBJECT (editcolumndlg, okbutton1, "okbutton1");
-
- return editcolumndlg;
-}
-
diff --git a/plugins/gtkui/interface.h b/plugins/gtkui/interface.h
index 931f74bd..0cac3e09 100644
--- a/plugins/gtkui/interface.h
+++ b/plugins/gtkui/interface.h
@@ -7,8 +7,8 @@ GtkWidget* create_searchwin (void);
GtkWidget* create_traymenu (void);
GtkWidget* create_addprogress (void);
GtkWidget* create_helpwindow (void);
-GtkWidget* create_prefwin (void);
GtkWidget* create_headermenu (void);
GtkWidget* create_addlocation (void);
GtkWidget* create_trackproperties (void);
GtkWidget* create_editcolumndlg (void);
+GtkWidget* create_prefwin (void);
diff --git a/plugins/gtkui/pluginconf.c b/plugins/gtkui/pluginconf.c
new file mode 100644
index 00000000..cc96e71b
--- /dev/null
+++ b/plugins/gtkui/pluginconf.c
@@ -0,0 +1,242 @@
+/*
+ DeaDBeeF - ultimate music player for GNU/Linux systems with X11
+ Copyright (C) 2009-2010 Alexey Yakovenko <waker@users.sourceforge.net>
+
+ This program is free software; you can redistribute it and/or
+ modify it under the terms of the GNU General Public License
+ as published by the Free Software Foundation; either version 2
+ of the License, or (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+*/
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
+#include <string.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <gtk/gtk.h>
+#include <gdk/gdkkeysyms.h>
+#include "../../deadbeef.h"
+#include "gtkui.h"
+#include "parser.h"
+#include "support.h"
+
+#define trace(...) { fprintf (stderr, __VA_ARGS__); }
+//#define trace(fmt,...)
+
+extern GtkWidget *mainwin;
+
+void
+on_prop_browse_file (GtkButton *button, gpointer user_data) {
+ GtkWidget *dlg = gtk_file_chooser_dialog_new ("Open file...", GTK_WINDOW (mainwin), GTK_FILE_CHOOSER_ACTION_OPEN, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, GTK_STOCK_OPEN, GTK_RESPONSE_OK, NULL);
+
+ gtk_file_chooser_set_select_multiple (GTK_FILE_CHOOSER (dlg), FALSE);
+ // restore folder
+ gtk_file_chooser_set_current_folder_uri (GTK_FILE_CHOOSER (dlg), deadbeef->conf_get_str ("filechooser.lastdir", ""));
+ int response = gtk_dialog_run (GTK_DIALOG (dlg));
+ // store folder
+ gchar *folder = gtk_file_chooser_get_current_folder_uri (GTK_FILE_CHOOSER (dlg));
+ if (folder) {
+ deadbeef->conf_set_str ("filechooser.lastdir", folder);
+ g_free (folder);
+ deadbeef->sendmessage (M_CONFIGCHANGED, 0, 0, 0);
+ }
+ if (response == GTK_RESPONSE_OK) {
+ gchar *file = gtk_file_chooser_get_filename (GTK_FILE_CHOOSER (dlg));
+ gtk_widget_destroy (dlg);
+ if (file) {
+ GtkWidget *entry = GTK_WIDGET (user_data);
+ gtk_entry_set_text (GTK_ENTRY (entry), file);
+ g_free (file);
+ }
+ }
+ else {
+ gtk_widget_destroy (dlg);
+ }
+}
+
+static void apply_conf (GtkWidget *w, DB_plugin_t *p) {
+ // parse script
+ char token[MAX_TOKEN];
+ const char *script = p->configdialog;
+ parser_line = 1;
+ while (script = gettoken (script, token)) {
+ if (strcmp (token, "property")) {
+ fprintf (stderr, "invalid token while loading plugin %s config dialog: %s at line %d\n", p->name, token, parser_line);
+ break;
+ }
+ char labeltext[MAX_TOKEN];
+ script = gettoken_warn_eof (script, labeltext);
+ if (!script) {
+ break;
+ }
+ char type[MAX_TOKEN];
+ script = gettoken_warn_eof (script, type);
+ if (!script) {
+ break;
+ }
+ char key[MAX_TOKEN];
+ script = gettoken_warn_eof (script, key);
+ if (!script) {
+ break;
+ }
+ char def[MAX_TOKEN];
+ script = gettoken_warn_eof (script, def);
+ if (!script) {
+ break;
+ }
+ script = gettoken_warn_eof (script, token);
+ if (!script) {
+ break;
+ }
+ if (strcmp (token, ";")) {
+ fprintf (stderr, "expected `;' while loading plugin %s config dialog: %s at line %d\n", p->name, token, parser_line);
+ break;
+ }
+
+ // fetch data
+ GtkWidget *widget = lookup_widget (w, key);
+ if (widget) {
+ if (!strcmp (type, "entry") || !strcmp (type, "password") || !strcmp (type, "file")) {
+ deadbeef->conf_set_str (key, gtk_entry_get_text (GTK_ENTRY (widget)));
+ }
+ else if (!strcmp (type, "checkbox")) {
+ deadbeef->conf_set_int (key, gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget)));
+ }
+ }
+ }
+ deadbeef->sendmessage (M_CONFIGCHANGED, 0, 0, 0);
+}
+
+void
+plugin_configure (GtkWidget *parentwin, DB_plugin_t *p) {
+ // create window
+ char title[200];
+ snprintf (title, sizeof (title), "Setup %s", p->name);
+ GtkWidget *win = gtk_dialog_new_with_buttons (title, GTK_WINDOW (parentwin), GTK_DIALOG_MODAL, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, GTK_STOCK_OK, GTK_RESPONSE_OK, GTK_STOCK_APPLY, GTK_RESPONSE_APPLY, NULL);
+ gtk_window_set_type_hint (GTK_WINDOW (win), GDK_WINDOW_TYPE_HINT_DIALOG);
+ gtk_container_set_border_width (GTK_CONTAINER(win), 12);
+
+ gtk_window_set_title (GTK_WINDOW (win), title);
+ gtk_window_set_modal (GTK_WINDOW (win), TRUE);
+ gtk_window_set_transient_for (GTK_WINDOW (win), GTK_WINDOW (parentwin));
+ GtkWidget *vbox;
+ vbox = GTK_DIALOG (win)->vbox;
+ gtk_box_set_spacing (GTK_BOX (vbox), 8);
+ GtkWidget *action_area = GTK_DIALOG (win)->action_area;
+ gtk_widget_show (action_area);
+ gtk_button_box_set_layout (GTK_BUTTON_BOX (action_area), GTK_BUTTONBOX_END);
+
+
+ // parse script
+ char token[MAX_TOKEN];
+ const char *script = p->configdialog;
+ parser_line = 1;
+ while (script = gettoken (script, token)) {
+ if (strcmp (token, "property")) {
+ fprintf (stderr, "invalid token while loading plugin %s config dialog: %s at line %d\n", p->name, token, parser_line);
+ break;
+ }
+ char labeltext[MAX_TOKEN];
+ script = gettoken_warn_eof (script, labeltext);
+ if (!script) {
+ break;
+ }
+ char type[MAX_TOKEN];
+ script = gettoken_warn_eof (script, type);
+ if (!script) {
+ break;
+ }
+ char key[MAX_TOKEN];
+ script = gettoken_warn_eof (script, key);
+ if (!script) {
+ break;
+ }
+ char def[MAX_TOKEN];
+ script = gettoken_warn_eof (script, def);
+ if (!script) {
+ break;
+ }
+ script = gettoken_warn_eof (script, token);
+ if (!script) {
+ break;
+ }
+ if (strcmp (token, ";")) {
+ fprintf (stderr, "expected `;' while loading plugin %s config dialog: %s at line %d\n", p->name, token, parser_line);
+ break;
+ }
+
+ // add to dialog
+ GtkWidget *label = NULL;
+ GtkWidget *prop = NULL;
+ GtkWidget *cont = NULL;
+ if (!strcmp (type, "entry") || !strcmp (type, "password")) {
+ label = gtk_label_new (labeltext);
+ gtk_widget_show (label);
+ prop = gtk_entry_new ();
+ gtk_widget_show (prop);
+ gtk_entry_set_text (GTK_ENTRY (prop), deadbeef->conf_get_str (key, def));
+ }
+ else if (!strcmp (type, "checkbox")) {
+ prop = gtk_check_button_new_with_label (labeltext);
+ gtk_widget_show (prop);
+ int val = deadbeef->conf_get_int (key, atoi (def));
+ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (prop), val);
+ }
+ else if (!strcmp (type, "file")) {
+ label = gtk_label_new (labeltext);
+ gtk_widget_show (label);
+ cont = gtk_hbox_new (FALSE, 2);
+ gtk_widget_show (cont);
+ prop = gtk_entry_new ();
+ gtk_widget_show (prop);
+ gtk_editable_set_editable (GTK_EDITABLE (prop), FALSE);
+ gtk_entry_set_text (GTK_ENTRY (prop), deadbeef->conf_get_str (key, def));
+ gtk_box_pack_start (GTK_BOX (cont), prop, TRUE, TRUE, 0);
+ GtkWidget *btn = gtk_button_new_with_label ("…");
+ gtk_widget_show (btn);
+ gtk_box_pack_start (GTK_BOX (cont), btn, FALSE, FALSE, 0);
+ g_signal_connect (G_OBJECT (btn), "clicked", G_CALLBACK (on_prop_browse_file), prop);
+ }
+ if (!strcmp (type, "password")) {
+ gtk_entry_set_visibility (GTK_ENTRY (prop), FALSE);
+ }
+ if (label && prop) {
+ GtkWidget *hbox = NULL;
+ hbox = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox);
+ gtk_box_pack_start (GTK_BOX (hbox), label, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (hbox), cont ? cont : prop, TRUE, TRUE, 0);
+ cont = hbox;
+ }
+ else {
+ cont = prop;
+ }
+ if (prop) {
+ g_object_set_data (G_OBJECT (win), key, prop);
+ }
+ if (cont) {
+ gtk_box_pack_start (GTK_BOX (vbox), cont, FALSE, FALSE, 0);
+ }
+ }
+
+ int response;
+ do {
+ response = gtk_dialog_run (GTK_DIALOG (win));
+ if (response == GTK_RESPONSE_APPLY || response == GTK_RESPONSE_OK) {
+ apply_conf (win, p);
+ }
+ } while (response == GTK_RESPONSE_APPLY);
+ gtk_widget_destroy (win);
+}
+
+
diff --git a/plugins/lastfm/lastfm.c b/plugins/lastfm/lastfm.c
index de86357e..28969561 100644
--- a/plugins/lastfm/lastfm.c
+++ b/plugins/lastfm/lastfm.c
@@ -665,7 +665,7 @@ lfm_thread (void *ctx) {
trace ("lfm sending nowplaying...\n");
// try to send nowplaying
- if (lfm_nowplaying[0]) {
+ if (lfm_nowplaying[0] && !deadbeef->conf_get_int ("lastfm.disable_np", 0)) {
lfm_send_nowplaying ();
}
lfm_send_submissions ();
@@ -801,6 +801,7 @@ static const char settings_dlg[] =
"property Username entry lastfm.login \"\";\n"
"property Password password lastfm.password \"\";"
"property \"Scrobble URL\" entry lastfm.scrobbler_url \""SCROBBLER_URL_LFM"\";"
+ "property \"Disable nowplaying\" checkbox lastfm.disable_np 0;"
;
// define plugin interface
diff --git a/plugins/vorbis/vorbis.c b/plugins/vorbis/vorbis.c
index b2b4e42c..96b25933 100644
--- a/plugins/vorbis/vorbis.c
+++ b/plugins/vorbis/vorbis.c
@@ -180,6 +180,11 @@ cvorbis_init (DB_playItem_t *it) {
plugin.free (_info);
return NULL;
}
+ if (info->vi->rate <= 0) {
+ trace ("vorbis: bad samplerate\n");
+ plugin.free (_info);
+ return NULL;
+ }
_info->plugin = &plugin;
_info->bps = 16;
//_info->dataSize = ov_pcm_total (&vorbis_file, -1) * vi->channels * 2;