← Back to team overview

ayatana-commits team mailing list archive

[Branch ~indicator-applet-developers/evolution-indicator/trunk] Rev 76: Merge

 

Merge authors:
  Mathieu Trudel-Lapierre (mathieu-tl)
Related merge proposals:
  https://code.launchpad.net/~mathieu-tl/evolution-indicator/fix-pop/+merge/48793
  proposed by: Mathieu Trudel-Lapierre (mathieu-tl)
  review: Approve - Didier Roche (didrocks)
------------------------------------------------------------
revno: 76 [merge]
committer: Didier Roche <didier.roche@xxxxxxxxxxxxx>
branch nick: evolution-indicator
timestamp: Mon 2011-02-07 18:54:23 +0100
message:
  Merge
  Fix bug 643321: simplify and fix handling POP accounts. Setting a POP account
  to IMAP and back to POP would cause evolution to crash.
modified:
  configure.ac
  src/evolution-indicator.c


--
lp:evolution-indicator
https://code.launchpad.net/~indicator-applet-developers/evolution-indicator/trunk

Your team ayatana-commits is subscribed to branch lp:evolution-indicator.
To unsubscribe from this branch go to https://code.launchpad.net/~indicator-applet-developers/evolution-indicator/trunk/+edit-subscription
=== modified file 'configure.ac'
--- configure.ac	2011-01-14 20:33:01 +0000
+++ configure.ac	2011-02-07 15:30:00 +0000
@@ -70,6 +70,11 @@
 AC_SUBST(DEPS_CFLAGS)
 AC_SUBST(DEPS_LIBS)
 
+EVO_I18N_DOMAIN=`pkg-config --modversion evolution-plugin | sed -e 's/\(.*\)\..\+$/\1/'`
+AC_DEFINE_UNQUOTED(EVO_I18N_DOMAIN,
+                   "evolution-$EVO_I18N_DOMAIN",
+                   [Define to the translation domain for Evolution])
+
 AC_OUTPUT([
 Makefile
 data/Makefile

=== modified file 'src/evolution-indicator.c'
--- src/evolution-indicator.c	2010-10-14 12:27:45 +0000
+++ src/evolution-indicator.c	2011-02-07 15:30:00 +0000
@@ -71,7 +71,6 @@
 static GSList         *indicators = NULL;
 static gint            n_accounts = 0;
 
-static IndicateIndicator  *pop_indicator  = NULL;
 static NotifyNotification *notification   = NULL;
 static ca_context         *canberra_cxt   = NULL;
 static ca_proplist        *canberra_props = NULL;
@@ -260,9 +259,6 @@
             break;
           }
       }
-    if (!indicator && pop_indicator) /* Use pop (default) indicator */
-      indicator = pop_indicator;
-    
     if (indicator)
       {
         gint count;
@@ -603,21 +599,7 @@
                                         NULL);
 
           /* Check to see account already exists and, if not, create it */
-          if (data.url && g_str_has_prefix (data.url, "pop:"))
-            {
-              if (pop_indicator == NULL)
-                {
-                  pop_indicator = create_indicator ("pop:",
-                                                  g_dgettext ("evolution-2.28",
-                                                                "Inbox"));
-                  g_debug ("EI: New Inbox indicator");
-                }
-              indicator = pop_indicator;
-            }
-          else
-            {
-              indicator = find_indicator_for_url (indicators, data.url);
-            }
+          indicator = find_indicator_for_url (indicators, data.url);
           if (indicator)
             {
               old_list = g_slist_remove (old_list, indicator);
@@ -625,7 +607,16 @@
             }
           else
             {
-              indicator = create_indicator (data.url, data.name);
+              if (data.url && g_str_has_prefix (data.url, "pop:"))
+                {
+                  indicator = create_indicator ("pop:",
+                                                g_dgettext (EVO_I18N_DOMAIN,
+                                                            "Inbox"));
+                }
+              else
+                {
+                  indicator = create_indicator (data.url, data.name);
+                }
               indicators = g_slist_append (indicators, indicator);
 
               g_debug ("EI: New account: %s (%s)", data.name, data.url);