After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 604952 - Cleanup dependencies in the mail backend
Cleanup dependencies in the mail backend
Status: RESOLVED FIXED
Product: evolution
Classification: Applications
Component: Mailer
unspecified
Other All
: Normal normal
: ---
Assigned To: evolution-mail-maintainers
Evolution QA team
Depends on:
Blocks:
 
 
Reported: 2009-12-18 21:18 UTC by Jonathon Jongsma
Modified: 2009-12-21 16:08 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Move forward_to() implementation to MailSession (remove dep on composer) (17.94 KB, patch)
2009-12-18 21:18 UTC, Jonathon Jongsma
committed Details | Review
Remove em_utils_show_error_silent() from MailSession (2.55 KB, patch)
2009-12-18 21:18 UTC, Jonathon Jongsma
rejected Details | Review
Move the gross hack for EAccountComboBox up a level (1.96 KB, patch)
2009-12-18 21:18 UTC, Jonathon Jongsma
committed Details | Review
The shell backend is responsibile for setting the MailSession online (1.88 KB, patch)
2009-12-18 21:18 UTC, Jonathon Jongsma
committed Details | Review
Remove MailSession's last dep on EShell (1.40 KB, patch)
2009-12-18 21:18 UTC, Jonathon Jongsma
committed Details | Review
Clean up a bunch of unnecessary includes in mail/ (6.84 KB, patch)
2009-12-18 21:19 UTC, Jonathon Jongsma
committed Details | Review
Remove the EShellBackend parameter from mail_session_init() (1.86 KB, patch)
2009-12-18 21:19 UTC, Jonathon Jongsma
committed Details | Review

Description Jonathon Jongsma 2009-12-18 21:18:40 UTC
These are some more changes in preparation for the eds-mail split.
Comment 1 Jonathon Jongsma 2009-12-18 21:18:43 UTC
Created attachment 150029 [details] [review]
Move forward_to() implementation to MailSession (remove dep on composer)

Previously, the CamelSesssion's forward_to vfunc was implemented in
em-composer-utils.  However, there wasn't really any composer-related
functionality that this function depended on, so in order to remove
MailSession's dependency on composer-related functionality, this function was
moved into mail-session.c.  So now, instead of calling
em_utils_forward_message_raw(), you should just call camel_session_forward_to()
instead.

This change necessitated moving a couple of "guess_account"-related functions
into em-utils, but that's ok for now -- it matches the existing
em_utils_guess_account() function that's already there.
Comment 2 Jonathon Jongsma 2009-12-18 21:18:50 UTC
Created attachment 150030 [details] [review]
Remove em_utils_show_error_silent() from MailSession

When we split the front- and back-end, we really can't have any dependency on
EShell from the MailSession, so this function has to go.  Currently I just
ripped out the offending function call and display an error dialog directly.  In
the future, we need to find a nicer way to coordinate error-reporting between
the frontend and backend.
Comment 3 Jonathon Jongsma 2009-12-18 21:18:53 UTC
Created attachment 150031 [details] [review]
Move the gross hack for EAccountComboBox up a level

This hack really needs to be fixed correctly, but I can't think of a good
solution for now.  So at the very least, move the hack up a level where it won't
cause dependency problems for the mail-to-eds split.
Comment 4 Jonathon Jongsma 2009-12-18 21:18:56 UTC
Created attachment 150032 [details] [review]
The shell backend is responsibile for setting the MailSession online

Previously the mail session set itself online inside mail_session_init() by
checking whether the shell was online.  This removes one more dependency from
MailSession to EShell by moving that responsibility up one level.
Comment 5 Jonathon Jongsma 2009-12-18 21:18:59 UTC
Created attachment 150033 [details] [review]
Remove MailSession's last dep on EShell

When MailSession moves to a daemon process, there will be no shell object to
query for the active window (and indeed there will often be no window in any
case), so we can't specify a parent for the error dialog.
Comment 6 Jonathon Jongsma 2009-12-18 21:19:01 UTC
Created attachment 150034 [details] [review]
Clean up a bunch of unnecessary includes in mail/

Over time, extra includes have built up.  I'm trying to get a good idea of what
are actual dependencies for these  files, so I'm cleaning out all of the
unused ones.
Comment 7 Jonathon Jongsma 2009-12-18 21:19:03 UTC
Created attachment 150035 [details] [review]
Remove the EShellBackend parameter from mail_session_init()

Last shell-related dep killed in MailSession
Comment 8 Matthew Barnes 2009-12-19 13:13:33 UTC
Most of the patches look good, but I'm concerned with "Remove em_utils_show_error_silent() from MailSession".  That code was the primary reason for suppressing annoying error dialogs, and I would hate to release a version with that reverted.  But I understand the eventual need for it.

Would it be possible for you to sit on that one for awhile?  Keep it in a private branch or something?  I don't really want it landing in master until we actually have a mail backend or at least a better way of reporting errors to the user that doesn't involve dialogs.

All other patches approved.  Some nice cleanups in there.
Comment 9 Jonathon Jongsma 2009-12-19 14:44:04 UTC
(In reply to comment #8)
> Most of the patches look good, but I'm concerned with "Remove
> em_utils_show_error_silent() from MailSession".  That code was the primary
> reason for suppressing annoying error dialogs, and I would hate to release a
> version with that reverted.  But I understand the eventual need for it.
> 
> Would it be possible for you to sit on that one for awhile?  Keep it in a
> private branch or something?  I don't really want it landing in master until we
> actually have a mail backend or at least a better way of reporting errors to
> the user that doesn't involve dialogs.
> 
> All other patches approved.  Some nice cleanups in there.

Yeah, I understand.  I'll sit on that patch for a while yet.  thanks for the reviews.
Comment 10 Jonathon Jongsma 2009-12-21 16:06:43 UTC
pushed the 6 other patches to master.
Comment 11 Jonathon Jongsma 2009-12-21 16:08:36 UTC
Comment on attachment 150030 [details] [review]
Remove em_utils_show_error_silent() from MailSession

will keep this one on a local branch until we decide how to handle it.