Unit 'MUIClass.Base' Package
[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] [#MUIClass]

TMUIRootClass.ConnectHookObject

Connect a Event (via Hook) to a changing Field Value with given object

Declaration

Source position: MUIClass.Base.pas line 77

protected procedure TMUIRootClass.ConnectHookObject(

  AObj: PObject_;

  MUIField: PtrUInt;

  TriggerValue: PtrUInt;

  HookFunc: THookFunc

);

Arguments

AObj

  

Object to set the Event

MUIField

  

Field to trigger

TriggerValue

  

Value when the Event should be fired or MUIV_EveryTime trigger for every change

HookFunc

  

Event function to call when event is triggered

Description

Set the Hook to the Hook function and install a Notify Event for the given Field and Value. The Hook Data points to this Pascal object. in principle it does something like:

MH_SetHook(Hook, HookFunc, Self);
  DoMethod(AObj, [MUI_Notify, MUIField, TriggerValue, MUIV_Notify_Self, 2, MUIM_CallHook, NativeUInt(Hook)]);
  

Better use ConnectHook which uses the internal object, it should be very seldom to use this explicit function

See also

ConnectHook

  

Connect a Event (via Hook) to a changing Field Value with internal object


Documentation generated on: 2024-12-27