atkvalue.inc 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. // included by atk.pp
  2. {
  3. The AtkValue interface should be supported by any anObject that
  4. supports a numerical value (e.g., a scroll bar). This interface
  5. provides the standard mechanism for an assistive technology to
  6. determine and set the numerical value as well as get the minimum
  7. and maximum values.
  8. }
  9. {$IFDEF read_forward_definitions}
  10. {$ENDIF read_forward_definitions}
  11. //------------------------------------------------------------------------------
  12. {$IFDEF read_interface_types}
  13. PAtkValueIface = ^TAtkValueIface;
  14. TAtkValueIface = record
  15. parent : TGTypeInterface;
  16. get_current_value : procedure (obj:PAtkValue; value:PGValue); cdecl;
  17. get_maximum_value : procedure (obj:PAtkValue; value:PGValue); cdecl;
  18. get_minimum_value : procedure (obj:PAtkValue; value:PGValue); cdecl;
  19. set_current_value : function (obj:PAtkValue; value:PGValue):gboolean; cdecl;
  20. pad1 : TAtkFunction;
  21. pad2 : TAtkFunction;
  22. end;
  23. {$ENDIF read_interface_types}
  24. //------------------------------------------------------------------------------
  25. {$IFDEF read_interface_rest}
  26. function ATK_TYPE_VALUE : GType;
  27. function ATK_IS_VALUE(obj: pointer) : boolean;
  28. function ATK_VALUE(obj: pointer) : PAtkValue;
  29. function ATK_VALUE_GET_IFACE(obj: pointer) : PAtkValueIface;
  30. function atk_value_get_type:GType; cdecl; external atklib;
  31. procedure atk_value_get_current_value(obj:PAtkValue; value:PGValue); cdecl; external atklib;
  32. procedure atk_value_get_maximum_value(obj:PAtkValue; value:PGValue); cdecl; external atklib;
  33. procedure atk_value_get_minimum_value(obj:PAtkValue; value:PGValue); cdecl; external atklib;
  34. function atk_value_set_current_value(obj:PAtkValue; value:PGValue):gboolean; cdecl; external atklib;
  35. {
  36. Additional GObject properties exported by GaccessibleValue:
  37. "accessible_value"
  38. (the accessible value has changed)
  39. }
  40. {$ENDIF read_interface_rest}
  41. //------------------------------------------------------------------------------
  42. {$IFDEF read_implementation}
  43. function ATK_TYPE_VALUE : GType;
  44. begin
  45. ATK_TYPE_VALUE:=atk_value_get_type;
  46. end;
  47. function ATK_IS_VALUE(obj: pointer) : boolean;
  48. begin
  49. ATK_IS_VALUE:=G_TYPE_CHECK_INSTANCE_TYPE(obj,ATK_TYPE_VALUE);
  50. end;
  51. function ATK_VALUE(obj: pointer) : PAtkValue;
  52. begin
  53. ATK_VALUE:=PAtkValue(G_TYPE_CHECK_INSTANCE_CAST(obj,ATK_TYPE_VALUE));
  54. end;
  55. function ATK_VALUE_GET_IFACE(obj: pointer) : PAtkValueIface;
  56. begin
  57. ATK_VALUE_GET_IFACE:=PAtkValueIface(G_TYPE_INSTANCE_GET_INTERFACE(obj,ATK_TYPE_VALUE));
  58. end;
  59. {$ENDIF read_implementation}