Mercurial > pidgin.yaz
annotate finch/libgnt/pygnt/gntwidget.override @ 19381:8d9913d9fe5a
Get rid of compile warnings on older glib.
author | Sadrul Habib Chowdhury <imadil@gmail.com> |
---|---|
date | Thu, 23 Aug 2007 18:34:31 +0000 |
parents | bfa12b00f54b |
children | 44b4e8bd759b |
rev | line source |
---|---|
18724
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
1 /** |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
2 * pygnt- Python bindings for the GNT toolkit. |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
3 * Copyright (C) 2007 Sadrul Habib Chowdhury <sadrul@pidgin.im> |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
4 * |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
5 * gntwidget.override: overrides for generic widgets. |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
6 * |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
7 * This library is free software; you can redistribute it and/or |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
8 * modify it under the terms of the GNU Lesser General Public |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
9 * License as published by the Free Software Foundation; either |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
10 * version 2.1 of the License, or (at your option) any later version. |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
11 * |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
12 * This library is distributed in the hope that it will be useful, |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
15 * Lesser General Public License for more details. |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
16 * |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
17 * You should have received a copy of the GNU Lesser General Public |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
18 * License along with this library; if not, write to the Free Software |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
19 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
20 * USA |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
21 */ |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
22 %% |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
23 override gnt_widget_get_size args |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
24 static PyObject * |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
25 _wrap_gnt_widget_get_size(PyGObject *self) |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
26 { |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
27 PyObject *list = PyList_New(0); |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
28 int x = 0, y = 0; |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
29 |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
30 gnt_widget_get_size(GNT_WIDGET(self->obj), &x, &y); |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
31 PyList_Append(list, PyInt_FromLong((long)x)); |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
32 PyList_Append(list, PyInt_FromLong((long)y)); |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
33 |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
34 return list; |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
35 } |
bfa12b00f54b
Export gnt_widget_get_size for pygnt.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
diff
changeset
|
36 |