diff options
author | Thomas White <taw@bitwiz.me.uk> | 2019-04-03 00:03:02 +0200 |
---|---|---|
committer | Thomas White <taw@bitwiz.me.uk> | 2019-04-03 00:03:02 +0200 |
commit | 65b623afe376e0331e106f00f487b755d555b7d1 (patch) | |
tree | ac74d02c668b8fc51d8ab5918c98616c26249af0 /libstorycode/narrative.c | |
parent | 50f6327a047673818e9b121ae9128b54c92cb90f (diff) |
Stylesheet saving skeleton
Diffstat (limited to 'libstorycode/narrative.c')
-rw-r--r-- | libstorycode/narrative.c | 22 |
1 files changed, 1 insertions, 21 deletions
diff --git a/libstorycode/narrative.c b/libstorycode/narrative.c index 287e181..d8af742 100644 --- a/libstorycode/narrative.c +++ b/libstorycode/narrative.c @@ -115,26 +115,6 @@ Narrative *narrative_load(GFile *file) } -static int write_narrative(GOutputStream *fh, Narrative *n) -{ - int i; - - for ( i=0; i<n->n_items; i++ ) { - - gssize r; - GError *error = NULL; - char *a = "Hello"; - - r = g_output_stream_write(fh, a, strlen(a), NULL, &error); - if ( r == -1 ) { - fprintf(stderr, "Write failed: %s\n", error->message); - return 1; - } - } - return 0; -} - - int narrative_save(Narrative *n, GFile *file) { GFileOutputStream *fh; @@ -151,7 +131,7 @@ int narrative_save(Narrative *n, GFile *file) fprintf(stderr, _("Open failed: %s\n"), error->message); return 1; } - r = write_narrative(G_OUTPUT_STREAM(fh), n); + r = storycode_write_presentation(n, G_OUTPUT_STREAM(fh)); if ( r ) { fprintf(stderr, _("Couldn't save presentation\n")); } |