~elementary-pantheon/poa-eds-bridge/say-were-desktop

« back to all changes in this revision

Viewing changes to src/Utils.vala

  • Committer: Corentin Noël
  • Date: 2014-09-03 15:34:52 UTC
  • Revision ID: corentin@elementaryos.org-20140903153452-17h43f2jnstz38y8
Now fully working.

Show diffs side-by-side

added added

removed removed

Lines of Context:
14
14
        }
15
15
    }
16
16
 
17
 
    /* This is a mapping between AgAccount provider names and
18
 
     * ESourceCollection backend names.  It requires knowledge
19
 
     * of other registry modules, possibly even from 3rd party
20
 
     * packages.
21
 
     *
22
 
     * FIXME Put the EDS backend name in the .service config
23
 
     *       files so we're not hard-coding the providers we
24
 
     *       support.  This isn't GNOME Online Accounts. */
25
 
    public static string? get_backend_name (string provider) {
26
 
        switch (provider) {
27
 
            case "google":
28
 
                return "google";
29
 
            case "microsoft":
30
 
                return "outlook";
31
 
            case "yahoo":
32
 
                return "yahoo";
33
 
            default:
34
 
                return null;
35
 
        }
36
 
    }
37
 
 
38
17
    /* Determine an appropriate service type based on
39
18
     * which extensions are present in the ESource. */
40
19
    public static string? get_service_type_from_source (E.Source source) {