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-13 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (check_send_configuration): Make sure the
folder-browser is not NULL or we'll crash.
svn path=/trunk/; revision=19115
2002-12-13 Jeffrey Stedfast <fejj@ximian.com>
* mail-session.c: Get rid of unneeded CamelObject casts.
(user_message_response): Don't unref the dialog object after we've
destroyed it.
* mail-display.c (write_data_to_file): Don't unref the dialog
object after we've destroyed it.
* mail-callbacks.c: Same here.
* component-factory.c: Here too.
* message-tag-editor.c: Added MESSAGE_TAG_EDITOR_GET_CLASS macros.
svn path=/trunk/; revision=19112
2002-12-03 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (guess_me_from_accounts): Use the same logic as
mail_generate_reply(). Fixes bug #34882
Fixes bug #34315
* component-factory.c (message_rfc822_dnd): Return TRUE if we
successfully handled all messages in the mbox stream, or FALSE
otherwise.
(destination_folder_handle_drop): For TEXT_URI_LIST, use the
retval from message_rfc822_dnd() rather than relying on an
exception, because one will not always necessarily be set. For
MESSAGE_RFC822, also use the retval from message_rfc822_dnd().
svn path=/trunk/; revision=18995
2002-11-27 Not Zed <NotZed@Ximian.com>
* message-tag-followup.c (construct): gnome_pixmap -> gtkimage.
(construct): gtk_clist -> gtk_tree_view, setup columns. They dont
size well :-/
(message_tag_followup_append_message): Append using model, remove
clist stuff.
(construct): Show date edit (glade bugs?)
* folder-browser.c (folder_browser_class_init): gtk_marshal -> g_cclosure_marshal
(setup_popup_icons): gnome_pixmap -> gtk_image.
(on_right_click): gtk_pixmap -> gtk_image.
* mail-accounts.c (account_delete_clicked): removed #if 0'd out code.
* mail-send-recv.c (receive_done): remove FIXME and extra unref.
* mail-session.c (request_password): Removed #if 0'd out stuff.
* mail-vfolder.c (new_rule_clicked): proper cast for g_object_get_data.
* mail-local.c (reconfigure_response): cast for g_object_get_data.
* mail-account-editor.c (construct): GNOME_DIALOG -> GTK_DIALOG.
* *.[ch]: re-ran fix.sh for e_notice change
* mail-callbacks.c (save_msg_ok): g_object_get_data +
gtk_object_remove_no_notify -> g_object_steal_data.
(find_socket): gtk_container_children ->
gtk_container_get_children
(edit_msg): gnome_*_dialog -> gtk_message_dialog.
(resent_msg): "
(search_msg): "
(confirm_goto_next_folder): gtkmessagedialogised (even if not
used).
(confirm_expunge): gtkmessagedialogised
(filter_edit): "
(do_mail_print): e_notice -> gtk_message_dialog.
(are_you_sure): removed e_gnome_ok_cancel_dialog crap, replaced
with a gtk dialog.
(are_you_sure): gtkmessagedialogised.
(edit_msg_internal): Dont free uids array, are_you_sure() free's
it.
(resend_msg): Same.
(check_send_configuration): Use e_notice for stuff. Sigh, here we
go again ...!
(e_question): A utility function to ask a question, potentially
with 'dont ask again' as well.
(configure_mail): use e_question to save code. Here we go again,
again ...
(ask_confirm_for_unwanted_html_mail): "
(ask_confirm_for_only_bcc): "
(ask_confirm_for_only_bcc): "
(composer_get_message): Use e_notice.
(composer_save_draft_cb): Use e_question
(edit_msg): use e_notice, & change to an ERROR.
(resend_msg): same.
(save_msg_ok): Properly initialise ret to OK, and use e_question,
and use access() to determine existance/write access rather than
stat, display an error if we can't write to a file that exists,
and print the filename in all dialogues.
(confirm_goto_next_folder): Use e_question.
(confirm_expunge): use e_question.
(filter_edit): Use e_notice.
(do_mail_print): use e_notice.
svn path=/trunk/; revision=18974
2002-11-26 Not Zed <NotZed@Ximian.com>
* message-list.c (get_normalised_string): Duh idiot, "un-fixed"
the memleak i added.
* mail-callbacks.c (composer_get_message): Set parent window in
message dialogue & DESTROY_WITH_PARENT flag.
(composer_save_draft_cb):
(configure_mail):
(check_send_configuration): Add DESTROY_WITH_PARENT flag to
gtk_message_dialog's
(local_configure_done): remove some unecessary/wrong casts.
(empty_trash_expunged_cb): "
(do_mail_print): use gtk_window_set_transient_for instead of
e_dialog_set_parent.
svn path=/trunk/; revision=18923
2002-11-26 Not Zed <NotZed@Ximian.com>
* mail-account-editor.c (mail_account_editor_new):
gtk_widget_set_parent_window -> gtk_window_set_transient_for.
* mail-callbacks.c (composer_send_queued_cb): dont unref composer.
* message-browser.c (message_browser_destroy): moved back from
finalise.
2002-11-25 Not Zed <NotZed@Ximian.com>
* message-list.c (message_list_dispose): move saving tree state
here.
(message_list_finalise): And take it from here.
* mail-display.c (mail_display_destroy): @#$@# gtk. changed this
around a bit.
(mail_display_init): Fix prototype, its a gobject.
(mail_display_init): ref/sink the invisible gtkobject.
svn path=/trunk/; revision=18919
2002-11-22 Not Zed <NotZed@Ximian.com>
* mail-callbacks.c (ask_confirm_for_unwanted_html_mail): removed
e_messagebox, and use gtk_message_dialog directly.
(ask_confirm_for_empty_subject): and here.
(ask_confirm_for_only_bcc): And here too.
(msgbox_destroy_cb): Removed, since no longer needed.
svn path=/trunk/; revision=18905
2002-11-19 Not Zed <NotZed@Ximian.com>
* importers/evolution-mbox-importer.c (mail_importer_module_init):
fix warning message, outlook->mbox.
* importers/Makefile.am: fix serverdir to point to
$libdir/bonobo/servers.
* mail-callbacks.c (addrbook_sender): add type to
bonobo_widget_set_property.
* mail-vfolder.c (vfolder_editor_response): dont unref after destroy.
* mail-session.c (pass_response): dont unref aftrer destroy.
* mail-local.c (reconfigure_response): dont unref after destroy.
* mail-display.c (launch_cb): dont unref after destroy.
(launch_cb): "
(drag_data_get_cb): "
(html_button_press_event): add type to bonobo_widget::set_property
* mail-config.c (mail_config_check_service): dont unref after
destroy.
* component-factory.c (send_receive_cb): dont unref after destroy.
(request_quit): "
* mail-signature-editor.c (mail_signature_editor): Use version 3.0
of gtkhtml editor interfaces.
(do_exit): dont unref after destroy.
(format_html_cb): Add type to bonobo_widget::set_property.
svn path=/trunk/; revision=18837
2002-11-14 Jeffrey Stedfast <fejj@ximian.com>
* mail-accounts.c (account_edit_clicked): Use g_object_weak_ref
rather than connecting to destroy.
(account_add_clicked): Same.
* mail-callbacks.c (addrbook_sender): Make this use
g_object_weak_notify also.
(subscribe_dialog_destroy): Add NULL guards here since I think we
really do want to connect to the "destroy" signal in the function
that connects us to that signal.
* mail-config-factory.c (config_control_factory_cb): Same.
* mail-display.c (save_part): Here too.
(make_popup_window): And here.
* mail-send-recv.c (build_dialogue): Same here.
* mail-summary.c (create_summary_view): Use g_object_weak_notify
instead of connecting to the destroy signal.
svn path=/trunk/; revision=18764
2002-10-22 Mike Kestner <mkestner@ximian.com>
* mail-callbacks.c (transfer_msg): pass fb->uri to the folder
selection dialog so the current folder is selected on display.
"fixes" 15966.
svn path=/trunk/; revision=18420
2002-10-16 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (mail_generate_reply): If mode == REPLY_LIST
and the mlist is "" (we only checked NULL before), change the mode
to REPLY_ALL so that we don't accidently reply to the user's
address. Fixes bug #28735
svn path=/trunk/; revision=18381
2002-10-12 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (mail_generate_reply): If we are trying to
reply to a list, first check that we can by getting the mlist
token (makes it easier to fix the mem leak). If not, then change
the mode to REPLY_ALL. If we can reply to list, the make sure we
free the CamelMessageInfo when we're done so we don't leak.
svn path=/trunk/; revision=18376
2002-10-12 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (mail_generate_reply): If we are trying to
reply to a list, first check that we can by getting the mlist
token. If not, then change the mode to REPLY_ALL. If we can reply
to list, the make sure we free the CamelMessageInfo when we're
done so we don't leak. Also added a check to see if the mlist
token could be found in the Reply-To ehader (since some mailing
lists override the Reply-To with their address).
svn path=/trunk/; revision=18375
2002-10-02 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (mail_generate_reply): Don't default 'me' to
the source account until after we've tried to detect the account
based on recipients. When adding accounts to the account hash, if
any accounts have identical email addresses, the ones that are
enabled take precedence over ones that aren't. This will hopefully
make everyone happy with reply account picking. Fixes bug #31693.
svn path=/trunk/; revision=18326
* component-factory.c (folder_types): add "mail/public". Leave
"vtrash" as it is rather than renaming it to "mail/vtrash",
because we want it to behave differently from normal mail folders
more often than we want it to behave the same.
(type_is_mail, type_is_vtrash): utility funcs
(create_view, create_folder, remove_folder, xfer_folder,
populate_folder_context_menu, unpopulate_folder_context_menu,
destination_folder_handle_drop, storage_create_folder): Use
type_is_mail/type_is_vtrash.
(create_component): Register "New Post" with "mail/public" instead
of "mail" so it becomes the default New icon for it. (29024)
* mail-callbacks.c (transfer_msg): Use "mail/*" for allowed type.
* message-browser.c (transfer_msg): Likewise.
* mail-account-gui.c (mail_account_gui_new): Use "mail/*" instead
of "mail" here for sent/drafts allowed type. (?)
svn path=/trunk/; revision=18223
2002-09-19 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (do_edit_messages): Unset the changed bit on
the composer and also drop any undo operations (since we loaded
the message into the composer). Fixes bug #30580.
svn path=/trunk/; revision=18127
2002-09-11 Not Zed <NotZed@Ximian.com>
* component-factory.c (configure_folder_popup): Handle file uri's
too.
* mail-callbacks.c (configure_folder): clear message list before
calling configure folder.
(local_configure_done): completion callback to reset message list
when done.
* mail-local.c (mail_local_reconfigure_folder): changed args to
accept uri, and done callback.
(reconfigure_got_folder): moved code to callback which presents
the configure uri once we have the folder.
svn path=/trunk/; revision=18039
2002-09-09 Jeffrey Stedfast <fejj@ximian.com>
* folder-browser-ui.c (folder_browser_ui_scan_selection): Make
sure that fb->message_list is non-NULL before checking
fb->message_list->threaded? I guess this'll fix bug #29965.
* mail-callbacks.c (composer_save_draft_cb): NULL-check the ccd
before reffing it.
(composer_send_cb): Same.
svn path=/trunk/; revision=18026
2002-09-05 Jeffrey Stedfast <fejj@ximian.com>
All this snot is to fix bug #29930. What I think was happening was
that the composer's destroy callback got fired off before the
async callback did.
* mail-callbacks.c (ccd_new): New convenience function to malloc a
new ccd.
(ccd_ref): ccd is now ref_counted (it needs to be) so we now have
this.
(ccd_unref): And we need this now too of course.
(composer_destroy_cb): composer's new destroy callback function -
unref's the ccd.
(composer_send_queued_cb): unref the ccd.
(composer_send_cb): ref the ccd here.
(save_draft_done): unref the ccd.
(composer_save_draft_cb): ref the ccd.
svn path=/trunk/; revision=17997
2002-09-04 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (mail_generate_reply): Made sure
account->id->address is not NULL before adding it to the hash
table. This is to prevent bug #29877 from crashing, although it is
still an invalid error condition.
svn path=/trunk/; revision=17969
2002-08-26 Peter Williams <peterw@ximian.com>
* mail-callbacks.c (toggle_flags): Logic change for when untoggling
a message from deleted-dom.
svn path=/trunk/; revision=17869
2002-08-20 Radek Doulik <rodo@ximian.com>
* mail-callbacks.c (do_mail_print): be sure that widget is
realized so that e_utf8_from_gtk_string works properly
(footer_print_cb): save/restore
svn path=/trunk/; revision=17826
2002-08-09 Peter Williams <peterw@ximian.com>
* subscribe-dialog.c: Change this into a GnomeApp so we get a
statusbar and the dialog is a little more comprehensible.
* subscribe-dialog.c: (struct _FolderETree): Add members for
tracking activity callback information.
(get_short_folderinfo_got): Notify the activity callback.
(subscribe_get_short_folderinfo): Here too.
(folder_etree_init): Initialize the activity level to 0.
(folder_etree_construct): Take new parameters of our activity
callback and user_data.
(folder_etree_new): Here too.
(store_data_get_widget): Take the parameters here and pass them
on.
(sc_close_pressed): New callback for when close button is pressed.
(sc_activity_timeout): New timeout to move the activity bar when
folders are being scanned.
(sc_activity_cb): If activity_level > 0, start the progressbar
moving and set the status.
(menu_item_selected): Pass the callback to store_data_get_widget.
(subscribe_dialog_construct): Load some more widgets and adapt to
some changes in the XML. Also connect the close button signal and
initialize the progress bar's settings.
* mail-callbacks.c (manage_subscriptions): Don't call
gnome_dialog_set_close on it anymore since it's no longer a gnome
dialog.
svn path=/trunk/; revision=17793
2002-08-13 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (forward_message): Removed an unused variable.
* mail-account-editor.c (construct): Set the focus on the Account
Name entry widget. Fixes bug #10350.
svn path=/trunk/; revision=17771
2002-08-12 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (forward_message): Use mail_get_messages()
instead of mail_get_message().
(do_forward_non_attached): Fixed to work as a callback from
mail_get_messages().
(do_edit_messages): Only set the drafts_folder and drafts_uid if
the folder-browser is a drafts folder. Fixes bug #28863.
svn path=/trunk/; revision=17762
2002-08-12 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (forward_message): Use mail_get_messages()
instead of mail_get_message().
(do_forward_non_attached): Fixed to work as a callback from
mail_get_messages().
svn path=/trunk/; revision=17761
2002-08-09 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (save_draft_done): If the ccd is NULL, create a
new ccd, disconnect the old signal handlers, and then reconnect
the signal handlers using the non-NULL ccd as the user_data.
(composer_send_queued_cb): Same, but only if the queue append
operation failed.
svn path=/trunk/; revision=17756
* mail-callbacks.c (composer_send_queued_cb, save_draft_done):
Handle the fact that ccd may be NULL (if the composer was created
via CORBA). Quick temporary fix for sending meeting requests.
svn path=/trunk/; revision=17754
2002-08-08 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (delete_msg): Don't check permanent_flags for
the CAMEL_MESSAGE_DELETED bit here, if we are gonna check to see
if the folder supports the permanent flag then there are better
places to check this. Besides, it was the cause for bug #28038.
svn path=/trunk/; revision=17740
2002-08-07 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (composer_send_queued_cb): Delete the Draft
item that this was edited from if that is the case as well as
setting any replied flags if we need to. Fixes bug #18171.
(save_draft_done): Not only delete the previously saved draft, but
also set any PostSendData on the message being replied to or
whatever. Fixes bug #20224.
(compose_msg): Create an empty callback data struct which is now a
MUST.
(mail_reply): Fill in the new post_send_data info and also move
the creation of the post_send_data to AFTER the creation of the
composer widget so we don't leak on fail.
(forward_get_composer): Pass an empty post_send_data structure as
the user_data to the signal callbacks.
(send_to_url): Same.
(post_to_url): Here too.
(redirect_get_composer): And here.
(do_edit_messages): We no longer use the evil kludge of setting
data on the composer object to denote the drafts_uid etc, this is
now part of the post_send_data struct.
svn path=/trunk/; revision=17736
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 Jeffrey Stedfast <fejj@ximian.com>
* component-factory.c (user_create_new_item_cb): Updated to call
post_to_url if the id is "post".
* mail-callbacks.c (post_to_url): New function so that we don't
need a FolderBrowser to post a new message.
(post_message): Call post_to_url since they shared so much code.
svn path=/trunk/; revision=17698
2002-08-02 Jeffrey Stedfast <fejj@ximian.com>
* mail-display.c (mail_display_render): Updated to use the new
Follow-Up tags. Instead of storing a string containing the
follow-up tag value, we now have to store the CamelMessageInfo.
(mail_display_destroy): Unref the folder and the message-info.
* folder-browser.c (followup_tag_complete): No longer needed.
(on_right_clicked): Use the individual follow-up tags to decide
whether or not to enable something.
* message-list.c (ml_tree_value_at): Update to use the new
Follow-Up tags.
* mail-callbacks.c (flag_for_followup): Update to use the new
MessageTagEditor API.
(tag_editor_ok): Update this too.
(flag_followup_completed): Updated this too.
(flag_followup_clear): Set all the follow-up tag values to "".
svn path=/trunk/; revision=17691
2002-07-25 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (composer_send_cb): Make sure that the url
isn't an empty string and also make sure to free it when we're
done with it. Also check that we got the folder - if it is NULL,
then just abort.
svn path=/trunk/; revision=17593
2002-07-24 Jeffrey Stedfast <fejj@ximian.com>
* mail-config.c (mail_config_folder_to_safe_url): Use
mail_tools_folder_to_url().
* mail-tools.c (mail_tools_folder_to_url): New convenience
function to take a CamelFolder and return the URL associated with
it.
* mail-callbacks.c (composer_get_message): Pass in a 'post'
argument so we know whether or not we can ignore a NULL set of
recipients.
(composer_send_cb): Default send->send to TRUE unless we are in
Post-To mode, in which case set send->send to FALSE (since we'll
have nothing to send). Also, if we are in Post-To mode, append to
the folder the user wants to post to rather than appending to
Outbox.
(composer_send_queued_cb): Only queue a send thread if send->send
is TRUE (ie, the composer was not in Post mode - if it was in Post
mode, then the message post has already been saved in the correct
folder so there is nothing to do).
(post_message): New function to create an empty composer widget in
Post mode.
(post_reply): New function that calls mail_reply with the new mode
of REPLY_POST.
(mail_generate_reply): If the mode is REPLY_POST, create a Post
composer widget otherwise create a normal composer widget.
svn path=/trunk/; revision=17592
2002-07-24 Peter Williams <peterw@ximian.com>
* mail-callbacks.c (do_mail_fetch_and_print): Check for whether
current_message is NULL as well as preview_shown (if we tried to
load the message and failed, as may happen in offline mode.)
(done_message_selected): Only print if we actually got the message.
* folder-browser.c (folder_browser_query_changed): New function,
use this on the query_changed signal. Don't run the search if
they only changed the dropdown.
svn path=/trunk/; revision=17580
2002-07-19 Not Zed <NotZed@Ximian.com>
* mail-callbacks.c: Try including gtkhtml/gtkhtml.h instead. Test
really is a 4 letter word obviously.
svn path=/trunk/; revision=17515
2002-07-15 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (composer_send_cb): Pass 'info' into
mail_append_mail(), seems I created the info but forgot to pass it
in.
(composer_send_queued_cb): If the message is successfully queued,
we destroy the composer, otherwise we unref it. Don't ever destroy
and then unref it.
svn path=/trunk/; revision=17468