Commit 4535a009 authored by Ole Aamot's avatar Ole Aamot

GNOME Gingerblue 0.1.7

parent e5d5766b
commit e5d5766bd2b22c946bc086d1bc9d774672ce40a6
Author: Ole Aamot <ole@gnome.org>
Date: Tue Jul 14 13:41:47 2020 +0200
Bump release version number
ChangeLog | 12 ++++++++++++
configure.ac | 2 +-
2 files changed, 13 insertions(+), 1 deletion(-)
commit a365fd5afe7d45a2811d4dacb747d4153c1a09f1
Author: Ole Aamot <ole@gnome.org>
Date: Tue Jul 14 13:40:24 2020 +0200
......
=============
Version 0.1.7
=============
Gingerblue
* src/gingerblue-main.c: Add cancellation of a recording loop
=============
Version 0.1.6
=============
......
......@@ -25,6 +25,7 @@ static void gb_assistant_button_toggled (GtkCheckButton *, GtkAssistant *);
static void gb_assistant_button_clicked (GtkButton *, GtkAssistant *);
static void gb_assistant_cancel (GtkAssistant *, gpointer);
static void gb_assistant_close (GtkAssistant *, gpointer);
static void gb_assistant_apply (GtkAssistant *, gpointer);
typedef struct {
GtkWidget *widget;
......@@ -42,6 +43,8 @@ GtkWidget *line_entry, *line_label;
GtkWidget *recording_entry, *recording_label;
GtkWidget *summary_entry, *summary_label;
GMainLoop *main_loops;
static void gb_assistant_entry_changed (GtkEditable *editable, GtkAssistant *assistant)
{
}
......@@ -56,7 +59,15 @@ static void gb_assistant_button_clicked (GtkButton *button, GtkAssistant *assist
static void gb_assistant_cancel (GtkAssistant *assistant, gpointer data)
{
gtk_main_quit();
if (!main_loops) {
g_error ("Quit more loops than there are.");
} else {
GMainLoop *loop = main_loops;
main_loops = g_slist_delete_link (main_loops, main_loops);
g_main_loop_quit (loop);
g_main_loop_unref (loop);
gtk_main_quit();
}
}
static void gb_assistant_close (GtkAssistant *assistant, gpointer data)
......@@ -75,6 +86,11 @@ static void gb_assistant_close (GtkAssistant *assistant, gpointer data)
fclose(fp);
}
static void gb_assistant_apply (GtkAssistant *assistant, gpointer data)
{
gst_element_send_event (data, gst_event_new_eos());
}
GtkAssistantPageFunc gb_assistant_cb (GtkAssistant *assistant, GDateTime *datestamp) {
/* gtk_assistant_next_page(assistant); */
}
......@@ -83,6 +99,7 @@ int main (int argc, char **argv) {
GDateTime *datestamp;
GingerblueData *data;
GingerblueChord *gingerblue_chord;
GstElement *src, *conv, *enc, *muxer, *sink, *pipeline;
GstPlayer *player;
GtkWidget *introduction;
GtkWidget *entry, *label, *button, *progress, *hbox;
......@@ -171,9 +188,11 @@ int main (int argc, char **argv) {
/* G_CALLBACK (gb_assistant_entry_changed), */
/* (gpointer) introduction); */
g_signal_connect (G_OBJECT (introduction), "cancel",
G_CALLBACK (gb_assistant_cancel), NULL);
G_CALLBACK (gb_assistant_cancel), main_loops);
g_signal_connect (G_OBJECT (introduction), "close",
G_CALLBACK (gb_assistant_close), NULL);
G_CALLBACK (gb_assistant_close), main_loops);
g_signal_connect (G_OBJECT (introduction), "apply",
G_CALLBACK (gb_assistant_apply), pipeline);
/* musicianpage = gtk_entry_new (); */
/* real_time = g_get_real_time(); */
/* gtk_assistant_insert_page (introduction, */
......@@ -231,8 +250,7 @@ int main (int argc, char **argv) {
main_window = gingerblue_main_loop (data);
gtk_widget_show_all (main_window);
*/
gst_init (&argc, &argv);
GstElement *src, *conv, *enc, *muxer, *sink, *pipeline;
gst_init(&argc, &argv);
gst_init(NULL, NULL);
pipeline = gst_pipeline_new ("record_pipe");
......@@ -250,11 +268,11 @@ int main (int argc, char **argv) {
gst_element_set_state (pipeline, GST_STATE_PLAYING);
GMainLoop *loop = g_main_loop_new (NULL, TRUE);
g_main_loop_run (loop);
main_loops = g_main_loop_new (NULL, TRUE);
g_main_loop_run (main_loops);
gst_element_set_state (pipeline, GST_STATE_NULL);
g_main_loop_unref (loop);
g_main_loop_unref (main_loops);
gst_object_unref (GST_OBJECT (pipeline));
/* player = play_new ("http://stream.radionorwegian.com/56.ogg", gingerblue_data->volume); */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment