Commit Graph

157 Commits

Author SHA1 Message Date
9663037f6c More work:
- Fixed some Camel API naming issues.
- Moved the message composer stuff to the `composer' directory.

svn path=/trunk/; revision=1395
1999-11-17 15:35:43 +00:00
ca7044930f Added streaming capability to CamelDataWrapper. This makes it possible, for
example, to build multipart messages out of files that are on disk without
loading them in memory.

svn path=/trunk/; revision=1394
1999-11-17 14:39:25 +00:00
b681ec2b9a Here is my initial Evolution work: message composition widget and some
installation fixes for Camel.

svn path=/trunk/; revision=1369
1999-11-05 23:06:09 +00:00
b2d3159593 missing files
svn path=/trunk/; revision=1329
1999-10-13 21:18:21 +00:00
bf9f54f961 A lot of changes. The thread proxy mechanism
is now functional. The signal proxy needs to be tested
though. The thread proxy folder is being implemented.
A rough summary :

1999-10-13  bertrand <Bertrand.Guiheneuf@aful.org>

	* camel/camel-folder.c (camel_folder_close): the
	folder->close method is now asynchronous.

	* camel/camel-folder-pt-proxy.c (_folder_open_cb):
	(_open):
	(_folder_open_cb):
	(_open):
	open/close method implemented in the thread proxy
	folder. More to come.

	* camel/camel-exception.c (camel_exception_xfer):
	new utility func.

	* camel/camel-marshal-utils.c: some new marshallers

	* camel/camel-folder-pt-proxy.c: Some explanations
	on the thread proxy system.

1999-10-11  bertrand <Bertrand.Guiheneuf@aful.org>

	* camel/camel-marshal-utils.c:
	camel/camel-marshal-utils.h:
	Handles operation marshalling.

	* camel/camel-thread-proxy.c:
	camel/camel-thread-proxy.h:
	new files. Generic proxy system.

	* camel/camel-folder-pt-proxy.c
	moved all proxy related code in dedicated files.

	(camel_folder_pt_proxy_init):
	removed proxy initialisation code
	(_finalize):
	removed proxy finalization code


	* camel/camel-exception.c
	(camel_exception_new):
	(camel_exception_set):
	(camel_exception_free):
	New funcs.

svn path=/trunk/; revision=1328
1999-10-13 21:16:55 +00:00
f1d9513767 weekly commit
svn path=/trunk/; revision=1322
1999-10-08 19:21:51 +00:00
6ed1a40852 Added corba-like exception system to CamelFolder. The exception system is
* Added corba-like exception system to CamelFolder.
The exception system is not finished but I wanted
the async and event implementation to get this right
from the beginning.

svn path=/trunk/; revision=1256
1999-09-23 19:26:54 +00:00
a8ccf54013 Check pthreads.
1999-09-21  bertrand  <Bertrand.Guiheneuf@aful.org>

	* configure.in:
	Check pthreads.

	* camel/Makefile.am:
	camel-folder-pt-proxy.c is only compiled
	when pthreads are available.

svn path=/trunk/; revision=1247
1999-09-21 20:40:27 +00:00
ed7fc1eaa2 More work on UID list in Mh provider.
1999-09-08  bertrand  <Bertrand.Guiheneuf@aful.org>

	* tests/ui-tests/store_listing.c (close_all):
	close all open folders and stores. (necessary
	for UID list saving ).

	* camel/providers/MH/mh-uid.c (mh_generate_uid_list):
	fix: store UID list in CamelMHFolder object.

	* camel/providers/MH/camel-mh-folder.c (_open):
	read or create UID list.
	(_close): save UID list.

svn path=/trunk/; revision=1192
1999-09-07 23:08:03 +00:00
66c1dd5fa4 changed names to follow camel style.
1999-09-06  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/md5-utils.h:
	* camel/md5-utils.c:
	changed names to follow camel style.

`

svn path=/trunk/; revision=1184
1999-09-06 10:08:37 +00:00
e716a2ed8b re-enabled old CPU/Mem consumming method. Use ful for pop3 for instance.
1999-09-05  bertrand  <Bertrand.Guiheneuf@aful.org>

	* tests/ui-tests/store_listing.c (show_folder_messages):
	re-enabled old CPU/Mem consumming
	method. Use ful for pop3 for instance.

svn path=/trunk/; revision=1179
1999-09-05 16:25:18 +00:00
4e4eb45bf6 use folder summary instead of opening all messages.
1999-09-05  bertrand  <Bertrand.Guiheneuf@aful.org>

	* tests/ui-tests/store_listing.c (show_folder_messages):
	use folder summary instead of opening all messages.

	* camel/providers/MH/camel-mh-folder.c (_create_summary):
	basic and highly non-efficient summary implementation.
	Should be seen as a proof of concept only.
	subfolder summary still has to be implemented.

	* camel/providers/maildir/camel-maildir-folder.c (_init_with_store):
	hasn't summary for the moment.
	* camel/providers/maildir/camel-maildir-folder.c
	cosmetic changes.

svn path=/trunk/; revision=1178
1999-09-05 16:15:12 +00:00
d938232d3c Address update
svn path=/trunk/; revision=1147
1999-08-29 22:13:34 +00:00
68a9dad22b text parameter declared const
1999-08-28  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/camel-mime-part.c (camel_mime_part_set_text):
	text parameter declared const

	* camel/camel-mime-part-utils.c (camel_mime_part_store_stream_in_buffer):
	actually test correctly nb_bytes_read_chunk is >0

	* camel/gstring-util.c:
	* camel/gmime-content-field.c:
	* camel/providers/MH/camel-mh-folder.c:
	* camel/camel-stream-fs.c:
	include string.h

	* camel/camel-stream-mem.c (_write): return
	the numver of written bytes.

	* camel/camel-stream-buffered-fs.c (_eos):
	return sthg

	* camel/camel-stream.c (default_camel_seek):
	return something.

* Started to work on new recipient code.
* fixed various leaks.

svn path=/trunk/; revision=1146
1999-08-29 15:57:47 +00:00
e826255bf1 contruct the content from the buffer before calling CamelMedium
1999-08-26  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/camel-mime-part.c (_get_content_object):
	contruct the content from the buffer before calling
	CamelMedium implementation.
	(_construct_from_stream): Do not construct the content
	by default, just store the content bytes in
	a temporary buffer. Content will be constructed only
	at caller request (when calling CamelMedium::get_content_object)
	Providers with better access to the messages (mbox/MH ...)
	will have to provider lighter implementation, that is
	shall not read content at all unless the caller asks
	for it (again with get_content).

	* camel/camel-mime-part-utils.c: new file, groups
	mime-part related utils. Meant to be used by providers
	subclassing MimeMessage.
	(camel_mime_part_construct_headers_from_stream):
	(camel_mime_part_construct_content_from_stream):
	no more useless temporary hash table.

	* camel/camel-mime-part.c (_construct_from_stream): calls
	mime-part-utils functions now.

	* camel/gmime-utils.c (_store_header_pair_from_string):
	do not use hash table to store header, use an array instead.

svn path=/trunk/; revision=1145
1999-08-26 15:29:40 +00:00
a76dccf18b now descend from CamelMedium.
1999-08-25  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/camel-mime-part.c: now descend from CamelMedium.

	* tests/test1.c (main): all headers must be strdup'ed
	(main): unref created objects

svn path=/trunk/; revision=1143
1999-08-25 20:42:59 +00:00
b42d3101ab La tout n'est qu'ordre et beaute,
Luxe, calme et voluptee.

svn path=/trunk/; revision=1142
1999-08-25 18:28:39 +00:00
08752e1b53 return the number of bytes read. How can this have ever worked ?
1999-08-17  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/camel-stream.c (camel_stream_read):
	return the number of bytes read.
	How can this have ever worked ?
	(camel_stream_flush): don't return anything.

	* camel/gmime-utils.c (get_header_table_from_stream):
	mem leak fixed.

+ various other mem leaks.

svn path=/trunk/; revision=1120
1999-08-17 17:44:00 +00:00
8efa5bea54 Now has a popup menu on mailbox tree to allow easier tests. Implemented
1999-08-16  bertrand  <Bertrand.Guiheneuf@aful.org>

	* tests/ui-tests/store_listing.c:
	Now has a popup menu on mailbox tree to allow
	easier tests. Implemented the copy stuff.
	Works well for the MH provider :)))

	* camel/providers/MH/camel-mh-folder.c (_copy_message_to):
	Test MH provider fast copy implemented.

svn path=/trunk/; revision=1119
1999-08-16 15:08:16 +00:00
fb5218e353 moved the active list readjustment code here. Much saner, providers won't
1999-08-15  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/camel-folder.c (camel_folder_expunge):
	moved the active list readjustment code here.
	Much saner, providers won't have to worry about
	that.

	* camel/providers/MH/camel-mh-folder.c (_expunge):
	no more active list readjustment stuff.

	* camel/camel-folder.h: the expunge virtual no more
	returns a list of expunged messages. Now providers
	only have to set the expunge flag on the expunged
	messages.

	* camel/camel-folder.c (camel_folder_get_message):
	moved the caching code here. Finally, I don't want
	providers to crash the libs with a bad message cache
	implementation.
	(_close): do not call the CamelFolder virtual expunge
	method directly, use camel_folder_expunge() instead.
	(camel_folder_expunge): added the want_list param.
	The client can decide if it wants the expunged message
	list or not. If yes, it'll have to unref the messages
	itself.

svn path=/trunk/; revision=1117
1999-08-15 20:40:11 +00:00
e579dc553c Implemented deletion/expunge mechanism.
1999-08-14  bertrand  <Bertrand.Guiheneuf@aful.org>

	* tests/ui-tests/store_listing.c (delete_selected_messages):
	(expunge_selected_folders):
	Implemented deletion/expunge mechanism.

	* camel/camel-folder.c (_get_message):
	Added some debug info.

	* camel/providers/MH/camel-mh-folder.c (_expunge):
	implemented and tested.

	* camel/camel-mime-message.c (_set_flag):
	changed the old braindead implementation.
	boolean are inserted in the flag hash
	table casted as gpointers.


	* camel/camel-mime-message.c: indentation fix

svn path=/trunk/; revision=1114
1999-08-14 18:50:46 +00:00
920be6e190 default implementation to be called first by providers methods. It looks
1999-08-13  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/camel-folder.c (_get_message): default implementation
	to be called first by providers methods. It looks in the
	folder message list (in memory) to see if the message has
	not already been retrieved, and in this case, returns
	the same CamelMimeMessage object

Caching messages in folder kworks. Providers will have to
do their job correctly.
Enough for today.

svn path=/trunk/; revision=1113
1999-08-13 18:28:56 +00:00
1c721c4abb remove stupid debug code. (add_mail_store): use camel_session_get_store
1999-08-12  bertrand  <Bertrand.Guiheneuf@aful.org>

	* tests/ui-tests/store_listing.c (show_folder_messages):
	remove stupid debug code.
	(add_mail_store): use camel_session_get_store instead
	of creating MH store directly.
	(main): load MH provider.

	* camel/camel-provider.c (camel_provider_register_as_module):
	register new provider.
	(camel_provider_get_for_protocol):
	Now, implementation is correct.

	* camel/camel-store.c (_finalize):
	* camel/camel-store.h (struct _CamelStore):
	further disabled url_name field use.
	URL will be generated dynamically.

Ben dam don dieu, vla t'y pas que ya tout le bourier qui marche !
(Autoload store/protocol from URL works)

svn path=/trunk/; revision=1108
1999-08-12 21:01:07 +00:00
a478ee7e9d new file. MH provider registration stuff.
1999-08-12  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/providers/MH/camel-mh-provider.c:
	new file. MH provider registration stuff.

	* camel/camel-provider.c (camel_provider_register_as_module):
	load a provider from a shared object (plugin).
	(camel_provider_register): register a provider
	"by hand". Used for statically defined providers.

	* tests/test7.c: new test.
	tests providers loading framework.

Providers modules loading Works !!! :))))

svn path=/trunk/; revision=1105
1999-08-11 22:34:09 +00:00
33ffe9aadc Message creation still consumes a lot of
memory (maybe 2000k) and I really don't
understand why. As soon as I get gtk working
on SunOS, purify should hopefully give me the answer.

1999-08-11  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/camel-service.c (_finalize):
	* camel/camel-stream-fs.c (_finalize):
	(_destroy): close file descriptor.
	* camel/camel-stream-mem.c (_finalize):
	* camel/camel-store.c (_finalize):
	* camel/camel-folder.c (_finalize):

svn path=/trunk/; revision=1104
1999-08-11 10:59:17 +00:00
9d041c9464 implemented destructors.
1999-08-11  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/camel-multipart.c (_finalize):
	* camel/camel-simple-data-wrapper.c (_finalize):
	* camel/camel-mime-part.c (_finalize):
	implemented destructors.

	* camel/gmime-content-field.c (gmime_content_field_ref):
	(gmime_content_field_unref):
	New reference mechanism for GMimeContentField objects.

	* camel/camel-data-wrapper.c (_finalize):
	Started implementing destructors.

	* camel/camel-mime-part.c (_construct_from_stream):
	* camel/gmime-content-field.c (gmime_content_field_write_to_stream):
	* camel/camel-multipart.c (_construct_from_stream):
	removed forgotten anarchic traces.


Go away memory leaks!

svn path=/trunk/; revision=1103
1999-08-10 23:22:44 +00:00
7d7f542330 Quick and (very) dirty hack to test Camel more easily.
1999-08-09  bertrand  <Bertrand.Guiheneuf@aful.org>

	* tests/ui-tests/store_listing.c:
	* tests/ui-tests/store_listing.glade:
	Quick and (very) dirty hack to test Camel more
	easily.

	* camel/camel-folder.c (camel_folder_append_message):
	new method.

svn path=/trunk/; revision=1102
1999-08-10 17:31:48 +00:00
6cb08f0bc1 some test files
svn path=/trunk/; revision=1101
1999-08-10 11:53:46 +00:00
4c3eb87749 fix. In MH, message number is not related to message position in folder.
1999-08-08  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/providers/MH/camel-mh-folder.c (_get_message):
	fix. In MH, message number is not related to
	message position in folder.

svn path=/trunk/; revision=1097
1999-08-08 20:02:02 +00:00
e5d44122b8 util func. (_get_message_count): implemented.
1999-08-08  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/providers/MH/camel-mh-folder.c (_is_a_message_file):
	util func.
	(_get_message_count): implemented.

svn path=/trunk/; revision=1096
1999-08-08 19:10:05 +00:00
85067acb32 encoder test.
1999-08-06  Robert Brady  <rwb197@ecs.soton.ac.uk>

	* tests/test6.c: encoder test.

	* camel/gmime-rfc2047.c: Fixed decoder bug : sequence
	?= is not always the terminator for an encoded-string.

svn path=/trunk/; revision=1091
1999-08-06 15:47:45 +00:00
9addfb95be added real test for MH folder provider. All tested things seem to work OK
1999-08-06  bertrand  <Bertrand.Guiheneuf@aful.org>

	* tests/test4.c (main): added real test for MH folder
	provider. All tested things seem to work OK :)

svn path=/trunk/; revision=1089
1999-08-06 14:41:10 +00:00
2bbd6e4180 test for RFC2047 decoder.
1998-08-06  Robert Brady  <rwb197@ecs.soton.ac.uk>

	* tests/test5.c: test for RFC2047 decoder.

	* camel/gmime-rfc2047.c: Improved RFC2047 decoder.

svn path=/trunk/; revision=1088
1999-08-06 14:25:09 +00:00
cf2f1c428f add debug information (_list_subfolders): test if first char in folder
1999-08-06  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/providers/MH/camel-mh-folder.c (_exists): add debug information
	(_list_subfolders): test if first char in folder name is not '.'
	before adding it to the folder list.

	* camel/camel-store.c (_init):
	disable session check temporarily
	(_get_separator):
	(_get_folder): new static func.
	Fixed several oddities in class definition.

	* camel/providers/MH/camel-mh-store.c (camel_mh_store_get_type):
	parent type is CAMEL_STORE_TYPE not CAMEL_FOLDER_TYPE

	* camel/camel-store.c:
	prent class is CamelServiceClass not GtkObjectClass

	* camel/url-util.c :
	cosmetic changes + use of const when possible.
	(find_host):
	fix a bug: when there is no host and no port don't skip the '/'
	all static find_* func are now named _func_*
	(g_url_free): destructor func.
	cache field has been disabled. Constructing the url string
	won't be too slow and will occur rarely enough that we
	do not need to add complexity to this code.

	* camel/providers/MH/camel-mh-store.c:
	parent class is CamelStorClass not GtkObjectClass

svn path=/trunk/; revision=1087
1999-08-06 14:17:27 +00:00
bb503a0bb5 forgotten file
svn path=/trunk/; revision=1084
1999-08-05 21:26:44 +00:00
7e8e444982 test mh provider.
1999-08-05  bertrand  <Bertrand.Guiheneuf@aful.org>

	* tests/test4.c:
	test mh provider.

	* camel/providers/MH/camel-mh-folder.c (_get_message):
	implemented

svn path=/trunk/; revision=1083
1999-08-05 21:25:53 +00:00
e77e777a57 Fixed copyright issue. ;)
svn path=/trunk/; revision=1078
1999-08-04 17:34:17 +00:00
382308f44a There is a probleme here. We can not allow mime part content-type field
* camel/camel-mime-part.c (_set_content_object):
	There is a probleme here. We can not allow mime part
	content-type field and content_object mime-type to be
	different. I thus chosed to set mime part object
	content field to be freed (if necessary) and set
	to be a pointer to content_object mime type
	field.
	(_construct_from_stream): set content_object mime type
	to be the same as mime_part's one. This is necessary
	because we use _set_content_type.

	This two things are a bit hackish ansd may need
	to be redesigned.

svn path=/trunk/; revision=1071
1999-08-03 13:16:35 +00:00
e9c6d8921c Multipart Mime message parsing works with plain text parts. Woohooo :))))
Making it work with other types is now just a matter of writing
the various data wrappers. And display them will just be a matter of writing
the good bonobo components.

1999-08-03  bertrand  <Bertrand.Guiheneuf@aful.org>

	* camel/camel-simple-data-wrapper.c (_construct_from_stream):
	more debugging output +  nb_bytes_read is now a signed int
	to avoid bug when eos is encountered.

	* camel/camel-mime-part.c (_construct_from_stream):
	sync to data_wrapper_repository function name changes.
	Use default "text/plain" type when conten-type field
	is not found. (following RFC 2046 spec).

	* camel/data-wrapper-repository.c (data_wrapper_repository_set_data_wrapper_type):
	(data_wrapper_repository_get_data_wrapper_type):
	change function name prefix (s/data_wrapper/data_wrapper_repository/)

	* camel/camel-multipart.c (_read_part):
	add `\n` at eol but not before boundary.

	* camel/gmime-utils.c (get_header_table_from_stream):
	correct implementation of end of stream detection.

svn path=/trunk/; revision=1070
1999-08-03 10:19:39 +00:00
3d7a8fdeac Adding missing files
svn path=/trunk/; revision=1053
1999-08-01 13:42:43 +00:00
cac0ba57e6 merge a lot of work. Rough ChangeLog will follow
svn path=/trunk/; revision=1052
1999-08-01 13:38:28 +00:00
1659afa3d3 now use CamelDataWrapper::contruct_form_stream to test message parsing
1999-06-28  bertrand  <Bertrand.Guiheneuf@inria.fr>

	* tests/test2.c (main): now use
	CamelDataWrapper::contruct_form_stream to test
	message parsing

	* camel/camel-data-wrapper.c:
	* camel/camel-data-wrapper.h:
	construct_from_stream no longer has maximimum size arg.

	* camel/camel-mime-part.c (_construct_from_stream): new.
	Construct the mime_part from a stream.

svn path=/trunk/; revision=1003
1999-06-28 16:05:09 +00:00
4f689d0fb8 sync
svn path=/trunk/; revision=983
1999-06-21 16:46:58 +00:00
19a118096f Commit of all Netherlands changes.
All mime stuff uses streams now, and it still works.

Bertrand

svn path=/trunk/; revision=981
1999-06-18 20:32:18 +00:00
a29ed28dd0 Chut \!
svn path=/trunk/; revision=977
1999-06-12 15:05:33 +00:00
1c1106598f use new stream code instead of raw file * stuff.
1999-05-31  bertrand  <Bertrand.Guiheneuf@inria.fr>

	* tests/test2.c (main):
	use new stream code instead of raw file * stuff.

	* camel/gmime-utils.c (get_header_table_from_stream):
	new func. Will replace get_header_table_from_file and will
	be used to parse headers from files as well as from
	memory buffers.

	* camel/camel-stream-fs.c:
	CamelStream Subclass. File system based
	stream.

svn path=/trunk/; revision=961
1999-05-30 21:56:11 +00:00
b3cdb41a12 new class. Represents an abstract stream object.
1999-05-30  bertrand  <Bertrand.Guiheneuf@inria.fr>

 	* camel/camel-stream.h: new class. Represents an
	abstract stream object.

svn path=/trunk/; revision=960
1999-05-30 20:02:42 +00:00
d32ba2a70a sync
svn path=/trunk/; revision=959
1999-05-30 14:02:36 +00:00
1d01c8dad1 remove leading and trailing spaces in recipient addresses.
* camel/camel-mime-message.c (_set_recipient_list_from_string):
	remove leading and trailing spaces in recipient addresses.

	* camel/gmime-utils.c (_store_header_pair_from_gstring):
	remove leading and trailing spaces from header values.

	* camel/gstring-util.c (g_string_trim): new
	func: remove leading or trailng chars from
	a specified char set.
	(g_string_split): allow trimming of substrings.

	* tests/test1.c (main): remove gtk_main call

svn path=/trunk/; revision=958
1999-05-30 11:40:05 +00:00
69912fc470 rewrite message obtained via parsing into a file. Actually, it works
* tests/test2.c (main): rewrite message obtained via
	parsing into a file. Actually, it works pretty well :))

	* camel/camel-mime-message.c (_set_recipient_list_from_string):
	create recipient list form a comma separated string.
	(_parse_header_pair): added recipient lists parsing.

	* camel/camel-mime-part.c (_parse_header_pair):
	new (protected) method. Parse a head pair and
	decides what to do with it.

	(_add_header): Call in _parse_header_pair

	* camel/camel-mime-message.c (_parse_header_pair):
	overload  header parsing MimePart mthod.

	* camel/gstring-util.c (g_string_split):
	new func: split a gstring into a GList of
	substring.

svn path=/trunk/; revision=950
1999-05-27 21:37:01 +00:00