Commit Graph

202 Commits

Author SHA1 Message Date
8a186c3588 Coding style cleanups. 2011-05-08 13:37:20 -04:00
4cfb84c573 Whitespace and coding style cleanups. 2011-05-07 18:48:38 -04:00
bf5647aa47 MailFolderCache: Drop folder URI in "folder-changed" signal.
We already include a CamelStore and folder name string in the signal
arguments, so it's trivial to reconstruct the URI if it's needed.
2011-05-06 12:58:55 -04:00
b8bb681c17 MailFolderCache: Emit folder names instead of URIs in signals. 2011-05-05 18:37:07 -04:00
324a7da5d7 Use e_mail_folder_uri_from_folder() instead of camel_folder_get_uri(). 2011-05-03 19:27:07 -04:00
c3b983d6e1 Drop 'folder_uri' param from em_utils_folder_is_outbox(). 2011-05-03 09:42:06 -04:00
b9f932b1b8 Drop 'folder_uri' param from em_utils_folder_is_sent(). 2011-05-03 09:42:06 -04:00
9e0f0f529f Drop 'folder_uri' param from em_utils_folder_is_drafts(). 2011-05-03 09:42:06 -04:00
fc0186d884 MailFolderCache: Remove 'folders_uri' hash table
We've been adding and removing folder URIs to this hash table but never
actually using it for anything.  Not a single lookup.  So just remove it.
2011-05-02 11:46:34 -04:00
ea0fdf21ec Adapt to sealed up CamelService. 2011-04-17 13:13:55 -04:00
c6fd77460f Coding style and whitespace cleanup. 2011-03-05 12:34:28 -05:00
1301cf02ef Bug #614480 - Avoid using G_TYPE_INSTANCE_GET_PRIVATE repeatedly 2011-02-25 16:20:41 +01:00
21ab8044da Coding style and whitespace cleanup. 2011-01-29 20:22:57 -05:00
2636da7dac Kill mail_store_set_offline().
Replace it with new async functions:

  e_mail_store_go_offline()
  e_mail_store_go_offline_finish()

  e_mail_store_go_online()
  e_mail_store_go_online_finish()
2010-10-22 17:26:08 -04:00
c881b5bc5e Simplify EActivity.
With unintrusive error dialogs gone, we can cut some unnecessary bits
out of EActivity.

I'm also adding a new enum property called "state", which is one of:

    E_ACTIVITY_RUNNING
    E_ACTIVITY_WAITING
    E_ACTIVITY_CANCELLED
    E_ACTIVITY_COMPLETED

The state of an activity must be explicitly changed.  In particular,
when the user cancels an activity the state should be set only after
confirming the operation has been cancelled and not when cancellation
is requested (e.g. after receiving a G_IO_ERROR_CANCELLED, not when
the GCancellable emits "cancelled").  EActivityBar and EActivityProxy
widgets have been updated to make this distinction clearer in the UI.

E_ACTIVITY_WAITING will be used when activities have to be queued and
dispatched in sequence, which I haven't written yet.
2010-10-22 14:21:22 -04:00
ae478d1e3c Collect mail enum types in e-mail-enums.h.
And generate GTypes for each of them in e-mail-enumtypes.[ch].

Also, the glib-gen.mak script forced me to add a <mail/e-mail.h>
top-level header, which really isn't a bad idea anyway.

TODO: We should do this for calendar and addressbook too.
2010-10-18 14:31:16 -04:00
35e55a8d6e Send errors to an EAlertSink instead of the task bar.
This marks the end of unintrusive error dialogs, which were too
unintrusive.  We now show errors directly in the main window using
the EAlert / EAlertSink framework.
2010-10-18 12:32:37 -04:00
ed45d23b84 Remove mail_tools_folder_to_url().
Use camel_folder_get_uri() instead.
2010-10-12 13:59:00 -04:00
a06e4484b8 Give MailSession a permanent home.
Global variables in shared libraries are a bad idea.  EMailBackend now
owns the MailSession instance, which is actually now EMailSession.

Move the blocking utility functions in mail-tools.c to e-mail-session.c
and add asynchronous variants.  Same approach as Camel.

Replace EMailReader.get_shell_backend() with EMailReader.get_backend(),
which returns an EMailBackend.  Easier access to the EMailSession.
2010-10-12 13:58:59 -04:00
8cd5fd9653 MailFolderCache notifies in reverse order
Causing unread count on Drafts disappear sometimes. (Drafts, like
Outbox, uses total message count, instead of real unread count).
2010-10-07 12:43:58 +02:00
3eb7903828 MailFolderCache: Use an idle callback instead of MailAsyncEvent. 2010-09-30 14:25:13 -04:00
fc2c71593a Remove "type" parameter from mail_async_event_emit().
All remaining cases use MAIL_ASYNC_GUI, so remove mail_async_event_t
altogether.
2010-09-30 13:55:39 -04:00
31b57ed038 Adapt to Camel API changes. 2010-09-28 11:35:55 -04:00
a91eeb6471 Pass GCancellable to Camel. 2010-09-28 11:35:55 -04:00
cd53ba9900 Coding style cleanups. 2010-09-13 08:28:58 -04:00
eb29179da6 Coding style and whitespace cleanup. 2010-07-11 22:25:06 -04:00
137b0743dd Migrate from CamelException to GError. 2010-07-08 14:37:52 -04:00
d729ecb765 Fix typo in mail-folder-cache.c:rename_folders 2010-06-15 21:00:39 +02:00
ead63f16b2 Bug #534369 - [new-mail-notify] Intermittent notifications 2010-06-14 20:15:55 +02:00
a5d79e9f91 Bug #546551 - Dialog for mark-all-read always mentions subfolders 2010-05-21 16:30:40 +02:00
8ad0c51edf Adapt to Camel API changes.
This also removes the boxed CamelObject GType, since CamelObject is an
honest-to-goodness GObject now.
2010-05-07 18:32:16 -04:00
aec33928b7 Adapt to Camel API changes. 2010-04-30 11:30:19 -04:00
ad1b3754f7 Bug #545505 - Properly free unused message infos periodically 2010-04-29 16:31:31 +02:00
bc90469e7f Camel is now GObject-based. 2010-04-24 11:05:27 -04:00
fabb6b035c Only #include Camel's top-level header. 2010-04-02 16:59:20 -04:00
f9dd2dd10b Move "section" documentation out of header files. 2010-03-21 17:24:42 -04:00
83a264cd7e Coding style and whitespace cleanup. 2009-12-19 18:36:46 -05:00
968ea42023 Kill em_utils_get_data/config_dir(), push down to MailSession
This pushes the get_data_dir() API down to the right level.  At present, it is
still implemented by querying the shell backend for the data dir / config dir.
But this should eventually be reversed (when mail is split off to EDS) so that
the mail daemon is the one responsible for the storage locations and the shell
backend queries the daemon for these values.
2009-12-16 11:10:02 -06:00
cef8bd60e1 Use the boxed CamelObject type for signal params in MailFolderCache
Previously I was just using G_TYPE_POINTER.  Use the boxed camel object type
from e-util.h instead.  When camel-gobject lands, we'll use G_TYPE_OBJECT
instead.
2009-12-15 14:16:09 -06:00
6818a05259 Add MailFolderCache::folder-changed signal
Yes, this signal is kind of an ugly monster.  I'm not sure how to improve this
significantly.  But this commit removes the last EMFolderTreeModel and EShell
dependencies from MailFolderCache, which is a big step towards splitting off
the backend.

https://bugzilla.gnome.org/show_bug.cgi?id=604627
2009-12-15 14:16:09 -06:00
9c644867fe MailFolderCache: add signal for updated unread counts
Emit a signal when we have an updated unread count for a folder rather than
pushing the update directly to a particular treemodel.  This doesn't yet remove
the dependency on EMFolderTreeModel, but it's a first step.

https://bugzilla.gnome.org/show_bug.cgi?id=604627
2009-12-15 14:16:09 -06:00
0eef4618ca Remove mail-config, vfolder, and filter deps from mail-folder-cache
Instead of pushing the updates to the right places, the folder cache simply
emits the appropriate signals and other objects are responsible for listening
and handling them appropriately.  This allows us to cut down the dependencies of
MailFolderCache significantly, which is a huge step towards allowing us to split
it off for the backend.

Another nice thing about this is that it allows us to trim a lot of 'public' api
from the filter, vfolder, and config classes that were only used by the cache.
Now that stuff can all be internal since they're pulling changes rather than
having the changes pushed.

The last remaining problematic dependency in MailFolderCache is
EmFolderTreeModel.  That is next on the chopping block.

https://bugzilla.gnome.org/show_bug.cgi?id=604627
2009-12-15 14:16:09 -06:00
6e73a7a8f3 Add signals to MailFolderCache for common events
This will allow us to decouple ourselves from some of the current dependencies,
such as the folder treemodel, the shell, etc.  This just defines the signals,
the next step is to refactor things and actually make other classes use them.

We need one additional signal yet related to indicating the new unread emails,
but that one will require a little more thought I think.

https://bugzilla.gnome.org/show_bug.cgi?id=604627
2009-12-15 14:16:08 -06:00
9c4f98e915 Add documentation to clarify mail-folder-cache functionality
Added a bunch of gtk-doc documentation as well as a variety of small comments in
the code.  Also added documentation and renamed a couple of mail_vfolder_*
functions that are only used by mail-folder-cache to make things a lot more
understandable.

https://bugzilla.gnome.org/show_bug.cgi?id=604627
2009-12-15 14:16:08 -06:00
65705e4f55 Make the mail folder cache a proper GObject
mail-folder-cache previously was a bit of a pseudo object (sort of a singleton)
that operated on some file static data.  This commit re-factors things so that
it is a proper class named MailFolderCache.  At the moment, this doesn't gain us
much, but in the future, it will allow us to add signals, etc so that we can
de-couple a lot of the interdependencies in here.  This is essentially a
pre-requisite to splitting up a lot of the mail backend stuff.

https://bugzilla.gnome.org/show_bug.cgi?id=604627
2009-12-15 14:16:08 -06:00
daa8339f17 Bug #464400 - New mail notify should display sender and subject 2009-10-30 17:01:01 +01:00
c58b706597 Prefer GQueue (or GNode) over EDList. 2009-10-27 09:25:01 -04:00
a09f553458 Prefer GLib mutexes over pthread mutexes. 2009-10-27 09:25:00 -04:00
93040de356 Bug #339628 - Non-default Draft folders are Draft folders too 2009-10-16 11:32:46 +02:00
ff7084ffe4 Bug 571488 - Migrate from deprecated gnome_sound to libcanberra 2009-08-23 08:31:14 -04:00