Skip to content

Commit 16d0c8a

Browse files
James Michael DuPontJames Michael DuPont
authored andcommitted
update
1 parent fae39b5 commit 16d0c8a

File tree

2 files changed

+59
-0
lines changed

2 files changed

+59
-0
lines changed

swig/treecode2.c.tmpl

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
/*** BEGIN file-header ***/
2+
#include "itl-gobject-enums.h"
3+
/*** END file-header ***/
4+
5+
/*** BEGIN file-production ***/
6+
/* enumerations from "@filename@" */
7+
#include "@filename@"
8+
/*** END file-production ***/
9+
10+
/*** BEGIN value-header ***/
11+
GType
12+
@enum_name@_get_type(void) {
13+
static GType enum_type_id = 0;
14+
if (G_UNLIKELY (!enum_type_id))
15+
{
16+
static const G@Type@Value values[] = {
17+
/*** END value-header ***/
18+
19+
/*** BEGIN value-production ***/
20+
{ @VALUENAME@, "@VALUENAME@", "@valuenick@" },
21+
/*** END value-production ***/
22+
23+
/*** BEGIN value-tail ***/
24+
{ 0, NULL, NULL }
25+
};
26+
enum_type_id = g_@type@_register_static (g_intern_static_string ("@EnumName@"), values);
27+
}
28+
return enum_type_id;
29+
}
30+
/*** END value-tail ***/

swig/treecode2.h.tmpl

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
/*** BEGIN file-header ***/
2+
#if !defined(INTROSPECTOR_GOBJECT_INSIDE) && !defined(INTROSPECTOR_GOBJECT_COMPILATION)
3+
#error "Only <st/st.h> can be included directly.h"
4+
#endif
5+
6+
#ifndef __ST_ENUM_TYPES_H__
7+
#define __ST_ENUM_TYPES_H__
8+
9+
#include <glib-object.h>
10+
11+
G_BEGIN_DECLS
12+
13+
/*** END file-header ***/
14+
15+
/*** BEGIN file-production ***/
16+
/* enumerations from "@filename@" */
17+
/*** END file-production ***/
18+
19+
/*** BEGIN file-tail ***/
20+
G_END_DECLS
21+
22+
#endif /* !__ST_ENUM_TYPES_H__ */
23+
/*** END file-tail ***/
24+
25+
/*** BEGIN value-header ***/
26+
GType @enum_name@_get_type (void) G_GNUC_CONST;
27+
#define INTROSPECTOR_TYPE_@ENUMSHORT@ (@enum_name@_get_type())
28+
29+
/*** END value-header ***/

0 commit comments

Comments
 (0)