summaryrefslogtreecommitdiff
path: root/packages/gtk2/src/glib/gclosure.inc
diff options
context:
space:
mode:
authormichael <michael@3ad0048d-3df7-0310-abae-a5850022a9f2>2008-08-21 07:34:06 +0000
committermichael <michael@3ad0048d-3df7-0310-abae-a5850022a9f2>2008-08-21 07:34:06 +0000
commit2509503b18031e278bbe1b16eb3af37ea5bd6bee (patch)
tree9af8e4db66750de34d09f75ccea7b5dd7e9453d1 /packages/gtk2/src/glib/gclosure.inc
parent5dda47ec2ed7fb0c99de76394fd7322d4af7fc67 (diff)
downloadfpc-2509503b18031e278bbe1b16eb3af37ea5bd6bee.tar.gz
* Patch from Paul Ishenin:
- added goption.inc with apropriate glib symbols - added gincludes.inc which contains all other include files (similar to gtk/gdk bindings and simlify inclusion into glib2.pas) - checked/corrected all the .inc files and make them follow to template used in gtk/gdk (4 sections: read_forward_definitions, read_interface_types, read_interface_rest, read_implementation) - removed from most of .inc files unneeded comments that has been taken from original glib .h files. Some of them were used by glib devels and others repeats official documentation. git-svn-id: http://svn.freepascal.org/svn/fpc/trunk@11617 3ad0048d-3df7-0310-abae-a5850022a9f2
Diffstat (limited to 'packages/gtk2/src/glib/gclosure.inc')
-rw-r--r--packages/gtk2/src/glib/gclosure.inc52
1 files changed, 17 insertions, 35 deletions
diff --git a/packages/gtk2/src/glib/gclosure.inc b/packages/gtk2/src/glib/gclosure.inc
index b28325087c..f251f0cc28 100644
--- a/packages/gtk2/src/glib/gclosure.inc
+++ b/packages/gtk2/src/glib/gclosure.inc
@@ -1,37 +1,15 @@
// included by glib2.pas
-{ -- typedefs --- }
-type
+{$IFDEF read_forward_definitions}
+{$ENDIF read_forward_definitions}
+
+//------------------------------------------------------------------------------
+
+{$IFDEF read_interface_types}
PGClosure = ^TGClosure;
PGClosureNotifyData = ^TGClosureNotifyData;
TGClosureNotify = procedure (data:gpointer; closure:PGClosure); cdecl;
-{< private > }
-{< private > }
-{< private > }
-{< private > }
-{ finalization notifiers }
-{< private > }
-{ invalidation notifiers }
-{< private > }
-{< private > }
-{< protected > }
-{< public > }
-{< public > }
-{< private > }
-{out }
-{< protected > }
-{< private > }
-{ invariants/constrains:
- - ->marshal and ->data are _invalid_ as soon as ->is_invalid==TRUE
- - invocation of all inotifiers occours prior to fnotifiers
- - order of inotifiers is random
- inotifiers may _not_ free/invalidate parameter values (e.g. ->data)
- - order of fnotifiers is random
- - each notifier may only be removed before or during its invocation
- - reference counting may only happen prior to fnotify invocation
- (in that sense, fnotifiers are really finalization handlers)
- }
TGClosure = record
flag0 : longint;
marshal : procedure (closure:PGClosure; return_value:PGValue; n_param_values:guint; param_values:PGValue; invocation_hint:gpointer;
@@ -40,8 +18,13 @@ type
notifiers : PGClosureNotifyData;
end;
+ PGCClosure = ^TGCClosure;
+ TGCClosure = record
+ closure : TGClosure;
+ callback : gpointer;
+ end;
- TGCallBackProcedure = procedure;
+ TGCallBackProcedure = procedure;
TGCallback = procedure (para1: TGCallBackProcedure); cdecl;
TGClosureMarshal = procedure (closure:PGClosure; return_value:PGValue; n_param_values:guint; param_values:PGValue; invocation_hint:gpointer;
@@ -52,7 +35,11 @@ type
notify : TGClosureNotify;
end;
+{$ENDIF read_interface_types}
+
+//------------------------------------------------------------------------------
+{$IFDEF read_interface_rest}
{ --- defines --- }
function G_CLOSURE_NEEDS_MARSHAL(closure : Pointer) : boolean;
@@ -105,12 +92,6 @@ procedure set_is_invalid(var a : TGClosure; __is_invalid : guint);
{ closure for C function calls, callback() is the user function }
-type
- PGCClosure = ^TGCClosure;
- TGCClosure = record
- closure : TGClosure;
- callback : gpointer;
- end;
{ --- prototypes --- }
@@ -144,6 +125,7 @@ procedure g_closure_invoke(closure:PGClosure; return_value:PGValue; n_param_valu
- need marshaller repo with decent aliasing to base types
- provide marshaller collection, virtually covering anything out there
}
+{$ENDIF read_interface_rest}
// included by glib2.pas