diff options
Diffstat (limited to 'src/fltk-widgets-groups-packed.adb')
-rw-r--r-- | src/fltk-widgets-groups-packed.adb | 33 |
1 files changed, 14 insertions, 19 deletions
diff --git a/src/fltk-widgets-groups-packed.adb b/src/fltk-widgets-groups-packed.adb index 69b6e7c..b35f75f 100644 --- a/src/fltk-widgets-groups-packed.adb +++ b/src/fltk-widgets-groups-packed.adb @@ -2,24 +2,19 @@ with - Interfaces.C, - System; - -use type - - System.Address; + Interfaces.C; package body FLTK.Widgets.Groups.Packed is procedure pack_set_draw_hook - (W, D : in System.Address); + (W, D : in Storage.Integer_Address); pragma Import (C, pack_set_draw_hook, "pack_set_draw_hook"); pragma Inline (pack_set_draw_hook); procedure pack_set_handle_hook - (W, H : in System.Address); + (W, H : in Storage.Integer_Address); pragma Import (C, pack_set_handle_hook, "pack_set_handle_hook"); pragma Inline (pack_set_handle_hook); @@ -29,12 +24,12 @@ package body FLTK.Widgets.Groups.Packed is function new_fl_pack (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) - return System.Address; + return Storage.Integer_Address; pragma Import (C, new_fl_pack, "new_fl_pack"); pragma Inline (new_fl_pack); procedure free_fl_pack - (B : in System.Address); + (B : in Storage.Integer_Address); pragma Import (C, free_fl_pack, "free_fl_pack"); pragma Inline (free_fl_pack); @@ -42,13 +37,13 @@ package body FLTK.Widgets.Groups.Packed is function fl_pack_get_spacing - (P : in System.Address) + (P : in Storage.Integer_Address) return Interfaces.C.int; pragma Import (C, fl_pack_get_spacing, "fl_pack_get_spacing"); pragma Inline (fl_pack_get_spacing); procedure fl_pack_set_spacing - (P : in System.Address; + (P : in Storage.Integer_Address; S : in Interfaces.C.int); pragma Import (C, fl_pack_set_spacing, "fl_pack_set_spacing"); pragma Inline (fl_pack_set_spacing); @@ -57,12 +52,12 @@ package body FLTK.Widgets.Groups.Packed is procedure fl_pack_draw - (W : in System.Address); + (W : in Storage.Integer_Address); pragma Import (C, fl_pack_draw, "fl_pack_draw"); pragma Inline (fl_pack_draw); function fl_pack_handle - (W : in System.Address; + (W : in Storage.Integer_Address; E : in Interfaces.C.int) return Interfaces.C.int; pragma Import (C, fl_pack_handle, "fl_pack_handle"); @@ -74,12 +69,12 @@ package body FLTK.Widgets.Groups.Packed is procedure Finalize (This : in out Packed_Group) is begin - if This.Void_Ptr /= System.Null_Address and then + if This.Void_Ptr /= Null_Pointer and then This in Packed_Group'Class then This.Clear; free_fl_pack (This.Void_Ptr); - This.Void_Ptr := System.Null_Address; + This.Void_Ptr := Null_Pointer; end if; Finalize (Group (This)); end Finalize; @@ -104,9 +99,9 @@ package body FLTK.Widgets.Groups.Packed is fl_group_end (This.Void_Ptr); fl_widget_set_user_data (This.Void_Ptr, - Widget_Convert.To_Address (This'Unchecked_Access)); - pack_set_draw_hook (This.Void_Ptr, Draw_Hook'Address); - pack_set_handle_hook (This.Void_Ptr, Handle_Hook'Address); + Storage.To_Integer (Widget_Convert.To_Address (This'Unchecked_Access))); + pack_set_draw_hook (This.Void_Ptr, Storage.To_Integer (Draw_Hook'Address)); + pack_set_handle_hook (This.Void_Ptr, Storage.To_Integer (Handle_Hook'Address)); fl_widget_set_label (This.Void_Ptr, Interfaces.C.To_C (Text)); end return; end Create; |