Commit Graph

69 Commits

Author SHA1 Message Date
a878c6c70b Add #include to fix warning.
2003-05-17  Jeremy Katz  <katzj@redhat.com>

	* mail-offline-handler.c: Add #include to fix warning.

	* mail-mt.c (mail_msg_new): Use glib macros for pointer/int
	conversions.
	(mail_msg_free): Likewise.
	(mail_msg_cancel): Likewise.
	(mail_msg_wait): Likewise.
	(mail_msg_active): Likewise.
	* mail-session.c (main_register_timeout): Likewise.
	(register_timeout): Likewise.
	(main_remove_timeout): Likewise.
	(remove_timeout): Likewise.
	* message-list.c (ml_value_to_string): Likewise.

	* mail-identify.c: Add #include to fix warning.

	* mail-config.c (config_write_fonts): Don't pass extra arguments
	to g_warning.

	* mail-callbacks.c: Add #include to fix warning.

svn path=/trunk/; revision=21222
2003-05-16 18:52:14 +00:00
2cd51fe3ac Free the temporary error text.
2003-04-15  Hans Petter Jansson  <hpj@ximian.com>

	* mail-mt.c (mail_msg_check_error): Free the temporary error text.

svn path=/trunk/; revision=20850
2003-04-15 21:29:21 +00:00
0701addc19 Use g_signal_emit() rather than gtk_signal_emit(). (build_flat): Same
2003-02-10  Jeffrey Stedfast  <fejj@ximian.com>

	* message-list.c (build_tree): Use g_signal_emit() rather than
	gtk_signal_emit().
	(build_flat): Same here.

	* mail-signature-editor.c: #include <string.h>

	* mail-vfolder.c: #include <string.h>

	* mail-session.c: #include <string.h>

	* mail-search.c: #include <string.h>

	* mail-mt.c: #include <string.h>

	* mail-ops.c (save_part_save): Use strcasecmp() instead of
	g_strcasecmp().

	* mail-local.c: #include <string.h>
	(reconfigure_folder_reconfigured): Use a GtkDialog instead of
	gnome_error_dialog().

	* mail-format.c (find_preferred_alternative): Use g_ascii_strdown
	since g_strdown is deprecated.
	(fake_mime_part_from_data): Removed, no longer used it seems.
	(destroy_part): Also removed.

	* mail-display.c (make_popup_window): Replace call to
	gtk_window_set_polociy() with gtk_window_set_resizable() instead.
	(popup_size_allocate_cb): Use gtk_window_set_position() with
	GTK_WIN_POS_MOUSE instead of calculating the position to put it
	in.

svn path=/trunk/; revision=19878
2003-02-10 19:50:55 +00:00
cf4448abf4 hook onto destroy to remove dialogue from active table. (error_response):
2003-01-13  Not Zed  <NotZed@Ximian.com>

        * mail-mt.c (mail_msg_check_error): hook onto destroy to remove
        dialogue from active table.
        (error_response): Just destroy on any response, dont unref either.

svn path=/trunk/; revision=19423
2003-01-13 06:07:10 +00:00
f37b0a1ab7 ...And a whole bunch more build fixes.
2002-12-17  Jeffrey Stedfast  <fejj@ximian.com>

	...And a whole bunch more build fixes.

	* mail-vfolder.c (mail_vfolder_delete_uri): Don't use
	g_string_sprintfa() anymore since it is apparently deprecated.

	* mail-session.c (main_get_filter_driver): Don't use
	g_string_sprintfa() anymore since it is apparently deprecated.

	* mail-ops.c (build_from): Don't use g_string_sprintfa() anymore
	since it is apparently deprecated.

	* mail-callbacks.c (ask_confirm_for_unwanted_html_mail): Don't use
	g_string_sprintfa() anymore since it is apparently deprecated.

	* mail-autofilter.c: Don't use g_string_sprintfa() anymore since
	it is apparently deprecated.

	* folder-browser.c: Don't use g_string_sprintfa() anymore since it
	is apparently deprecated.

	* mail-search.c (mail_search_set_subject): Remove the unnecessary
	g_strdup()'age as well as fix a possible buffer overrun.

	* mail-local.c (mail_local_folder_construct): Use
	g_path_get_basename().

	* mail-config-druid.c (make_account): Don't use e_utf8_*
	functions.

svn path=/trunk/; revision=19152
2002-12-17 20:38:25 +00:00
bc9886539a Do not #include <libgnome/gnome-defs.h>. Likewise. Likewise. Likewise.
* mail-format.c: Do not #include <libgnome/gnome-defs.h>.
* mail-importer.c: Likewise.
* mail-mt.c: Likewise.
* mail-ops.c: Likewise.
* mail-search-dialogue.c: Likewise.
* mail-session.c: Likewise.
* mail-vfolder.c: Likewise.
* message-tag-followup.c: Likewise.
* main.c: Likewise, and <libgnomeui/gnome-init.h>.

* mail-callbacks.c: Do not #include <libgnome/gnome-paper.h>.
(do_mail_print): Remove the GnomePaper local variable.

svn path=/trunk/; revision=18739
2002-11-13 16:46:52 +00:00
f9804e1193 Commented out stuff that doesn't build yet. Also fixed idl build rule.
2002-11-13  Not Zed  <NotZed@Ximian.com>

	* Makefile.am: Commented out stuff that doesn't build yet.  Also
	fixed idl build rule.  importers still not built.

	* main.c (main): bonobactivationise.  remove push visual/colormap.
	(main): no longer activate activation, let bonobo_init do it.

	* mail-signature-editor.c (menu_help): Change help api.

	* mail-session.c (user_message_destroy_noreply): removed.  Not
	used?

	* mail-local.c (load_metainfo): xml root->children.

	* mail-format.c (g_string_append_len): Removed, it exists now.

2002-11-12  Not Zed  <NotZed@Ximian.com>

	* subscribe-dialog.c: gnome2ised, use gtkdialog.
	(subscribe_get_global_extras): use a weak ref rather than destroy signal.

	* message-tag-followup.c: gnome2ised.

	* message-tag-editor.c: gnome2ised & converted to gtkdialog.

	* message-list.c: gnome2ised.
	(message_list_finalise): From destroy method.  maybe should be
	destroy still.

	* message-browser.c: port to gnome2
	(message_browser_finalise): renamed from destroy method.

	* mail-stream-gtkhtml.c: removed redundant
	camel_class_get_global_classfuncs() call.

	* mail-signature-editor.c: gtkdialogised, & bonobo api changes.


	* mail-search-dialogue.c: gtkdialogised.

	* mail-folder-cache.c: cleaned up camel ref/hook casts.

	* mail-composer-prefs.c (mail_composer_prefs_get_type): convert to
	gtype.

	* mail-font-prefs.c (mail_font_prefs_destroy): from finalise.

	* mail-config.c: s/bonobo_config/e_config_listener/
	Added /apps/Evolution prefix to the evolution keys.
	Changed to use e_config_listener, etc.
	(mail_config_init): remove bonobo_config stuff.
	(mail_config_check_service): gtk dialogise.
	(check_response): from check_cancelled.

	* mail-config-druid.c (mail_config_druid_destroy): renamed from
	_finalize, turned into destroy handler.
	(construct): set type to toplevel, GTK_WINDOW_DIALOG no longer exists.

	* mail-config-factory.c (mail_config_register_factory): bonobo api
	changes.

	* mail-crypto.c (mail_crypto_get_pgp_cipher_context): cleaned up
	unref casts.

	* mail-display.c (write_data_to_file): gnome->gtkdialog.
	(on_link_clicked): use ascii_str*cmp on url.
	(save_part): g_path stuff.
	(launch_cb): gtk dialog.
	(pixmap_press): de-oafify.
	(pixbuf_for_mime_type): gnome-vfs api changes.
	(do_attachment_header): Change the pixmap to a gtkimage.
	(do_signature): "
	(pixbuf_gen_idle): "
	(do_attachment_header): ascii_str*cmp
	(do_attachment_header): gnome pixmap->gtkimage.
	(mail_display_destroy): protect against gtk mentalness.
	(html_button_press_event): ascii_str*cmp
	(drag_data_get_cb): added comment for translators of filename.

	* mail-format.c (component_supports): de-oafise.
	(is_anonymous): ascii_strncmp
	(attachment_header): remove utf8<>locale stuff, and gnomevfs api
	changes.
	(format_mime_part): fix g_strdown call.
	(write_field_row_begin): kill utf8->gtk stuff.
	(write_address): "
	(default_header_index): ascii_strcasecmp
	(handle_text_plain): "
	(handle_text_enriched): "
	(handle_multipart_encrypted): remove utf/gtk stuff.
	(handle_message_external_body): ascii_str*cmp

	* mail-identify.c (mail_identify_mime_part):
	(identify_by_magic): gnome vfs api changes.

	* mail-importer.c: Converted.

	* mail-local.c (load_metainfo): xml childs -> children.
	(mls_get_folder): g_strerror.
	(mls_delete_folder): g_strerror.
	(reconfigure_got_folder): Gnome->GtkDialog
	(reconfigure_response): from reconfigure_clicked.

	* mail-mt.c (mail_msg_check_error): gnome -> gtk dialog
	(error_response): renmae from error_gone.  destroy widget on any
	response.

	* mail-offline-handler.c (impl_finalise): renamed from
	impl_destroy since thats what it should be anyway.

	* mail-ops.c: removed utf8 widget conversion & camel_object_un/ref
	casts.

	* mail-preferences.c (mail_preferences_get_type): glib2'ised.

	* mail-search.c (mail_search_finalise): renmaed from destroy &
	properly chain.
	(mail_search_get_type): glib2 & make gtkdialog parent.
	(entry_run_search): run search when entry activated.  not sure if
	gtkdialog has anohter way to do this on an arbitrary widget.

	* mail-send-recv.c (dialogue_response): renamed from clicked.  Use
	gtkdialog.

	* mail-session.c (request_password_deleted): removed, redundant.
	(pass_response): rename from pass_got, changed for gtkdialog.
	(user_message_destroy): Removed, redundant.
	(user_message_response): Renamed from user_message_clicked.

2002-11-11  Not Zed  <NotZed@Ximian.com>

	* mail-stream-gtkhtml.c (mail_stream_gtkhtml_class_init): dont use
	get_global_classfuncs, just get the type

	* mail-tools.c: converted gnome2 api's.

	* mail-vfolder.c (vfolder_editor_response): clicked->response.
	(vfolder_editor_destroy): Removed.
	(vfolder_edit): gtk dialog api
	(edit_rule_response): clicked->response.
	(vfolder_edit_rule): gnomedialog->gtkdialog.
	(vfolder_gui_add_rule): "
	(new_rule_clicked): clicked->response

svn path=/trunk/; revision=18723
2002-11-12 14:59:35 +00:00
ce3ae88564 If we are not in interactive mode, don't display error dialogs.
2002-08-05  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-mt.c (mail_msg_check_error): If we are not in interactive
	mode, don't display error dialogs.

	* component-factory.c (interactive_cb): Updated to use the new
	function mail_session_set_interactive().
	(owner_unset_cb): Same here.

	* mail-session.c (mail_session_set_interactive): Renamed from
	mail_session_enable_interaction().
	(mail_session_get_interactive): New function to get the
	interactive state.

svn path=/trunk/; revision=17702
2002-08-05 21:20:59 +00:00
432ddb8b68 setup private data. (mail_display_destroy): cancel any outstanding
2002-07-29  Not Zed  <NotZed@Ximian.com>

        * mail-display.c (mail_display_init): setup private data.
        (mail_display_destroy): cancel any outstanding fetches, and free
        private data.
        (mail_display_set_message): Cancel any outstanding fetches.
        (fetch_cancelled):
        (fetch_next):
        (fetch_remote):
        (fetch_data):
        (fetch_free):
        (fetch_cancel):
        (fetch_done): Implement, used to use soup to download remote
        images.
        (load_http): Removed.
        (on_url_requested): When requesting a http* url, use the
        fetch_remote call above.

        * mail-display.h (struct _MailDisplay): Added priv(ate) member.

svn path=/trunk/; revision=17640
2002-07-30 14:20:06 +00:00
0
18e40f0e2d Added exception strings to some of the op logging.
2001-10-30    <NotZed@Ximian.com>

	* mail-mt.c: Added exception strings to some of the op logging.

	* mail-format.c (elide_quotes): Remove, uh, what was this for, its
	not used anywhere?  Also loops the instant it had a ", good one
	trow! :)
	(write_address): Remove name_arg/email_arg, these aren't used
	anywhere.

svn path=/trunk/; revision=14482
2001-10-30 21:31:45 +00:00
0
d244e01c6d If we have a cancellation setup, destroy it immediately, to save fd's.
2001-10-30    <NotZed@Ximian.com>

        * mail-mt.c (mail_msg_received): If we have a cancellation setup,
        destroy it immediately, to save fd's.
        (mail_msg_cancel): Check cancel != NULL.
        (mail_msg_free): Same.

svn path=/trunk/; revision=14470
2001-10-30 18:52:18 +00:00
5
cab9406217 So apparently the uicomp can just 'vanish' while we're using it. Joy. Take
2001-10-25    <NotZed@Ximian.com>

	* folder-browser-ui.c (fbui_sensitize_timeout): So apparently the
	uicomp can just 'vanish' while we're using it.  Joy.  Take care of
	that case here, fixes #13482.
	(fbui_sensitise_item): Check here too just for kicks.

	* mail-folder-cache.c (store_finalised): If we can't destroy our
	async event, then queue another one to do it.
	(store_finalised_finish): And handle it here, until we can, then
	free it.
	(mail_note_store): Queue an async event to get folderinfo, dont
	use mail_get_folderinfo.
	(update_folders_get): thread-async event to retrieve the
	folderinfo, and build it, then queues gui-async event to update
	the gui.
	(add_unmatched_info): Taken from mail-ops, adds unmatched if
	required.
	(add_vtrash_info): From mail-ops, add trash if required.
	(update_folders): Thread async event to update gui.
	(mail_note_store): Ref the store and storage when created.
	(update_1folder): Changed to assume we have info_lock, and store
	updates in an updates list.
	(setup_folder): Same.
	(folder_changed): Changed to call update_1folder directly.
	(real_folder_changed): Removed.
	(mail_note_folder): Changed to call update_1folder directly.
	(real_note_folder): Removed.
	(store_folder_subscribed): Call setup_folder directly.
	(real_folder_created): Removed.
	(real_flush_update): Function that actually does the updates in
	the gui thread.
	(mail_note_store): Go back to using mail_get_folderinfo.
	(update_folders): Fixed upf ro changed api's.
	(unset_folder_info): Changed to queue pending updates.
	(real_folder_deleted): Removed.
	(store_folder_unsubscribed): Do the removal work directly.
	(mail_note_store): Dont link to finalised event of store - we now
	ref it.
	(mail_note_store_remove): If we have any pending updates, clear
	them out.  Also cancel any pending folderinfo retrieve operations.
	(update_folders): Remove our update from the storeinfo list, if it
	still exists.
	(update_1folder): Make 'sent folder shows all counts' optional via
	an environmental variable EVOLUTION_COUNT_SENT for all those
	bloody whinging lusers out there.
	(mail_note_store_remove): Unref the storage when done.

	* mail-mt.c (mail_async_event_emit): If we're in main and have a
	gui task, set it to run via an idle function.
	(idle_async_event): Wrapper for calling do_async_event from idle
	function, and freeing the message when done.
	(idle_async_event): Call mail_msg_free not free on the finished
	message.

	* component-factory.c (mail_remove_storage): Destroy the storage
	async.
	(store_disconnect): This does the work.
	(free_storage): Un-note the store when we remove it, so the store
	noting code can unref things properly.
	(idle_quit): Return false when done, dont loop.

2001-10-24    <NotZed@Ximian.com>

	* component-factory.c (owner_set_cb): Setup an async_event
	handler.
	(idle_quit): Try to destroy the async_event, or keep dropping out
	if it can't (deadlock).

	* mail-mt.c (do_async_event): Set the threadid of the thread we're
	running in so we know its running/which thread its in.
	(mail_async_event_emit): Added new argument 'type' which is the
	type of thread to execute against, gui or another one.  Fixed all
	callers.
	(mail_async_event_destroy): Return -1 if this operation will fail
	(deadlock possibility).  If we're in the thread of the task
	we're going to wait for, then return a failure (since we will
	deadlock).
	(mail_async_event_emit): Chagned to use MailAsyncFunc type as the
	function type, which just takes 3 void args, change args to suit.

	* mail-folder-cache.c (mail_note_store): Record the pending update
	events in a pending list.  We should really be able to use an
	async event for this, but that doesn't return to the gui loop when
	done :-/
	(update_folders): Remove from pending update when done.

svn path=/trunk/; revision=14101
2001-10-25 21:21:33 +00:00
3
a0974e678a Removed, all functionality moved to mail-session.
2001-10-23    <NotZed@Ximian.com>

        * mail-mt.c (mail_user_message):
        (mail_get_password): Removed, all functionality moved to
        mail-session.

        * mail-config.c (mail_config_write_on_exit): Check
        threaded/preview hash is null before using it, its setup on demand
        so itmight nto be initialised here.

        * mail-session.c (request_password): Remove password_current
        stuff.
        (alert_user): Redont, similar to get_pass.  Do things as async as
        possible, and dont even wait for a response if we're not asking
        for the cancel button (this may or may not be right behaviour -
        need to check).  mail_user_message() code replaced from the stuff
        in mail-mt.c
        (MailSession): Added a lock field.
        (init): Setup lock.
        (finalise): fRee lock.
        (register_timeout): Redone.  We now allocate our own 'timeoutid's,
        and <> to the real things asynchronously.  Use async_event's so we
        can make sure we have no outstanding ones after shutdown.
        (mail_session_enable_interaction): If interaction has been
        disabled, and we have either a message-box open, or a password
        request open and/or any pending message boxes/passwords, blow 'em
        away.
        (main_register_timeout): If we have pending remove of this same
        timeout, dont do anything.
        (timeout_timeout): Properly honour the result, remove the timout
        if it returns false.

svn path=/trunk/; revision=13952
2001-10-23 20:42:57 +00:00
3
1651eba931 Added missing errno.h (mail_msg_new): Fix the logic a bit, dont try to
2001-10-23    <NotZed@Ximian.com>

        * mail-mt.c: Added missing errno.h
        (mail_msg_new): Fix the logic a bit, dont try to open the log file
        unless logging is actually requested.

svn path=/trunk/; revision=13944
2001-10-23 17:11:33 +00:00
41fb38eb09 If the fopen() fails (eg, because evolution-mail was started by oafd with
* mail-mt.c (mail_msg_new): If the fopen() fails (eg, because
	evolution-mail was started by oafd with PWD=/), don't try to use
	the NULL file handle.

svn path=/trunk/; revision=13943
2001-10-23 16:32:44 +00:00
3
343f36cffe Completely re-done. We now hae a completely async dialogue when requested
2001-10-23    <NotZed@Ximian.com>

        * mail-session.c (get_password): Completely re-done.  We now hae a
        completely async dialogue when requested from antoehr thread, and
        dont use gtk_main() if we can avoid it (which is normally the
        case).  This stuff is only partially finished, and will mena the
        removal of the same from mail-mt.c, and the mail_user_message()
        code will be moved here and changed to work in a similar way.

        * mail-callbacks.c (empty_trash): Dont try and connect to remote
        stores just to get the trash.  Also, always run empty trash async,
        and make sure we unref the trash.
        (empty_trash): Hmm, dont unref the trash, causes a problem on
        exit, i suspect something else is doing funky unrefs on it.

        * mail-tools.c (mail_tool_get_trash): Pass a 'connect' arg, tell
        it whether it should tryand connect or not to the parent service,
        if it isn't already connected.

        * component-factory.c (owner_unset_cb): Dont try wait_all here,
        could potentially deadlock.
        (idle_quit): Keep returning TRUE if we have outstanding
        processing.  Note that this may busy-wait during exit processign
        with busy tasks :(
        (idle_quit): Keep calling ourselves till we no longer get called
        (i.e. gtk_main really quits).

        * mail-mt.c (mail_msg_active): New function, returns TRUE if
        events are still active/outstanding.
        (do_op_status): @$@$#@@!#@!!  didn't unlock the mail_msg_lock if
        data->activity was NULL and we had no global_shell_client anymore!
        Also shortcut processing if this is going to be the case.
        (mail_msg_init): Setup a temporary other gui_port for redoing with
        new semantics password, user message and progress reporting.
        (mail_get_password): #ifdef'd out all this code temporarily, till
        it gets fully moved to mail-session.c

2001-10-22    <NotZed@Ximian.com>

        * component-factory.c (owner_set_cb): Dont call enable_interaction
        here.
        (interactive_cb): But here instead, let the shell tell us when its
        ok to go interactive.

svn path=/trunk/; revision=13933
2001-10-23 06:28:27 +00:00
d8ee10a7fc Don't free `clientid' as it's uninitialized.
* mail-mt.c (do_op_status): Don't free `clientid' as it's
uninitialized.

svn path=/trunk/; revision=13899
2001-10-22 22:27:53 +00:00
739e7cd1da #include "component-factory.h". (do_op_status): Pass the component ID
* mail-mt.c: #include "component-factory.h".
(do_op_status): Pass the component ID instead of the msg ID.

* component-factory.h (COMPONENT_ID): #define here instead of
`component-factory.c'.
(SUMMARY_FACTORY_ID): Likewise.

svn path=/trunk/; revision=13895
2001-10-22 21:16:10 +00:00
72edd88061 change va_copy to G_VA_COPY
svn path=/trunk/; revision=13753
2001-10-18 17:30:04 +00:00
40964e5ccc Use va_copy to make this compile on ppc again.
* mail-mt.c (mail_call_main): Use va_copy to make this compile on
	ppc again.

svn path=/trunk/; revision=13749
2001-10-18 17:00:37 +00:00
8c85ed61ba Added an async_event handler to store_info. (mail_note_store): Setup async
* mail-folder-cache.c: Added an async_event handler to store_info.
	(mail_note_store): Setup async event handler here.
	(store_finalised): Flush out async events here.
	(folder_changed): Use async event handler to emit event.
	(mail_note_folder): Chagned, do most of the work in the calling
	context, only do the corba stuff in main.
	(store_folder_subscribed): Use async event, and do more work locally.
	(store_folder_unsubscribed): Same.
	(store_folder_deleted): Call store_folder_unsubscribed if we have
	to do any work.
	(store_folder_created): Call store_folder_subscribed if we have to
	do any work.
	(store_folder_unsubscribed): Ref store while busy.
	(real_folder_deleted): And unref here.
	(store_folder_subscribed): Reg store while busy.
	(real_folder_created): Unref here.
	(mail_note_folder): Ref folder while busy.
	(real_note_folder): And unref here.
	(mail_note_folder): Hook onto folder_deleted event.
	(folder_deleted): Just mark this folder as no longer available.

	* mail-session.c (register_timeout): Use mail_call_main instead of
	proxy_event.
	(remove_timeout): Same here.

	* folder-browser.c (folder_changed): use the new mail_async_event
	stuff.
	(folder_changed_main): Remove old async event handling stuff.
	(FOLDER_BROWSER_LOCK/UNLOCK): Removed.
	(FolderBrowserPrivate): Removed too, sigh.

	* mail-mt.c (mail_async_event_new, mail_async_event_emit,
	mail_async_event_destroy): New functions to handle async events.
	(mail_proxy_event, mail_proxy_event_id): Removed old functions for
	async events.
	(do_call): Add suport for MAIL_CALL_p_pp.
	(mail_msg_free): Use mail_async_event instead of proxy_event.

	* message-list.c (message_changed): Promote the message_changed to
	a folder_changed and use main_folder_changed to process it.
	(main_message_changed): Remove.d
	(message_list_init): Setup async event handler.
	(message_list_destroy): Remove async handler.
	(folder_changed): Use async hanler to emit event in main loop.
	(message_changed): Same.

svn path=/trunk/; revision=13698
2001-10-16 19:13:31 +00:00
6
41802db263 New function to return the id of the currently executing proxied event.
2001-10-16    <NotZed@Ximian.com>

	* mail-mt.c (mail_proxy_event_id): New function to return the id
	of the currently executing proxied event.

	* folder-browser.h: Added private field.

	* folder-browser.c (folder_changed): Keep track of tasks
	outstanding in the tasks list, locked access.
	(FOLDER_BROWSER_LOCK, UNLOCK): Macros to lock the folder browser
	for poking about in diff threads.
	(folder_browser_finalise): Wait for any outstanding takss to
	finish before cleaning ourself up.
	(folder_browser_destroy): Move the seen_id handling to finalise,
	also add a loading_id handling code.
	(main_folder_changed): Remove our running task when done.

svn path=/trunk/; revision=13695
2001-10-16 17:34:59 +00:00
5
3ac3a15e3c Proxy get-password call to main thread. (forget_password): same for
2001-10-15    <NotZed@Ximian.com>

        * mail-session.c (get_password): Proxy get-password call to main
        thread.
        (forget_password): same for forget_password.
        (get_filter_driver): and same for get_filter_driver, since it uses
        gtk objects.

        * mail-mt.c (mail_call_main): new generic interface for calling
        stuff/proxying in the gui thread.

svn path=/trunk/; revision=13679
2001-10-15 18:55:18 +00:00
c0af9ae948 Fix a merge-conflict leftover.
2001-10-05  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-mt.c (pass_got): Fix a merge-conflict leftover.

svn path=/trunk/; revision=13474
2001-10-05 22:17:04 +00:00
f26378de36 Don't call mail_config_service_set_save_passwd if we didn't find a
* mail-mt.c (pass_got): Don't call
	mail_config_service_set_save_passwd if we didn't find a service.

svn path=/trunk/; revision=13231
2001-09-28 21:11:35 +00:00
03dcbdb743 Added mail_msg_cleanup() prototype.
2001-09-28  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-mt.h: Added mail_msg_cleanup() prototype.

svn path=/trunk/; revision=13219
2001-09-28 18:40:55 +00:00
905bc4ef20 Always make the Cancel button the last one.
* mail-mt.c (do_user_message): Always make the Cancel button the
last one.

svn path=/trunk/; revision=13207
2001-09-28 00:03:51 +00:00
115673976e Change the wording of the password dialog if we are getting a pgp
2001-09-26  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-mt.c (do_get_pass): Change the wording of the password
	dialog if we are getting a pgp passphrase so that users don't
	misinterpret it to mean saving the passphrase forever.

svn path=/trunk/; revision=13176
2001-09-26 23:45:35 +00:00
5
ba5b1b6be7 Deal with destroy vs finalise semantics. Only destroy widgets here.
2001-09-25    <NotZed@Ximian.com>

        * folder-browser.c (folder_browser_destroy): Deal with destroy vs
        finalise semantics.  Only destroy widgets here.
        (folder_browser_finalise): object finalise function, actually
        unref/free all other objects here.
        (folder_browser_class_init): Init the finalise hook.
        (got_folder): Check if message_list == NULL -> we've been
        destroyed before the thread got a chance to finish loading the
        folder.
        (folder_browser_is_drafts): Dont use a g_return_if_fail to return
        in what could be a valid state of the object.
        (folder_browser_is_sent): Likewise.
        (folder_browser_copy): Do nothing if message_list == NULL.

        * main.c (main): call  mail_msg_cleanup() before leaving threads.

        * component-factory.c (owner_unset_cb): Wait for all outstanding
        operations to finish before setting up to quit.
        (idle_quit): Wait for all outstanding ops to finish before
        cleanup.
        (unref_standard_folders): NULL out the standard folder before
        unreffing it.

        * mail-mt.c (mail_msg_wait_all): New function to wait for all
        outstanding thread operations.
        (mail_msg_cleanup): Destroy the io channels before we're
        finished.  Also wait for all outstanding threads first.  Made
        public.
        (mail_msg_init): Dont call mail_msg_cleanup atexit automatically.

svn path=/trunk/; revision=13129
2001-09-25 22:18:52 +00:00
d6cecfcef1 Only cache the password for the service if it has an entry in the account
2001-09-25  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-mt.c (pass_got): Only cache the password for the service if
	it has an entry in the account database. Fixes bug #10875.

svn path=/trunk/; revision=13111
2001-09-25 18:12:47 +00:00
3c632cd045 Always cache POP and IMAP passwords, even if the user didn't tell us to.
2001-09-23  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-mt.c (pass_got): Always cache POP and IMAP passwords, even
	if the user didn't tell us to. Fixes bug #10569.

svn path=/trunk/; revision=13089
2001-09-24 00:34:01 +00:00
1
cca23c1566 If we have an operation that failed before, dont show the dialogue for the
2001-09-21    <NotZed@Ximian.com>

	* mail-mt.c (mail_msg_check_error): If we have an operation that
	failed before, dont show the dialogue for the the new error.  Also
	use gtk_widget_show rather than invoking another main loop.  Fix
	for lazy people who like to leave their mailers running and go
	home.

svn path=/trunk/; revision=13075
2001-09-21 23:12:44 +00:00
0
412c2967bb Register vfolder sources here.
2001-09-20    <NotZed@Ximian.com>

        * mail-tools.c(mail_tool_uri_to_folder): Register vfolder sources here.

        * folder-browser.c (got_folder): Dont register vfolder sources
        here.

        * mail-ops.c (mail_get_folder): Add thread parameter.  Fix callers.

        * mail-vfolder.c (vfolder_setup): Use the 'slow' queue for setting
        up vfolders.

        * mail-mt.c (mail_msg_init): Limit the maximum number of threads
        on the 'new' thread to 10.
        (mail_msg_init): Create a new queue 'slow' for doing slow
        operations.

svn path=/trunk/; revision=13017
2001-09-20 21:01:53 +00:00
c3b248ff4b Make the title translatable, and also use the account name when possible.
2001-09-18  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-mt.c (do_get_pass): Make the title translatable, and also
	use the account name when possible. Sorta fixes bug #6277.

svn path=/trunk/; revision=12964
2001-09-19 00:16:34 +00:00
3e079da9b6 Pass a 'cache-me' argument to mail_get_password.
2001-09-18  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-session.c (get_password): Pass a 'cache-me' argument to
	mail_get_password.

	* mail-mt.c (pass_got): Make less confusing...
	(mail_get_password): Now takes an argument 'cache' that allows our
	caller to determine if the user wanted to cache his/her password
	or not.
	(pass_got): Set the cache option.

svn path=/trunk/; revision=12950
2001-09-18 20:14:38 +00:00
ac4f13b93e Allow the activity to be NULL if there isn't a global_shell_client so that
2001-08-19  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-mt.c (do_op_status): Allow the activity to be NULL if there
	isn't a global_shell_client so that we don't try and report status
	updates when the shell is destroyed.

	* mail-config.c (add_shortcut_entry): Return if there isn't a
	global_shell_client.

	* component-factory.c (owner_set_cb): set the global_shell_client
	here and connect to the destroy signal.

	* mail-vfolder.c (vfolder_create_storage): Use an extern global_shell_client.

svn path=/trunk/; revision=12242
2001-08-20 04:02:10 +00:00
c2e50e8804 Changed the title of this dialog to "Enter Password".
2001-07-31  Anna Marie Dirks <anna@ximian.com>
	* mail-mt.c (do_get_pass): Changed the title of this dialog
	to "Enter Password".

svn path=/trunk/; revision=11534
2001-07-31 20:53:46 +00:00
bf408fed06 We are not guarenteed to have a non-NULL service (ie. PGP) thus check for
2001-07-30  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-mt.c (do_get_pass): We are not guarenteed to have a
	non-NULL service (ie. PGP) thus check for it.
	(pass_got): And again here.
	(mail_get_password): And of course here too.

svn path=/trunk/; revision=11493
2001-07-30 22:16:49 +00:00
45701621c5 Don't need this anymore. (do_get_pass): Since we already have the entry
2001-07-27  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-mt.c (focus_on_entry): Don't need this anymore.
	(do_get_pass): Since we already have the entry widget, no need to
	do the nasty focus_on_entry hack.

svn path=/trunk/; revision=11453
2001-07-27 19:02:42 +00:00
4157d65284 Figure out whether we're getting the password for the source or the
2001-07-26  Peter Williams  <peterw@ximian.com>

	* mail-mt.c (do_get_pass): Figure out whether we're getting the password
	for the source or the transport, and get the toggle button accordingly.
	(pass_got): Same.

	* mail-config.c (mail_config_get_account_by_transport_url): New function.
	Cut + paste + search + replace of _by_source_url.

	* mail-config.h: Prototype here.

svn path=/trunk/; revision=11446
2001-07-27 15:36:42 +00:00
871a58ea8a Use magic to make the password remembering checkbutton come after the
2001-07-26  Peter Williams  <peterw@ximian.com>

	* mail-mt.c (do_get_pass): Use magic to make the password
	remembering checkbutton come after the entry, visually.

svn path=/trunk/; revision=11432
2001-07-26 19:47:05 +00:00
b0d5e599ce Don't make the key url:item if we have the url, just make it url. This
2001-07-25  Jeffrey Stedfast  <fejj@ximian.com>

	* mail-session.c (make_key): Don't make the key url:item if we
	have the url, just make it url. This fixes bug #5339.
	(mail_session_set_password): Removed.

svn path=/trunk/; revision=11411
2001-07-25 20:04:12 +00:00
56d33b7e47 Now take a CamelService parameter (as passed by Camel). Allows us to have
2001-07-25  Peter Williams  <peterw@ximian.com>

	* mail-mt.c (mail_get_password): Now take a CamelService parameter
	(as passed by Camel). Allows us to have a "remember password"
	checkbox that is set correctly and whose settings can be
	propagated back to the proper MailConfigService.
	(do_get_pass): Add a checkbutton allowing the user to change
	whether the password is remembered or not.
	(pass_got): Apply the setting of the "remember password"
	checkbutton (if not cancelled.)

	* mail-mt.h: Update the prototype here.

	* mail-config.c (mail_config_service_set_save_passwd): New function,
	pretty bland.

	* mail-config.h: Prototype our bland new function. (Get it? It's a pun!)

	* mail-session.c (get_password): Pass the service as well.

svn path=/trunk/; revision=11408
2001-07-25 19:05:08 +00:00
cb4926026f Go back to calling mail_msg_free here. (mail_msg_destroy): Remove the
2001-07-23  Not Zed  <NotZed@Ximian.com>

        * mail-mt.c (mail_msgport_replied): Go back to calling
        mail_msg_free here.
        (mail_msg_destroy): Remove the operation unregistration stuff.
        (mail_msg_received): And put it here, so we unregister as soon as
        the async part of the operation is complete.  I thought about this
        and we should be doing this anyway so we register/unregister
        always in the same thread, although the camel_operation api
        doesn't enforce it, this *is* what it expects.

        * message-list.c (regen_list_regen): re-add reporting to
        rebuilding the message list.  Basically fixes #4931

svn path=/trunk/; revision=11332
2001-07-24 01:36:11 +00:00
fcce65ec8a Fix DanW's fix. Pass the right arguments to mail_msg_destroy.
2001-07-20  Peter Williams  <peterw@ximian.com>

	* mail-mt.c (mail_msgport_replied): Fix DanW's fix. Pass the right
	arguments to mail_msg_destroy.

	* component-factory.c (component_fn): Don't populate the context
	menu; our only action didn't even work.
	(populate_folder_context_menu): Removed. ChangeFolderProperties
	needs a FolderBrowser which we don't have. It didn't even work
	before.

	* mail-local.c (mail_local_reconfigure_folder): Bring the creation
	of the hash table to the beginning to prevent warnings. Complain
	if the mailbox is non-local.

svn path=/trunk/; revision=11266
2001-07-20 19:15:04 +00:00
47b817166c Use mail_msg_destroy rather than mail_msg_free, so the cancellation
* mail-mt.c (mail_msgport_replied): Use mail_msg_destroy rather
	than mail_msg_free, so the cancellation operation gets
	unregistered and doesn't leak two file descriptors.

svn path=/trunk/; revision=11263
2001-07-20 18:00:44 +00:00
37695c74b7 remvoed register/start/end etc code.
2001-07-19  Not Zed  <NotZed@Ximian.com>

        * mail-local.c (reconfigure_folder_reconfigure): remvoed
        register/start/end etc code.

        * mail-ops.c (get_messages_desc): Add the count here.
        (get_messages_get): Remove the register/start code, its handled
        above us.
        (save_messages_desc): Added count.
        (save_messages_save): Removed register/start/end code.

        * mail-mt.c (mail_msg_received, mail_msg_destroy): Changed to use
        camel_operation rather than mail_status.
        (mail_msgport_received, mail_msgport_replied): Turn of the
        mail_status stuff, we dont need to report on stuff running in the
        gui thread right?
        (retrieve_shell_view_interface_from_control, set_view_data,
        mail_statusf,  mail_status, mail_status_end, mail_status_start,
        status_timeout, do_del_status, set_status_op): removed now
        redundant stuff.
        (mail_msg_free): Removed reference to timeout_id.

svn path=/trunk/; revision=11225
2001-07-19 13:31:22 +00:00
cdea22d886 partial checkin before completing the changes
2001-07-18  Not Zed  <NotZed@Ximian.com>

        * mail-local.c (reconfigure_folder_reconfigure): Changed to use
        camel_operation rathre than mail_status.
        (reconfigure_folder_describe): re-enabled this function.

        * mail-ops.c (get_messages_get): Changed to use camel-progress for
        status reporting.
        (save_messages_save): Likewise.

2001-07-17  Not Zed  <NotZed@Ximian.com>

        * mail-mt.c (struct _mail_msg_priv, destroy_objects, mail_msg_new,
        mail_msg_free, do_op_status): Changed to use an EvolutionActivityClient for
        progress.

svn path=/trunk/; revision=11223
2001-07-19 11:50:49 +00:00
03d2f262c0 Don't pop up a progress dialog to say "I already finished this a while
* mail-mt.c (op_status_timeout): Don't pop up a progress dialog to
	say "I already finished this a while ago".

	* component-factory.c (storage_create_folder): Pass the path
	prefix to folder_created so it can add it to the folder tree in
	the right place.

	* mail-callbacks.c (folder_created): Take a path prefix.

svn path=/trunk/; revision=10508
2001-06-26 19:13:24 +00:00
d4b3c14fcd Renamed from session.c and made to be a subclass of CamelSession.
* mail-session.c: Renamed from session.c and made to be a subclass
	of CamelSession.

	* mail-mt.c (mail_user_message): Renamed from mail_get_accept and
	made more general-purpose, to implement the new
	camel_session_alert_user.

svn path=/trunk/; revision=9618
2001-04-27 21:08:51 +00:00