r20130 - gnucash/trunk/src/optional/python-bindings - Remove old obsolete unused file from python wrappers.
Christian Stimming
cstim at code.gnucash.org
Thu Jan 20 15:15:02 EST 2011
Author: cstim
Date: 2011-01-20 15:15:02 -0500 (Thu, 20 Jan 2011)
New Revision: 20130
Trac: http://svn.gnucash.org/trac/changeset/20130
Removed:
gnucash/trunk/src/optional/python-bindings/glib.i
Modified:
gnucash/trunk/src/optional/python-bindings/Makefile.am
Log:
Remove old obsolete unused file from python wrappers.
Apparently this is unused since r17284.
Modified: gnucash/trunk/src/optional/python-bindings/Makefile.am
===================================================================
--- gnucash/trunk/src/optional/python-bindings/Makefile.am 2011-01-20 20:14:51 UTC (rev 20129)
+++ gnucash/trunk/src/optional/python-bindings/Makefile.am 2011-01-20 20:15:02 UTC (rev 20130)
@@ -95,8 +95,7 @@
example_scripts/change_tax_code.py \
example_scripts/account_analysis.py \
example_scripts/new_book_with_opening_balances.py \
- example_scripts/test_imbalance_transaction.py \
- glib.i
+ example_scripts/test_imbalance_transaction.py
MAINTAINERCLEANFILES = gnucash_core.c
Deleted: gnucash/trunk/src/optional/python-bindings/glib.i
===================================================================
--- gnucash/trunk/src/optional/python-bindings/glib.i 2011-01-20 20:14:51 UTC (rev 20129)
+++ gnucash/trunk/src/optional/python-bindings/glib.i 2011-01-20 20:15:02 UTC (rev 20130)
@@ -1,122 +0,0 @@
-/*
- * glib.i -- SWIG interface file for type translation of glib types
- *
- * Copyright (C) 2008 ParIT Worker Co-operative <paritinfo at parit.ca>
- *
- * This program 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 2 of
- * the License, or (at your option) any later version.
- *
- * This program 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, contact:
- *
- * Free Software Foundation Voice: +1-617-542-5942
- * 51 Franklin Street, Fifth Floor Fax: +1-617-542-2652
- * Boston, MA 02110-1301, USA gnu at gnu.org
- *
- * @author Mark Jenkins, ParIT Worker Co-operative <mark at parit.ca>
- */
-/** @file
- @brief SWIG interface file for type translation of glib types
- This file may be obsolete, because the same definitions are also in base-typemaps.i.
- @author Mark Jenkins, ParIT Worker Co-operative <mark at parit.ca>
- @author Jeff Green, ParIT Worker Co-operative <jeff at parit.ca>
- @ingroup python_bindings */
-
-
-%typemap(in) gint8, gint16, gint32, gint64, gint, gshort, glong {
- $1 = ($1_type)PyInt_AsLong($input);
-}
-
-%typemap(out) gint8, gint16, gint32, gint64, gint, gshort, glong {
- $result = PyInt_FromLong($1);
-}
-
-%typemap(in) guint8, guint16, guint32, guint64, guint, gushort, gulong {
- $1 = ($1_type)PyLong_AsUnsignedLong($input);
-}
-
-%typemap(out) guint8, guint16, guint32, guint64, guint, gushort, gulong {
- $result = PyLong_FromUnsignedLong($1);
-}
-
-%typemap(in) gfloat, gdouble {
- $1 = ($1_type)PyFloat_AsDouble($input);
-}
-
-%typemap(out) gfloat, gdouble {
- $result = PyFloat_FromDouble($1);
-}
-
-%typemap(in) gchar * {
- $1 = ($1_type)PyString_AsString($input);
-}
-
-%typemap(out) gchar * {
- $result = PyString_FromString($1);
-}
-
-%typemap(in) gboolean {
- if ($input == Py_True)
- $1 = TRUE;
- else if ($input == Py_False)
- $1 = FALSE;
- else
- {
- PyErr_SetString(
- PyExc_ValueError,
- "Python object passed to a gboolean argument was not True "
- "or False" );
- return NULL;
- }
-}
-
-%typemap(out) gboolean {
- if ($1 == TRUE)
- {
- Py_INCREF(Py_True);
- $result = Py_True;
- }
- else if ($1 == FALSE)
- {
- Py_INCREF(Py_False);
- $result = Py_False;
- }
- else
- {
- PyErr_SetString(
- PyExc_ValueError,
- "function returning gboolean returned a value that wasn't "
- "TRUE or FALSE.");
- return NULL;
- }
-}
-
-%typemap(out) GList *, CommodityList *, SplitList *, AccountList *, LotList * {
- guint i;
- gpointer data;
- PyObject *list = PyList_New(0);
- for (i = 0; i < g_list_length($1); i++)
- {
- data = g_list_nth_data($1, i);
- if (GNC_IS_ACCOUNT(data))
- PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
- else if (GNC_IS_SPLIT(data))
- PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
- else if (GNC_IS_TRANSACTION(data))
- PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
- else if (GNC_IS_COMMODITY(data))
- PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
- else if (GNC_IS_LOT(data))
- PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
- else
- PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gpointer, 0));
- }
- $result = list;
-}
More information about the gnucash-changes
mailing list