summaryrefslogtreecommitdiffstats
path: root/toolkit/components/search/components.conf
blob: f6b21e01ff0f1d51774dc328d81d3929d3bfe638 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
# vim: set filetype=python:
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

HAVE_SIDEBAR = buildconfig.substs['MOZ_BUILD_APP'] in ('browser', 'mobile/android', 'xulrunner')

Classes = [
    {
        'js_name': 'search',
        'cid': '{7319788a-fe93-4db3-9f39-818cf08f4256}',
        'contract_ids': ['@mozilla.org/browser/search-service;1'],
        'interfaces': ['nsISearchService'],
        'jsm': 'resource://gre/modules/SearchService.jsm',
        'constructor': 'SearchService',
        'processes': ProcessSelector.MAIN_PROCESS_ONLY,
    },
    {
        'cid': '{aa892eb4-ffbf-477d-9f9a-06c995ae9f27}',
        'contract_ids': ['@mozilla.org/autocomplete/search;1?name=search-autocomplete'],
        'jsm': 'resource://gre/modules/SearchSuggestions.jsm',
        'constructor': 'SearchSuggestAutoComplete',
    },
]

if HAVE_SIDEBAR:
    Classes += [
        {
            'cid': '{22117140-9c6e-11d3-aaf1-00805f8a4905}',
            'contract_ids': ['@mozilla.org/sidebar;1'],
            'jsm': 'resource://gre/modules/Sidebar.jsm',
            'constructor': 'nsSidebar',
        },
    ]