summaryrefslogtreecommitdiff
path: root/app-emulation/vice/files/vice-3.10-mpg123-without-curl.patch
blob: 2173a05be019e11f7031b473565649f8a54be8c8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
https://bugs.gentoo.org/970962
https://sourceforge.net/p/vice-emu/code/45964/
--- a/src/arch/gtk3/widgets/settings_userport.c
+++ b/src/arch/gtk3/widgets/settings_userport.c
@@ -442,81 +441,0 @@
-#if defined(USE_MPG123) && defined (HAVE_GLOB_H)
-/* FunMP3 path selection widget */
-#include "mainlock.h"
-
-/** \brief  Callback for the directory-select dialog
- *
- * \param[in]   dialog      directory-select dialog
- * \param[in]   filename    filename (NULL if canceled)
- * \param[in]   entry       entry box for the filename
- */
-static void funmp3dir_browse_callback(GtkDialog *dialog, gchar *filename, gpointer entry)
-{
-    if (filename != NULL) {
-        vice_gtk3_resource_entry_set(GTK_WIDGET(entry), filename);
-        g_free(filename);
-    }
-    gtk_widget_destroy(GTK_WIDGET(dialog));
-}
-
-/** \brief  Handler for the 'clicked' event of the FunMP3 directory browse button
- *
- * \param[in]   button  FunMP3 directory browse button (unused)
- * \param[in]   entry   FunMP3 directory text entry
- */
-static void on_funmp3dir_browse_clicked(GtkWidget *button, gpointer entry)
-{
-    GtkWidget *dialog;
-
-    mainlock_assert_is_not_vice_thread();
-
-    dialog = vice_gtk3_select_directory_dialog("Select FunMP3 directory",
-                                               NULL,
-                                               TRUE,
-                                               NULL,
-                                               funmp3dir_browse_callback,
-                                               entry);
-    gtk_widget_show_all(dialog);
-}
-
-/** \brief  Create FunMP3 path selection entry widget
- *
- */
-static GtkWidget *create_funmp3dir_entry_widget(void)
-{
-    GtkWidget *entry;
-    entry = vice_gtk3_resource_entry_new("FunMP3Dir");
-    gtk_widget_set_tooltip_text(entry,
-                                "Select the host directory for MP3 files");
-    gtk_widget_set_hexpand(entry, TRUE);
-    return entry;
-}
-
-/** \brief  Create FunMP3 path selection widget
- *
- */
-static GtkWidget *create_funmp3dir_widget(void)
-{
-    GtkWidget *grid;
-    GtkWidget *entry;
-    GtkWidget *label;
-    GtkWidget *browse;
-
-    grid = vice_gtk3_grid_new_spaced(8, 0);
-
-    label  = gtk_label_new("FunMP3 directory");
-    gtk_widget_set_halign(label, GTK_ALIGN_START);
-    entry  = create_funmp3dir_entry_widget();
-    browse = gtk_button_new_with_label("Browse ...");
-    g_signal_connect_unlocked(browse,
-                              "clicked",
-                              G_CALLBACK(on_funmp3dir_browse_clicked),
-                              (gpointer)entry);
-    gtk_grid_attach(GTK_GRID(grid), label,  0, 1, 1, 1);
-    gtk_grid_attach(GTK_GRID(grid), entry,  1, 1, 1, 1);
-    gtk_grid_attach(GTK_GRID(grid), browse, 2, 1, 1, 1);
-
-    gtk_widget_show_all(grid);
-    return grid;
-}
-
-#endif  /* MPG123 && HAVE_GLOB_H */
@@ -684,0 +604,82 @@
+
+#if defined(USE_MPG123) && defined (HAVE_GLOB_H)
+/* FunMP3 path selection widget */
+#include "mainlock.h"
+
+/** \brief  Callback for the directory-select dialog
+ *
+ * \param[in]   dialog      directory-select dialog
+ * \param[in]   filename    filename (NULL if canceled)
+ * \param[in]   entry       entry box for the filename
+ */
+static void funmp3dir_browse_callback(GtkDialog *dialog, gchar *filename, gpointer entry)
+{
+    if (filename != NULL) {
+        vice_gtk3_resource_entry_set(GTK_WIDGET(entry), filename);
+        g_free(filename);
+    }
+    gtk_widget_destroy(GTK_WIDGET(dialog));
+}
+
+/** \brief  Handler for the 'clicked' event of the FunMP3 directory browse button
+ *
+ * \param[in]   button  FunMP3 directory browse button (unused)
+ * \param[in]   entry   FunMP3 directory text entry
+ */
+static void on_funmp3dir_browse_clicked(GtkWidget *button, gpointer entry)
+{
+    GtkWidget *dialog;
+
+    mainlock_assert_is_not_vice_thread();
+
+    dialog = vice_gtk3_select_directory_dialog("Select FunMP3 directory",
+                                               NULL,
+                                               TRUE,
+                                               NULL,
+                                               funmp3dir_browse_callback,
+                                               entry);
+    gtk_widget_show_all(dialog);
+}
+
+/** \brief  Create FunMP3 path selection entry widget
+ *
+ */
+static GtkWidget *create_funmp3dir_entry_widget(void)
+{
+    GtkWidget *entry;
+    entry = vice_gtk3_resource_entry_new("FunMP3Dir");
+    gtk_widget_set_tooltip_text(entry,
+                                "Select the host directory for MP3 files");
+    gtk_widget_set_hexpand(entry, TRUE);
+    return entry;
+}
+
+/** \brief  Create FunMP3 path selection widget
+ *
+ */
+static GtkWidget *create_funmp3dir_widget(void)
+{
+    GtkWidget *grid;
+    GtkWidget *entry;
+    GtkWidget *label;
+    GtkWidget *browse;
+
+    grid = vice_gtk3_grid_new_spaced(8, 0);
+
+    label  = gtk_label_new("FunMP3 directory");
+    gtk_widget_set_halign(label, GTK_ALIGN_START);
+    entry  = create_funmp3dir_entry_widget();
+    browse = gtk_button_new_with_label("Browse ...");
+    g_signal_connect_unlocked(browse,
+                              "clicked",
+                              G_CALLBACK(on_funmp3dir_browse_clicked),
+                              (gpointer)entry);
+    gtk_grid_attach(GTK_GRID(grid), label,  0, 1, 1, 1);
+    gtk_grid_attach(GTK_GRID(grid), entry,  1, 1, 1, 1);
+    gtk_grid_attach(GTK_GRID(grid), browse, 2, 1, 1, 1);
+
+    gtk_widget_show_all(grid);
+    return grid;
+}
+
+#endif  /* MPG123 && HAVE_GLOB_H */