atkselection.inc 3.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. // included by atk.pp
  2. {
  3. This AtkSelection interface provides the standard mechanism for an
  4. assistive technology to determine what the current selected children are,
  5. as well as modify the selection set. Any anObject that has children that
  6. can be selected should support the AtkSelection interface.
  7. }
  8. {$IFDEF read_forward_definitions}
  9. {$ENDIF read_forward_definitions}
  10. //------------------------------------------------------------------------------
  11. {$IFDEF read_interface_types}
  12. { signal handlers }
  13. PAtkSelectionIface = ^TAtkSelectionIface;
  14. TAtkSelectionIface = record
  15. parent : TGTypeInterface;
  16. add_selection : function (selection:PAtkSelection; i:gint):gboolean; cdecl;
  17. clear_selection : function (selection:PAtkSelection):gboolean; cdecl;
  18. ref_selection : function (selection:PAtkSelection; i:gint):PAtkObject; cdecl;
  19. get_selection_count : function (selection:PAtkSelection):gint; cdecl;
  20. is_child_selected : function (selection:PAtkSelection; i:gint):gboolean; cdecl;
  21. remove_selection : function (selection:PAtkSelection; i:gint):gboolean; cdecl;
  22. select_all_selection : function (selection:PAtkSelection):gboolean; cdecl;
  23. selection_changed : procedure (selection:PAtkSelection); cdecl;
  24. pad1 : TAtkFunction;
  25. pad2 : TAtkFunction;
  26. end;
  27. {$ENDIF read_interface_types}
  28. //------------------------------------------------------------------------------
  29. {$IFDEF read_interface_rest}
  30. function ATK_TYPE_SELECTION : GType;
  31. function ATK_IS_SELECTION(obj: pointer) : boolean;
  32. function ATK_SELECTION(obj: pointer) : PAtkSelection;
  33. function ATK_SELECTION_GET_IFACE(obj: pointer) : PAtkSelectionIface;
  34. function atk_selection_get_type:GType; cdecl; external atklib;
  35. function atk_selection_add_selection(selection:PAtkSelection; i:gint):gboolean; cdecl; external atklib;
  36. function atk_selection_clear_selection(selection:PAtkSelection):gboolean; cdecl; external atklib;
  37. function atk_selection_ref_selection(selection:PAtkSelection; i:gint):PAtkObject; cdecl; external atklib;
  38. function atk_selection_get_selection_count(selection:PAtkSelection):gint; cdecl; external atklib;
  39. function atk_selection_is_child_selected(selection:PAtkSelection; i:gint):gboolean; cdecl; external atklib;
  40. function atk_selection_remove_selection(selection:PAtkSelection; i:gint):gboolean; cdecl; external atklib;
  41. function atk_selection_select_all_selection(selection:PAtkSelection):gboolean; cdecl; external atklib;
  42. {$ENDIF read_interface_rest}
  43. //------------------------------------------------------------------------------
  44. {$IFDEF read_implementation}
  45. function ATK_TYPE_SELECTION : GType;
  46. begin
  47. ATK_TYPE_SELECTION:=atk_selection_get_type;
  48. end;
  49. function ATK_IS_SELECTION(obj: pointer) : boolean;
  50. begin
  51. ATK_IS_SELECTION:=G_TYPE_CHECK_INSTANCE_TYPE(obj,ATK_TYPE_SELECTION);
  52. end;
  53. function ATK_SELECTION(obj: pointer) : PAtkSelection;
  54. begin
  55. ATK_SELECTION:=PAtkSelection(G_TYPE_CHECK_INSTANCE_CAST(obj,ATK_TYPE_SELECTION));
  56. end;
  57. function ATK_SELECTION_GET_IFACE(obj: pointer) : PAtkSelectionIface;
  58. begin
  59. ATK_SELECTION_GET_IFACE:=PAtkSelectionIface(G_TYPE_INSTANCE_GET_INTERFACE(obj,ATK_TYPE_SELECTION));
  60. end;
  61. {$ENDIF read_implementation}