diff options
author | bertrand <Bertrand.Guiheneuf@aful.org> | 2000-02-17 23:19:04 +0800 |
---|---|---|
committer | Bertrand Guiheneuf <bertrand@src.gnome.org> | 2000-02-17 23:19:04 +0800 |
commit | b39cda14b7678b925a6e3e645b60fb9858fdfaf6 (patch) | |
tree | dec02fd77a7f312b4cd4ea8d63abb90fdfa4cd14 /camel/camel-seekable-substream.c | |
parent | cf16aa4fb112337616d20f4f2f9c2512cbe5e82f (diff) | |
download | gsoc2013-evolution-b39cda14b7678b925a6e3e645b60fb9858fdfaf6.tar.gz gsoc2013-evolution-b39cda14b7678b925a6e3e645b60fb9858fdfaf6.tar.zst gsoc2013-evolution-b39cda14b7678b925a6e3e645b60fb9858fdfaf6.zip |
revamped so that it uses the output stream of the data wrapper
2000-02-17 bertrand <Bertrand.Guiheneuf@aful.org>
* camel/camel-formatter.c (handle_text_plain):
revamped so that it uses the output stream
of the data wrapper
(handle_text_html): ditto.
* camel/camel-simple-data-wrapper.h:
* camel/camel-simple-data-wrapper.c (camel_simple_data_wrapper_new):
use (void) instead of ().
(_get_output_stream): simple implementation.
A lot of small fixes so that the new parser scheme
works properly. Simple implementation of the stream
though.
Changed vette-formatter files so that they work with the
new scheme.
The new parser is now in a usable state. Still needs some work but the
infrastructure is here. /me is happy.
svn path=/trunk/; revision=1822
Diffstat (limited to 'camel/camel-seekable-substream.c')
-rw-r--r-- | camel/camel-seekable-substream.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/camel/camel-seekable-substream.c b/camel/camel-seekable-substream.c index 6d59d8994c..2b4b7d2917 100644 --- a/camel/camel-seekable-substream.c +++ b/camel/camel-seekable-substream.c @@ -143,12 +143,14 @@ static void _finalize (GtkObject *object) { CamelSeekableStream *seekable_stream; + CamelSeekableSubstream *seekable_substream; CAMEL_LOG_FULL_DEBUG ("Entering CamelSeekableSubstream::finalize\n"); seekable_stream = CAMEL_SEEKABLE_STREAM (object); + seekable_substream = CAMEL_SEEKABLE_SUBSTREAM (object); - if (seekable_stream->parent_stream) - gtk_object_unref (seekable_stream->parent_stream); + if (seekable_substream->parent_stream) + gtk_object_unref (GTK_OBJECT (seekable_substream->parent_stream)); GTK_OBJECT_CLASS (parent_class)->finalize (object); CAMEL_LOG_FULL_DEBUG ("Leaving CamelSeekableSubstream::finalize\n"); @@ -195,7 +197,7 @@ _init_with_seekable_stream_and_bounds (CamelSeekableSubstream *seekable_substre /* store the parent stream */ seekable_substream->parent_stream = parent_stream; - gtk_object_ref (parent_stream); + gtk_object_ref (GTK_OBJECT (parent_stream)); /* set the bound of the substream */ _set_bounds (seekable_substream, inf_bound, sup_bound); @@ -446,11 +448,13 @@ _seek (CamelSeekableStream *stream, gint offset, CamelStreamSeekPolicy policy) default: return -1; } + if (!seek_done) { if (real_offset > 0) { seekable_stream->cur_pos = MIN (real_offset, substream_len); } else seekable_stream->cur_pos = 0; + printf ("** set in substream %p, offset=%d\n", stream, real_offset); } |