1{ 2} 3 4{**************************************************************************** 5 Interface 6****************************************************************************} 7 8{$ifdef read_interface} 9 10 type 11 PGtkListItem = ^TGtkListItem; 12 TGtkListItem = record 13 item : TGtkItem; 14 end; 15 16 PGtkListItemClass = ^TGtkListItemClass; 17 TGtkListItemClass = record 18 parent_class : TGtkItemClass; 19 toggle_focus_row : procedure (list_item:PGtkListItem);cdecl; 20 select_all : procedure (list_item:PGtkListItem);cdecl; 21 unselect_all : procedure (list_item:PGtkListItem);cdecl; 22 undo_selection : procedure (list_item:PGtkListItem);cdecl; 23 start_selection : procedure (list_item:PGtkListItem);cdecl; 24 end_selection : procedure (list_item:PGtkListItem);cdecl; 25 extend_selection : procedure (list_item:PGtkListItem; scroll_type:TGtkScrollType; position:gfloat; auto_start_selection:gboolean);cdecl; 26 scroll_horizontal : procedure (list_item:PGtkListItem; scroll_type:TGtkScrollType; position:gfloat);cdecl; 27 scroll_vertical : procedure (list_item:PGtkListItem; scroll_type:TGtkScrollType; position:gfloat);cdecl; 28 toggle_add_mode : procedure (list_item:PGtkListItem);cdecl; 29 end; 30 31Type 32 GTK_LIST_ITEM=PGtkListItem; 33 GTK_LIST_ITEM_CLASS=PGtkListItemClass; 34 35function GTK_LIST_ITEM_TYPE:TGtkType;cdecl;external gtkdll name 'gtk_list_item_get_type'; 36function GTK_IS_LIST_ITEM(obj:pointer):boolean; 37function GTK_IS_LIST_ITEM_CLASS(klass:pointer):boolean; 38 39function gtk_list_item_get_type:TGtkType;cdecl;external gtkdll name 'gtk_list_item_get_type'; 40function gtk_list_item_new:PGtkWidget;cdecl;external gtkdll name 'gtk_list_item_new'; 41function gtk_list_item_new_with_label(thelabel:Pgchar):PGtkWidget;cdecl;external gtkdll name 'gtk_list_item_new_with_label'; 42procedure gtk_list_item_select(list_item:PGtkListItem);cdecl;external gtkdll name 'gtk_list_item_select'; 43procedure gtk_list_item_deselect(list_item:PGtkListItem);cdecl;external gtkdll name 'gtk_list_item_deselect'; 44 45{$endif read_interface} 46 47 48{**************************************************************************** 49 Implementation 50****************************************************************************} 51 52{$ifdef read_implementation} 53 54function GTK_IS_LIST_ITEM(obj:pointer):boolean; 55begin 56 GTK_IS_LIST_ITEM:=(obj<>nil) and GTK_IS_LIST_ITEM_CLASS(PGtkTypeObject(obj)^.klass); 57end; 58 59function GTK_IS_LIST_ITEM_CLASS(klass:pointer):boolean; 60begin 61 GTK_IS_LIST_ITEM_CLASS:=(klass<>nil) and (PGtkTypeClass(klass)^.thetype=GTK_LIST_ITEM_TYPE); 62end; 63 64{$endif read_implementation} 65 66 67