File: mediaprofilesmodule.c

package info (click to toggle)
gnome-python-desktop 2.32.0%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd, stretch
  • size: 4,528 kB
  • ctags: 983
  • sloc: sh: 10,214; xml: 8,851; ansic: 3,428; python: 1,457; makefile: 664
file content (36 lines) | stat: -rw-r--r-- 771 bytes parent folder | download | duplicates (4)
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
36
/* -*- Mode: C; c-basic-offset: 4 -*- */
#ifdef HAVE_CONFIG_H
#  include "config.h"
#endif

#include <pygobject.h>
#include <pygtk/pygtk.h>

#include <profiles/gnome-media-profiles.h>

void pymediaprofiles_register_classes(PyObject *d);
extern PyMethodDef pymediaprofiles_functions[];

DL_EXPORT (void)
initmediaprofiles (void)
{
    PyObject *m, *d;
    
    gnome_media_profiles_init (gconf_client_get_default ());

    m = Py_InitModule("mediaprofiles", pymediaprofiles_functions);
    d = PyModule_GetDict(m);
    if (PyErr_Occurred())
        return;

    init_pygtk();
    if (PyErr_Occurred())
        return;
    init_pygobject();
    if (PyErr_Occurred())
        return;
    
    pymediaprofiles_register_classes(d);
    if (PyErr_Occurred())
        return;
}