+++ /dev/null
-#
-# Copyright (c) 2008 INdT - Instituto Nokia de Tecnologia
-#
-# This file is part of python-purple.
-#
-# python-purple is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# python-purple is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY = None without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-#
-
-cdef extern from "libpurple/core.h":
- ctypedef struct PurpleCoreUiOps:
- void (*ui_prefs_init) ()
- void (*debug_ui_init) ()
- void (*ui_init) ()
- void (*quit) ()
- GHashTable* (*get_ui_info) ()
-
- cdef gboolean c_purple_core_init "purple_core_init" (const_char_ptr ui)
- cdef void c_purple_core_quit "purple_core_quit" ()
- cdef gboolean c_purple_core_migrate "purple_core_migrate" ()
- cdef void c_purple_core_set_ui_ops "purple_core_set_ui_ops" (PurpleCoreUiOps *ops)
-
-""" CoreUiOps class """
-__core_uiops = None
-
-cdef void ui_prefs_init():
- global __core_uiops
- if __core_uiops and __core_uiops.ui_prefs_init:
- __core_uiops.ui_prefs_init()
-
-cdef void debug_ui_init():
- global __core_uiops
- if __core_uiops and __core_uiops.debug_ui_init:
- __core_uiops.debug_ui_init()
-
-cdef void ui_init():
- global __core_uiops
- if __core_uiops and __core_uiops.ui_init:
- __core_uiops.ui_init()
-
-cdef void quit():
- global __core_uiops
- if __core_uiops and __core_uiops.quit:
- __core_uiops.quit()
-
-cdef GHashTable *get_ui_info():
- global __core_uiops
- if __core_uiops and __core_uiops.get_ui_info:
- __core_uiops.get_ui_info()
-
-
-class CoreUiOps(object):
- def __init__(self):
- self.ui_prefs_init = None
- self.debug_ui_init = None
- self.ui_init = None
- self.quit = None
- self.get_ui_info = None
-
-
-def core_set_ui_ops(core_uiops):
- global __core_uiops
- cdef PurpleCoreUiOps c_core_uiops
-
- c_core_uiops.ui_prefs_init = ui_prefs_init
- c_core_uiops.debug_ui_init = debug_ui_init
- c_core_uiops.ui_init = ui_init
- c_core_uiops.quit = quit
- c_core_uiops.get_ui_info = get_ui_info
-
- __core_uiops = core_uiops
-
- c_purple_core_set_ui_ops(&c_core_uiops)
-
-def core_init(ui):
- c_purple_core_init(ui)
-
+++ /dev/null
-#
-# Copyright (c) 2008 INdT - Instituto Nokia de Tecnologia
-#
-# This file is part of python-purple.
-#
-# python-purple is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# python-purple is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-#
-
-cdef extern from "libpurple/eventloop.h":
- ctypedef struct PurpleEventLoopUiOps:
- pass
-
- void c_purple_eventloop_set_ui_ops "purple_eventloop_set_ui_ops" (PurpleEventLoopUiOps *ops)
-
-class EventLoop(object):
- """ EventLoop class """
-
- def __init__(self):
- purple_eventloop_ui_ops = None
-
- # FIXME
- """
- def purple_eventloop_set_ui_ops(ops):
- c_purple_eventloop_set_ui_ops(ops)
- """
+++ /dev/null
-#
-# Copyright (c) 2008 INdT - Instituto Nokia de Tecnologia
-#
-# This file is part of python-purple.
-#
-# python-purple is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# python-purple is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-#
-
-cdef extern from "libpurple/idle.h":
- ctypedef struct PurpleIdleUiOps:
- pass
-
- void c_purple_idle_set_ui_ops "purple_idle_set_ui_ops" (PurpleIdleUiOps *ops)
-
-class Idle(object):
- """ Idle class """
-
- def __init__(self):
- purple_idle_ui_ops = None
-
- # FIXME
- """
- def purple_idle_set_ui_ops(ops)
- c_purple_idle_set_ui_ops(ops)
- """
+++ /dev/null
-#
-# Copyright (c) 2008 INdT - Instituto Nokia de Tecnologia
-#
-# This file is part of python-purple.
-#
-# python-purple is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# python-purple is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-#
-
-cdef extern from "libpurple/prefs.h":
- void c_purple_prefs_rename "purple_prefs_rename" (const_char_ptr oldname, const_char_ptr newname)
- const_char_ptr c_purple_prefs_get_string "purple_prefs_get_string" (const_char_ptr name)
- gboolean c_purple_prefs_load "purple_prefs_load" ()
-
-class Prefs(object):
- """ Prefs class """
-
- def __init__(self):
- pass
-
- def purple_prefs_rename(old_name, new_name):
- c_purple_prefs_rename(old_name, new_name)
-
- def purple_prefs_get_string(name):
- return c_purple_prefs_get_string(name)
-
- def purple_prefs_load():
- return c_purple_prefs_load()
--- /dev/null
+#
+# Copyright (c) 2008 INdT - Instituto Nokia de Tecnologia
+#
+# This file is part of python-purple.
+#
+# python-purple is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# python-purple is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+#
+
+cdef extern from "libpurple/idle.h":
+ ctypedef struct PurpleIdleUiOps:
+ pass
+
+ void c_purple_idle_set_ui_ops "purple_idle_set_ui_ops" (PurpleIdleUiOps *ops)
include "libpurple/core.pxd"
include "libpurple/debug.pxd"
include "libpurple/eventloop.pxd"
+include "libpurple/idle.pxd"
include "libpurple/plugin.pxd"
include "libpurple/pounce.pxd"
include "libpurple/prefs.pxd"
conn = Connection()
conn.connect()
-include "core/account.pxd"
-#include "core/blist.pxd"
-include "core/buddy.pxd"
-include "core/connection.pxd"
-include "core/conversation.pxd"
-#include "core/core.pxd"
-#include "core/idle.pxd"
-#include "core/pounce.pxd"
+include "account.pyx"
+include "buddy.pyx"
+include "connection.pyx"
+include "conversation.pyx"