platform/upstream/evolution-data-server.git
10 years agoBug 701838 - Work around a semantic API break in GObject
Tristan Van Berkom [Sat, 8 Jun 2013 14:12:14 +0000 (10:12 -0400)]
Bug 701838 - Work around a semantic API break in GObject

Recent versions of GObject fire critical messages if properties are
installed outside of class initializers (causing all of EDS tests to
fail).  This patch adds some class data and initializes the class in
the dynamic subclass initializer.

Note that the class data which should normally be freed in the class
finalizer is not freed, since it is a static type the finalizer will
never run (and GLib also takes the liberty of firing critical messages
for specifying a class finalizer).

11 years agoFix e-source-enumtypes.h generation.
Tristan Van Berkom [Mon, 3 Jun 2013 10:02:52 +0000 (19:02 +0900)]
Fix e-source-enumtypes.h generation.

Cannot feed more than one file to EDS's enum generation rule, or
else it results in imbalanced G_BEGIN/END_DECLS declarations.

11 years agoAdding D-Bus localed xml description to EXTRA_DIST to pass distcheck
Tristan Van Berkom [Tue, 28 May 2013 09:23:42 +0000 (18:23 +0900)]
Adding D-Bus localed xml description to EXTRA_DIST to pass distcheck

11 years agoCustomize the default system addressbook
Tristan Van Berkom [Tue, 28 May 2013 08:36:27 +0000 (17:36 +0900)]
Customize the default system addressbook

This patch modifies data/sources/system-address-book.source.in
so that it has a customized summary optimized for person names
and phone numbers.

This customization adds the following fields to the summary
with prefix indexes (for optimized SQLite queries):

 E_CONTACT_FULL_NAME, E_CONTACT_FAMILY_NAME, E_CONTACT_NICKNAME,
 E_CONTACT_GIVEN_NAME, E_CONTACT_TEL

Additionally, the E_CONTACT_TEL field is configured to store the
normalized phone number data in SQLite in order to optimize the
phone number queries such as E_BOOK_QUERY_EQUALS_PHONE_NUMBER.

The code to achieve the same configuration is as follows:

e_source_backend_summary_setup_set_summary_fields (
setup,
E_CONTACT_FULL_NAME,
E_CONTACT_FAMILY_NAME,
E_CONTACT_NICKNAME,
E_CONTACT_GIVEN_NAME,
E_CONTACT_TEL,
0);
e_source_backend_summary_setup_set_indexed_fields (
setup,
E_CONTACT_FULL_NAME, E_BOOK_INDEX_PREFIX,
E_CONTACT_FAMILY_NAME, E_BOOK_INDEX_PREFIX,
E_CONTACT_NICKNAME, E_BOOK_INDEX_PREFIX,
E_CONTACT_GIVEN_NAME, E_BOOK_INDEX_PREFIX,
E_CONTACT_TEL, E_BOOK_INDEX_PREFIX,
E_CONTACT_TEL, E_BOOK_INDEX_PHONE,
0);

11 years agoAdded test-sqlite-cursor-change-locale.c
Tristan Van Berkom [Mon, 27 May 2013 11:20:33 +0000 (20:20 +0900)]
Added test-sqlite-cursor-change-locale.c

This new test changes the locale dynamically and then checks new
sort order of the converted addressbook between every locale
change.

11 years agolibedata-book tests: Changed all cursor tests to use new testing APIs
Tristan Van Berkom [Mon, 27 May 2013 03:04:16 +0000 (12:04 +0900)]
libedata-book tests: Changed all cursor tests to use new testing APIs

Mostly changed to include the locale in the move-by tests and to stop
setting the 'EDS_COLLATE' variable to hack the current locale used by
the backend.

11 years agotests/libedata-book: Added a testing API to set the locale dynamically
Tristan Van Berkom [Fri, 17 May 2013 09:31:50 +0000 (18:31 +0900)]
tests/libedata-book: Added a testing API to set the locale dynamically

Also, the 'move-by' testing API now has a locale argument.

11 years agoEBookClient: Added "locale" property.
Tristan Van Berkom [Thu, 23 May 2013 10:56:04 +0000 (19:56 +0900)]
EBookClient: Added "locale" property.

Propagate the 'locale' property change notifications when the dbus
proxy notifies a locale property change, also load the initial value
of the dbus proxy's locale property for the initial value.

11 years agoEBookBackendFile: Implement EBookBackend->set_locale() & ->get_locale()
Tristan Van Berkom [Thu, 23 May 2013 07:26:26 +0000 (16:26 +0900)]
EBookBackendFile: Implement EBookBackend->set_locale() & ->get_locale()

11 years agoEBookBackendSqliteDB: Added e_book_backend_sqlitedb_get/set_locale()
Tristan Van Berkom [Thu, 23 May 2013 07:15:34 +0000 (16:15 +0900)]
EBookBackendSqliteDB: Added e_book_backend_sqlitedb_get/set_locale()

Locale setting is now only ever guessed when creating a new addressbook
before e_book_backend_sqlitedb_set_locale() is called, setting the locale
will save the localization setting and it will be reused on subsequent
accesses. If and when a locale setting is changed, the contact sort
keys are regenerated with a new ECollator for the new locale.

11 years agoEDataBook: Watch the system bus for locale notifications
Tristan Van Berkom [Thu, 23 May 2013 06:24:09 +0000 (15:24 +0900)]
EDataBook: Watch the system bus for locale notifications

When org.freedesktop.locale1 is available, listen to changes in
the LC_COLLATE locale and configure backends with locale changes
using e_book_backend_set_locale(), notify property changes via
the locale property on the addressbook D-Bus API.

Also, load the backend's initially set locale as the locale property
value until the org.freedesktop.locale1 D-Bus interface notifies
us of a locale change on the system bus.

11 years agoEBookBackend added new ->set_locale() API and ->get_locale() API
Tristan Van Berkom [Fri, 17 May 2013 11:03:45 +0000 (20:03 +0900)]
EBookBackend added new ->set_locale() API and ->get_locale() API

Use these to dynamically set the locale of a running addressbook, and also
to fetch the currently configured locale of an addressbook at startup time

11 years agoorg.gnome.evolution.AddressBook.xml: Added Locale property.
Tristan Van Berkom [Thu, 23 May 2013 10:54:58 +0000 (19:54 +0900)]
org.gnome.evolution.AddressBook.xml: Added Locale property.

11 years agoAdded org.freedesktop.locale1 interface to private/ to generate a DBus proxy
Tristan Van Berkom [Mon, 20 May 2013 07:08:35 +0000 (16:08 +0900)]
Added org.freedesktop.locale1 interface to private/ to generate a DBus proxy

11 years agoMigrated sqlite cursor test cases to not specify any specific collation rule.
Tristan Van Berkom [Fri, 17 May 2013 12:17:44 +0000 (21:17 +0900)]
Migrated sqlite cursor test cases to not specify any specific collation rule.

11 years agoPorted data migration tests to use the new ICU sorted data.
Tristan Van Berkom [Tue, 7 May 2013 13:00:32 +0000 (22:00 +0900)]
Ported data migration tests to use the new ICU sorted data.

Added migration tests also for fr_CA and de_DE locale, the
de_DE locale expects a @collation=phonebook type of sort order
but only the test-sqlite-cursor-posix-initial test which creates
the shared addressbook defines it, so we also test that the
collation rule is properly stored and introspected in the
SQLite tables.

11 years agoPorted test-sqlite-cursor-set-sexp to use the new ICU sorted data.
Tristan Van Berkom [Tue, 7 May 2013 12:12:29 +0000 (21:12 +0900)]
Ported test-sqlite-cursor-set-sexp to use the new ICU sorted data.

11 years agoPorted test-sqlite-cursor-calculate test to use the new ICU test data.
Tristan Van Berkom [Tue, 7 May 2013 11:23:07 +0000 (20:23 +0900)]
Ported test-sqlite-cursor-calculate test to use the new ICU test data.

11 years agoPorted test-sqlite-cursor-set-target.c to work with new ICU test data.
Tristan Van Berkom [Tue, 7 May 2013 10:48:21 +0000 (19:48 +0900)]
Ported test-sqlite-cursor-set-target.c to work with new ICU test data.

No point in doing one for every locale, we test a bunch of locales already
with the move-by test.

11 years agoFixed test-sqlite-cursor-move-by for new ICU localization
Tristan Van Berkom [Thu, 2 May 2013 13:01:39 +0000 (22:01 +0900)]
Fixed test-sqlite-cursor-move-by for new ICU localization

Added new sortable vcards and changed the whole sortable data set.

Now there are 4 move-by tests: posix, en_US, fr_CA and de_DE. All
tests try the default and phonebook collation rules, the de_DE test
data sorts differently under phonebook sort.

A table was added to data-test-utils.h for reference, showing
the expected order of sorted contacts in given locales.

11 years agoEBookBackendSqliteDB: Pull out the code which keeps separate collators per summarized...
Tristan Van Berkom [Fri, 17 May 2013 11:58:05 +0000 (20:58 +0900)]
EBookBackendSqliteDB: Pull out the code which keeps separate collators per summarized field.

For now let's keep a single ECollator, it seems that we don't want to configure
collation rules but rather have a single collator API which maintains a
knowledge base of what tailoring to choose in which locale.

11 years agoEBookBackendSqliteDB: Use ECollator
Tristan Van Berkom [Thu, 2 May 2013 13:00:28 +0000 (22:00 +0900)]
EBookBackendSqliteDB: Use ECollator

Now check the ESourceBackendSummarySetup extension for custom collations,
use a default ECollator for the current locale for every contact field
unless a custom collation is specified, if a custom collation is specified
for a given field then use a special ECollator to sort that field.

11 years agoRevert "ESourceBackendSummarySetup: Added apis to set collation rules on addressbooks."
Tristan Van Berkom [Fri, 17 May 2013 11:17:04 +0000 (20:17 +0900)]
Revert "ESourceBackendSummarySetup: Added apis to set collation rules on addressbooks."

This reverts commit 6a30b3f5164b782e6d0c1194930fd854fdb43a3d.

Reverting this for now but keeping the history, apparently we do not
want a configurable collation rule for addressbook fields, but rather
an ECollator which chooses the most popular default.

11 years agoESourceBackendSummarySetup: Added apis to set collation rules on addressbooks.
Tristan Van Berkom [Fri, 3 May 2013 09:59:36 +0000 (18:59 +0900)]
ESourceBackendSummarySetup: Added apis to set collation rules on addressbooks.

11 years agoECollator: Remove the "collation_type" option.
Tristan Van Berkom [Fri, 17 May 2013 11:15:53 +0000 (20:15 +0900)]
ECollator: Remove the "collation_type" option.

Instead ECollator will try to make a best guess at what
type of collation is desired for a given language

11 years agoAdded utility ECollator to libedataserver.
Tristan Van Berkom [Tue, 30 Apr 2013 07:09:35 +0000 (16:09 +0900)]
Added utility ECollator to libedataserver.

The ECollator API wraps up the required ICU APIs into something more
convenient for usage in EDS.

11 years agoAdded detection of ICU libs to configure.ac
Tristan Van Berkom [Fri, 26 Apr 2013 12:29:31 +0000 (21:29 +0900)]
Added detection of ICU libs to configure.ac

11 years agoECalClient tests: Use async apis to open the client for every async test.
Tristan Van Berkom [Wed, 24 Apr 2013 08:48:42 +0000 (17:48 +0900)]
ECalClient tests: Use async apis to open the client for every async test.

11 years agoEBookClient tests: Use async apis to open the client for every async test.
Tristan Van Berkom [Wed, 24 Apr 2013 08:18:06 +0000 (17:18 +0900)]
EBookClient tests: Use async apis to open the client for every async test.

11 years agotest-utils: Added argumement to the fixture closure data to open async
Tristan Van Berkom [Wed, 24 Apr 2013 07:56:02 +0000 (16:56 +0900)]
test-utils: Added argumement to the fixture closure data to open async

If a closure specifies async then the EBookClient or ECalClient will be
opened using async APIs instead of sync APIs.

11 years agoAdded e_book_client_connect_direct() and e_book_client_connect_direct_finish()
Tristan Van Berkom [Mon, 27 May 2013 11:59:30 +0000 (20:59 +0900)]
Added e_book_client_connect_direct() and e_book_client_connect_direct_finish()

11 years agotest-client-custom-summary.c: Added tests for regex queries
Tristan Van Berkom [Fri, 10 May 2013 08:23:16 +0000 (17:23 +0900)]
test-client-custom-summary.c: Added tests for regex queries

11 years agotest-client-custom-summary.c: Optimize test.
Tristan Van Berkom [Tue, 23 Apr 2013 10:30:51 +0000 (19:30 +0900)]
test-client-custom-summary.c: Optimize test.

Reuse the same two addressbooks for every test, so that only the
first 2 tests populate the addressbooks with contacts and the remaining
tests only create a client and execute a query.

Also add all test contacts with a single batch command and dont fetch
the test contacts, also removed the #if 0'd case which is the only
case which required the local contact copies.

11 years agotest-server-utils: Allow reuse of existing addressbook.
Tristan Van Berkom [Fri, 19 Apr 2013 10:48:08 +0000 (19:48 +0900)]
test-server-utils: Allow reuse of existing addressbook.

If committing the new scratch source ends with an error that
the addressbook/calendar already exists, then just use the existing
source instead of bailing out.

This is needed for tests which reuse the addressbook from a previous test.

Conflicts:

tests/test-server-utils/e-test-server-utils.c

11 years agoEBookBackendSqliteDB: Support regex queries
Tristan Van Berkom [Tue, 23 Apr 2013 08:36:47 +0000 (17:36 +0900)]
EBookBackendSqliteDB: Support regex queries

E_BOOK_QUERY_REGEX_NORMAL is supported in summary queries if the
query field is summarized, E_BOOK_QUERY_REGEX_RAW and normalized
but non-summarized queries are delegated to EBookBackendSexp for
matching.

11 years agoEBookBackendSexp: Support regex query types.
Tristan Van Berkom [Tue, 23 Apr 2013 08:35:54 +0000 (17:35 +0900)]
EBookBackendSexp: Support regex query types.

11 years agoEBookQuery: Added regex query API.
Tristan Van Berkom [Tue, 23 Apr 2013 08:34:54 +0000 (17:34 +0900)]
EBookQuery: Added regex query API.

Added E_BOOK_QUERY_REGEX_NORMAL and E_BOOK_QUERY_REGEX_RAW

11 years agoAdded tests to ensure that localized data is properly migrated.
Tristan Van Berkom [Fri, 19 Apr 2013 10:49:38 +0000 (19:49 +0900)]
Added tests to ensure that localized data is properly migrated.

The added tests must run in the order specified in the Makefile:
  o test-sqlite-cursor-posix-initial

    Creates an addressbook sorted in POSIX locale and asserts that
    contacts are sorted in basic POSIX locale

  o test-sqlite-cursor-en-US-migrated

    Loads the existing address book in en_US-UTF-8 locale and asserts
    that contacts are sorted in the en_US-UTF-8 locale

  o test-sqlite-cursor-posix-migrated

    Loads the existing address book in POSIX locale again and asserts
    that contacts are sorted in the POSIX locale

11 years agoAdded test case test-sqlite-cursor-set-sexp.c
Tristan Van Berkom [Wed, 17 Apr 2013 11:34:44 +0000 (20:34 +0900)]
Added test case test-sqlite-cursor-set-sexp.c

This test verifies that invalid queries are rejected, and that a cursor
position is changed by the new sexp with the correct new filtered values
after applying a filter (sexp) to the cursor.

11 years agoAdded test case test-sqlite-cursor-calculate.c
Tristan Van Berkom [Wed, 17 Apr 2013 10:37:04 +0000 (19:37 +0900)]
Added test case test-sqlite-cursor-calculate.c

This test verifies that e_book_backend_sqlitedb_cursor_calculate() report
the right position and total values when the cursor is moved, after the
target is set, after the addressbook is modified, for filtered and unfiltered
result sets.

11 years agoAdded test case test-sqlite-cursor-set-target.c
Tristan Van Berkom [Tue, 16 Apr 2013 11:32:35 +0000 (20:32 +0900)]
Added test case test-sqlite-cursor-set-target.c

This test case tests e_book_backend_sqlitedb_cursor_set_target().

The special case of setting a partial state is tested so that when
a cursor is setup to sort by "family_name, given_name" and the target
is set to "J", then we recieve results inclusive of the contact with
the family name "J".

11 years agoAdded test case test-sqlite-cursor-move-by
Tristan Van Berkom [Mon, 15 Apr 2013 11:46:01 +0000 (20:46 +0900)]
Added test case test-sqlite-cursor-move-by

This test case asserts that e_book_backend_sqlite_cursor_move_by()
works as expected. Consequently, a hand full of additional test
vcards were added for this.

11 years agoAdded test case test-sqlite-create-cursor
Tristan Van Berkom [Mon, 15 Apr 2013 11:53:29 +0000 (20:53 +0900)]
Added test case test-sqlite-create-cursor

The new test case verifies that cursor creation is well protected
(cursor creation is denied for some queries and ordering requests).

11 years agoAdded libedata-book test directory and added first test.
Tristan Van Berkom [Fri, 12 Apr 2013 06:37:27 +0000 (15:37 +0900)]
Added libedata-book test directory and added first test.

In this new directory we can add tests for libedata-book backend
components, currently there is a custom fixture which opens an
EBookBackendSqliteDB on the same addressbook that an EBookClient
opens, to test EBookBackendSqliteDB APIs directly on the addressbook.

Conflicts:

tests/Makefile.am

11 years agoEBookBackendSqliteDB: Adding cursor APIs
Tristan Van Berkom [Mon, 22 Apr 2013 11:42:14 +0000 (20:42 +0900)]
EBookBackendSqliteDB: Adding cursor APIs

Added the following APIs:

      o e_book_backend_sqlitedb_cursor_new()

        Creates a cursor for a given query expression and sort order

      o e_book_backend_sqlitedb_cursor_free()

        Frees a cursor and it's resources

      o e_book_backend_sqlitedb_cursor_move_by()

        Moves the cursor and fetches results

      o e_book_backend_sqlitedb_cursor_set_target()

        Sets the cursor state to a given position in the results

      o e_book_backend_sqlite_cursor_calculate()

        Calculates the position / total values of a cursor.

      o e_book_backend_sqlitedb_cursor_set_sexp()

        Sets the search expression for a given cursor

Also restored DB overwrite when country code changes.

11 years agotest-server-utils: Add e_test_server_utils_run_full()
Mathias Hasselmann [Tue, 5 Mar 2013 10:03:24 +0000 (11:03 +0100)]
test-server-utils: Add e_test_server_utils_run_full()

Basically this is to tell e_test_server_utils_run() to not
wipe the working directory before start.

Conflicts:

tests/test-server-utils/e-test-server-utils.h

11 years agolibedataserver: Fix some documentation typos.
Matthew Barnes [Fri, 24 May 2013 17:19:47 +0000 (13:19 -0400)]
libedataserver: Fix some documentation typos.

(cherry picked from commit 1e8be12632b44e9cae764c82cae8fc8c761f096b)

11 years agoBug 699909 — Do not use toggle_refs in CamelObjectBag
David Woodhouse [Fri, 10 May 2013 20:13:35 +0000 (21:13 +0100)]
Bug 699909 — Do not use toggle_refs in CamelObjectBag

They are broken and not thread-safe. Use GWeakRef instead to fix the
original problem that they were introduced to fix (bug 638810).
(cherry picked from commit 87b365d99c2d1f5d366d1432a6422db8fdc45d0b)

11 years agoImprove error handling in imapx_command_fetch_message_done().
Matthew Barnes [Tue, 21 May 2013 18:54:33 +0000 (14:54 -0400)]
Improve error handling in imapx_command_fetch_message_done().

Spotted a few execution paths where we claim success but have no
stream object for the fetched message.

(cherry picked from commit 8e239df91382e0950e75d2231de3bbd0e39e6e4b)

11 years agocamel_imapx_command_set_error_if_failed() minor cleanup.
Matthew Barnes [Tue, 21 May 2013 18:32:44 +0000 (14:32 -0400)]
camel_imapx_command_set_error_if_failed() minor cleanup.

(cherry picked from commit f6de223967143aae8732bf88a7643bcd49eae27a)

11 years agoMake CamelNNTPStore a bit more thread-safe.
Matthew Barnes [Tue, 21 May 2013 02:48:40 +0000 (22:48 -0400)]
Make CamelNNTPStore a bit more thread-safe.

* Make CamelNNTPStore's public members private.

* Guard the private CamelNNTPStore members with a mutex.

* Add thread-safe accessors:

    camel_nntp_store_ref_cache()
    camel_nntp_store_ref_stream()
    camel_nntp_store_ref_summary()
    camel_nntp_store_get_current_group()
    camel_nntp_store_dup_current_group()
    camel_nntp_store_set_current_group()
    camel_nntp_store_add_capabilities()
    camel_nntp_store_has_capabilities()
    camel_nntp_store_remove_capabilities()

(cherry picked from commit fbf1ac4ac492951a3d6877e73961004741a0591c)

11 years agoCamelNNTPStore: Remove unused "password_reprompt" flag.
Matthew Barnes [Tue, 21 May 2013 17:26:21 +0000 (13:26 -0400)]
CamelNNTPStore: Remove unused "password_reprompt" flag.

(cherry picked from commit 5d6f055cd0ce49c2406e689822e2c9ae6c44e554)

11 years agoCamelNNTPStore: Remove unused "posting_allowed" flag.
Matthew Barnes [Tue, 21 May 2013 17:25:48 +0000 (13:25 -0400)]
CamelNNTPStore: Remove unused "posting_allowed" flag.

(cherry picked from commit c9342840ead4c6b7cdb2d85f5573b6ea8d3492d3)

11 years agoCamelNNTPStore: Remove unused "extensions" flags.
Matthew Barnes [Tue, 21 May 2013 17:25:07 +0000 (13:25 -0400)]
CamelNNTPStore: Remove unused "extensions" flags.

(cherry picked from commit 96c1aca7d1f0b716a42f1cb44236313567f3951f)

11 years agoCamelNNTPStore: Remove CamelMemStream member.
Matthew Barnes [Tue, 21 May 2013 00:57:01 +0000 (20:57 -0400)]
CamelNNTPStore: Remove CamelMemStream member.

It's just used for assembling command strings.  Use a GString instead,
and for heaven sake don't make it a public member!  That's not thread-
safe at all.

(cherry picked from commit d3f5679d45d646eddd6aae54883e0996a473dfd6)

11 years agoMake CamelPOP3Store a bit more thread-safe.
Matthew Barnes [Mon, 20 May 2013 21:43:46 +0000 (17:43 -0400)]
Make CamelPOP3Store a bit more thread-safe.

* Make CamelPOP3Store's cache and engine members private.

* Guard the private cache and engine members with a mutex.

* Add thread-safe accessors which return a new reference:

    camel_pop3_store_ref_cache()
    camel_pop3_store_ref_engine()

TODO: CamelPOP3Engine itself should also be made thread-safe, but that
      will be considerably more work.  This commit merely prevents the
      CamelPOP3Engine from being finalized while still in use.

(cherry picked from commit 0338a31f78160beadaba421698c79635737c6b8c)

11 years agoBug 699597 - Autocomplete using GAL is slow
David Woodhouse [Mon, 20 May 2013 13:14:24 +0000 (14:14 +0100)]
Bug 699597 - Autocomplete using GAL is slow

With large addressbooks, using an inner join which produces hundreds of
thousands of duplicate results, and then filtering them back down to what
we really wanted with 'DISTINCT' is really inefficient. I can't even tell
you *how* inefficient, because it didn't complete a single query in the
hours that I left it running. Switch it to a more sensible outer join and
it completes in a second or so on my 216000-entry address book.
(cherry picked from commit fcc0c4c89dcb01329d76f9a826dc9cb7f3d346a6)

11 years agoCamelGpgContext: Report decrypt error only if no data was decrypted
Milan Crha [Thu, 16 May 2013 14:15:05 +0000 (16:15 +0200)]
CamelGpgContext: Report decrypt error only if no data was decrypted

When there is a message which is both signed and encrypted in once,
the gpg checks also signature of the sender, and if the sender's key
is not available between user's keys, or it's not trusted, or
the signature is otherwise incorrect, then the gpg returns failure,
which caused no data returned, though the decrypt itself worked
flawlessly.

11 years agoupdated kn translations
Shankar Prasad [Tue, 14 May 2013 09:13:56 +0000 (14:43 +0530)]
updated kn translations

11 years agoUpdated Russian translation
Yuri Myasoedov [Mon, 13 May 2013 18:41:55 +0000 (22:41 +0400)]
Updated Russian translation

11 years agoCamel MH provider can deadlock on folder creation
Milan Crha [Mon, 13 May 2013 17:11:46 +0000 (19:11 +0200)]
Camel MH provider can deadlock on folder creation

This was reported downstream as [1]. The MH provider can deadlock
during folder creation, because it tries to get a new CamelFolder
instance for a folder it is currently creating, which makes
the CamelObjectBag of CamelFolder-s wait for itself.

[1] https://bugzilla.redhat.com/show_bug.cgi?id=854017

11 years agoBug #699811 - Moved IMAPx messages reappear
Milan Crha [Mon, 13 May 2013 14:29:58 +0000 (16:29 +0200)]
Bug #699811 - Moved IMAPx messages reappear

This affected users whom had configured a real Trash folder.

11 years agoUpdated Norwegian bokmål translation
Kjartan Maraas [Mon, 13 May 2013 08:22:32 +0000 (10:22 +0200)]
Updated Norwegian bokmål translation

11 years agoPost-release version bump.
Matthew Barnes [Sun, 12 May 2013 13:51:26 +0000 (09:51 -0400)]
Post-release version bump.

11 years agoNEWS update for 3.8.2 release.
Matthew Barnes [Sun, 12 May 2013 13:22:12 +0000 (09:22 -0400)]
NEWS update for 3.8.2 release.

11 years agoIMAPX: Support IMAP MOVE extension.
Matthew Barnes [Wed, 8 May 2013 17:30:18 +0000 (13:30 -0400)]
IMAPX: Support IMAP MOVE extension.

http://tools.ietf.org/rfc/rfc6851

(cherry picked from commit e2355e318a87f4512c789026f998598249ab030f)

11 years agoIMAPX: Add macros for checking server capabilities.
Matthew Barnes [Wed, 8 May 2013 16:20:11 +0000 (12:20 -0400)]
IMAPX: Add macros for checking server capabilities.

These just read better and are more compact.

    CAMEL_IMAPX_HAVE_CAPABILITY(cinfo, capa)
    CAMEL_IMAPX_LACK_CAPABILITY(cinfo, capa)

Both macros evaluate to FALSE if 'cinfo' is NULL.

(cherry picked from commit 6f935fd146476048b80b1f42e5176a587dc106d4)

11 years agoBug 697859 - Google: "Other Fax" is saved as "Business Fax"
Matthew Barnes [Wed, 8 May 2013 14:48:03 +0000 (10:48 -0400)]
Bug 697859 - Google: "Other Fax" is saved as "Business Fax"

The gd:phoneNumber @rel value "http://schemas.google.com/g/2005#fax"
has no clear mapping to an EContact field.

Both it and "http://schemas.google.com/g/2005#other_fax" end up in a
vCard as TEL;TYPE=fax.  But because of the conversion table ordering,
TEL;TYPE=fax was being saved as "#fax" instead of "#other_fax".

Then when reading the contact back from Google, I guess some fallback
logic somewhere was converting "#fax" to "TEL;TYPE="work,fax".  Never
found exactly where that was happening.  Maybe in the Contact Editor?

This commit reorders the conversion table to prefer "#other_fax" over
"#fax".  There's still a conflict where if a Google contact specifies
both "#fax" and "#other_fax" one of the fax numbers may be lost.  But
honestly, who has that many fax machines nowadays?

(cherry picked from commit e40b88b4e1b7c90cf0490cbca08c7912583eebc4)

11 years agoCoding style and whitespace cleanup.
Matthew Barnes [Wed, 8 May 2013 13:14:53 +0000 (09:14 -0400)]
Coding style and whitespace cleanup.

11 years agoECalBackendWeather: e_weather_source_new() is failable.
Matthew Barnes [Tue, 7 May 2013 17:51:37 +0000 (13:51 -0400)]
ECalBackendWeather: e_weather_source_new() is failable.

Backend logic was failing to take this into account and crashing if the
weather location code in the ESource was invalid.

I'm not sure if EWeatherSource is even worth keeping around, but I'll
come back to that later.  Not doing an all-out rewrite at the moment.

(cherry picked from commit ef17c11c438c390378130ae942d81d6feb65405d)

11 years agoEWeatherSource cleanups.
Matthew Barnes [Tue, 7 May 2013 16:18:47 +0000 (12:18 -0400)]
EWeatherSource cleanups.

(cherry picked from commit 7bd54b6fd0a53d83907bcff6f88c5613342d0934)

11 years agoBug 699024 - [google/yahoo] Don't override username
Matthew Barnes [Mon, 6 May 2013 14:02:41 +0000 (10:02 -0400)]
Bug 699024 - [google/yahoo] Don't override username

When mail child sources are added to a google or yahoo collection, avoid
overriding an existing user name setting.  The IMAP or (especially) SMTP
configuration may have been modified to use a non-Google/Yahoo! server.

(cherry picked from commit 49da63819f2c4da465758210fea325f6efa1e7b6)

11 years agoECalClientView: Make D-Bus signal handlers thread-safe.
Matthew Barnes [Sat, 4 May 2013 13:44:00 +0000 (09:44 -0400)]
ECalClientView: Make D-Bus signal handlers thread-safe.

Seeing crashes now where handler functions for D-Bus signals like
"objects-added" are receiving finalized ECalClientView instances.
Possibly a side-effect of recent changes to GMainContext usage.

Use the trick of passing an allocated GWeakRef along with a suitable
GClosureNotify to g_signal_connect_data().  The handler function will
just return quietly if it can't obtain a strong client view reference.

(cherry picked from commit b255406dd249327efdb133e2c797b4dd496c736b)

Conflicts:
calendar/libecal/e-cal-client-view.c

11 years agoEBookClientView: Make D-Bus signal handlers thread-safe.
Matthew Barnes [Sat, 4 May 2013 14:32:36 +0000 (10:32 -0400)]
EBookClientView: Make D-Bus signal handlers thread-safe.

Seeing crashes now where handler functions for D-Bus signals like
"objects-added" are receiving finalized EBookClientView instances.
Possibly a side-effect of recent changes to GMainContext usage.

Use the trick of passing an allocated GWeakRef along with a suitable
GClosureNotify to g_signal_connect_data().  The handler function will
just return quietly if it can't obtain a strong client view reference.

(cherry picked from commit 2df7a66eb535863dc41db446afc67ca4e0268c12)

Conflicts:
addressbook/libebook/e-book-client-view.c

11 years agoBug 699223 - Emit view signals from context where view was started
Matthew Barnes [Fri, 3 May 2013 17:14:53 +0000 (13:14 -0400)]
Bug 699223 - Emit view signals from context where view was started

This applies to both EBookClientView and ECalClientView.

Incoming D-Bus signals were being propagated to the EClient's main loop
context, but there may not be a running main loop on that thread, so the
main loop sources were never being dispatched and the view signals never
emitted.

Instead use the main loop context which was the thread-default at the
time the view was started, which is often the so-called "main" thread
where a main loop is more likely to be running.

(cherry picked from commit 417164c733128072ea3e4ad685829f0c3270c1b7)

Conflicts:
addressbook/libebook/e-book-client-view.c
calendar/libecal/e-cal-client-view.c

11 years agoIMAPX: Recognize RFC 5530 response codes.
Matthew Barnes [Thu, 2 May 2013 23:34:37 +0000 (19:34 -0400)]
IMAPX: Recognize RFC 5530 response codes.

(cherry picked from commit c6a76b8d21ffb88260e8d42bde19a8af1ea3882f)

11 years agoBug 699160 - IMAPX: Always flush debugging messages
Matthew Barnes [Thu, 2 May 2013 21:39:42 +0000 (17:39 -0400)]
Bug 699160 - IMAPX: Always flush debugging messages

Had a debugging scenario where key information was not written to a log
file until another IMAP command was issued.  Caused a bit of confusion.
This commit ensures that won't happen again.

(cherry picked from commit d22b2ec7cdf32c9904e2c19fb263750b5173f62c)

11 years agocamel_imapx_debug() cleanups.
Matthew Barnes [Thu, 2 May 2013 21:38:25 +0000 (17:38 -0400)]
camel_imapx_debug() cleanups.

(cherry picked from commit 3fbf3f2e9347643e7e72fc8e66895cd974c11f7c)

11 years agoMake camel_mime_message_dump() dump message contents
Dan Williams [Thu, 2 May 2013 20:36:22 +0000 (15:36 -0500)]
Make camel_mime_message_dump() dump message contents

Previously unimplemented.  Dumps in hex and ASCII:

class: CamelMimeMessage
mime-type: text/plain; charset="UTF-8"
content class: CamelDataWrapper
content mime-type: text/plain; charset="UTF-8"
content len 967
    4f 6e 20 54 68 75 2c 20 32 30 31 33 2d 30 35 2d    On Thu, 2013-05-
    30 32 20 61 74 20 31 34 3a 31 37 20 2d 30 35 30    02 at 14:17 -050
    30 2c 20 44 61 6e 20 57 69 6c 6c 69 61 6d 73 20    0, Dan Williams
    77 72 6f 74 65 3a 0a 3e 20 4f 6e 20 54 68 75 2c    wrote:.> On Thu,
    20 32 30 31 33 2d 30 35 2d 30 32 20 61 74 20 31     2013-05-02 at 1
    31 3a 35 33 20 2d 30 37 30 30 2c 20 4c 69 6e 75    1:53 -0700, Linu
    73 20 54 6f 72 76 61 6c 64 73 20 77 72 6f 74 65    s Torvalds wrote
    3a 0a 3e 20 3e 20 4f 6e 20 54 68 75 2c 20 4d 61    :.> > On Thu, Ma
    79 20 32 2c 20 32 30 31 33 20 61 74 20 31 31 3a    y 2, 2013 at 11:

(02:09:38 PM) mbarnes: dcbw: nice, I forgot about camel_mime_message_dump() -- go ahead and commit that

(cherry picked from commit f69531d1bca0ddf379b1da9516e302d2325bd31b)

11 years agoBug 699461 - Accept any 2xx HTTP code as successful DELETE
Matthew Barnes [Thu, 2 May 2013 18:48:28 +0000 (14:48 -0400)]
Bug 699461 - Accept any 2xx HTTP code as successful DELETE

(cherry picked from commit c80a95cd1bf12438bedac1b1b492c5719cbc901b)

11 years agoESource: Fix a compiler warning.
Matthew Barnes [Thu, 2 May 2013 12:55:40 +0000 (08:55 -0400)]
ESource: Fix a compiler warning.

(cherry picked from commit fa2da02c05c06bc4bcd9345649a7c23817bfffd5)

11 years agoBug 698725 - ESourceRegistry: Handle service restarts gracefully
Matthew Barnes [Sun, 28 Apr 2013 01:36:46 +0000 (21:36 -0400)]
Bug 698725 - ESourceRegistry: Handle service restarts gracefully

Check GDBusObjectManagerClient's "name-owner" property when handling
"object-added" and "object-removed" signals.  If the property is NULL,
implement a strategy that swaps out the ESource's old proxy object for
an equivalent replacement such that applications should remain unaware
of the service restart.

This is important to handle gracefully not only for crash recovery, but
also when the registry service receives a Reload() method invocation or
a SIGHUP, both of which cause it to temporarily release its well-known
bus name and reload key files.

(cherry picked from commit b219dfe2d989809b4eed437b7d8bc67b14e9cc1b)

11 years agoe_source_ref_dbus_object: Use the property lock.
Matthew Barnes [Sat, 27 Apr 2013 15:18:22 +0000 (11:18 -0400)]
e_source_ref_dbus_object: Use the property lock.

ESourceRegistry is going to swap out the GDBusObject as part of the
recovery strategy for evolution-source-registry restarts, so we need
to make sure e_source_ref_dbus_object() is properly thread-safe.

(cherry picked from commit 133c0e3fe057e6bcac5339879c08649e7cdc72b5)

11 years agoESourceRegistry: object_path_table cleanups.
Matthew Barnes [Tue, 30 Apr 2013 17:52:19 +0000 (13:52 -0400)]
ESourceRegistry: object_path_table cleanups.

(cherry picked from commit 995aff9ca6760b5c0700b1250ea6064110864908)

11 years agoAdd source_registry_dbus_object_dup_uid().
Matthew Barnes [Tue, 30 Apr 2013 17:45:44 +0000 (13:45 -0400)]
Add source_registry_dbus_object_dup_uid().

Handy internal utility for ESourceRegistry.

This also happens to fix an EDBusSource reference leak in
source_registry_create_sources_object_added_cb().

(cherry picked from commit e3ea6473316091a5ed9f8a333f584dda277a2404)

11 years agohindi update
Rajesh Ranjan [Thu, 2 May 2013 08:13:57 +0000 (13:43 +0530)]
hindi update

11 years agoupdate Punjabi Translation
A S Alam [Wed, 1 May 2013 14:49:25 +0000 (20:19 +0530)]
update Punjabi Translation

11 years agoBug 699027 - Crash in e_cal_backend_file_get_backend_property()
Frederic Peters [Sun, 28 Apr 2013 13:31:57 +0000 (09:31 -0400)]
Bug 699027 - Crash in e_cal_backend_file_get_backend_property()

11 years agoEGoaClient nitpicks.
Matthew Barnes [Sat, 27 Apr 2013 13:28:13 +0000 (09:28 -0400)]
EGoaClient nitpicks.

(cherry picked from commit fdfc4c71a9c45a384d03b4b401109854d36b1e3c)

11 years agoBug 698726 - Handle goa-daemon crashes/restarts gracefully
Matthew Barnes [Sat, 27 Apr 2013 12:47:18 +0000 (08:47 -0400)]
Bug 698726 - Handle goa-daemon crashes/restarts gracefully

EGoaClient is an improved GoaClient that handles daemon crashes and
restarts gracefully so E-D-S accounts are not destroyed unnecessarily.

(cherry picked from commit 725e976e67a62bf00820c70c47a3f439811d6c0d)

11 years agoTamil Translation Updated
Shantha kumar [Thu, 25 Apr 2013 12:48:42 +0000 (18:18 +0530)]
Tamil Translation Updated

11 years agoImprove error handling in imapx_server_get_message().
Matthew Barnes [Wed, 24 Apr 2013 14:09:09 +0000 (10:09 -0400)]
Improve error handling in imapx_server_get_message().

If a GET_MESSAGE job for the same UID is already in progress, wait for
the job to finish, but don't assume it was successful.  Try retrieving
the message from cache, but if that fails then we have to re-fetch the
message from the IMAP server.

(cherry picked from commit cb048105f08625cf504bd8a539cafeccc92ba89e)

11 years agoUpdated gujarati file
Sweta Kothari [Wed, 24 Apr 2013 08:50:54 +0000 (14:20 +0530)]
Updated gujarati file

11 years agoDo not consider PGP and S/MIME subparts as attachments
Milan Crha [Wed, 24 Apr 2013 06:54:12 +0000 (08:54 +0200)]
Do not consider PGP and S/MIME subparts as attachments

11 years ago[l10n] Updated Catalan (Valencian) translation
Carles Ferrando [Fri, 19 Apr 2013 22:28:48 +0000 (00:28 +0200)]
[l10n] Updated Catalan (Valencian) translation

11 years ago[l10n] Update Catalan translation
Gil Forcada [Fri, 19 Apr 2013 22:28:29 +0000 (00:28 +0200)]
[l10n] Update Catalan translation

11 years agobuild: Fix srcdir != builddir from git
Colin Walters [Fri, 12 Apr 2013 13:23:53 +0000 (09:23 -0400)]
build: Fix srcdir != builddir from git

We can't do (cd $(srcdir); ...) and inside reference $(top_srcdir)
because that variable uses a *relative* path.  Thus we copy the
approach from gnome-shell of explicitly using addprefix to append the
source directory.

(cherry picked from commit fb9b02e43251b7f4004eb41791f0a3553eeb2b4c)

11 years agoBug #698261 - Skip invalid flags in imapx_parse_flags()
Milan Crha [Thu, 18 Apr 2013 12:16:15 +0000 (14:16 +0200)]
Bug #698261 - Skip invalid flags in imapx_parse_flags()

Previous patch had incorrectly implemented skip of the broken flag,
which fixes this change.

11 years agoBug #698261 - Skip invalid flags in imapx_parse_flags()
Milan Crha [Thu, 18 Apr 2013 10:27:55 +0000 (12:27 +0200)]
Bug #698261 - Skip invalid flags in imapx_parse_flags()

11 years agoCamelStoreSettings::filter-inbox: Change default to TRUE
Milan Crha [Thu, 18 Apr 2013 06:36:07 +0000 (08:36 +0200)]
CamelStoreSettings::filter-inbox: Change default to TRUE