mpv_event_name method

Pointer<Char> mpv_event_name(
  1. mpv_event_id event
)

Return a string describing the event. For unknown events, NULL is returned.

Note that all events actually returned by the API will also yield a non-NULL string with this function.

@param event event ID, see see enum mpv_event_id @return A static string giving a short symbolic name of the event. It consists of lower-case alphanumeric characters and can include "-" characters. This string is suitable for use in e.g. scripting interfaces. The string is completely static, i.e. doesn't need to be deallocated, and is valid forever.

Implementation

ffi.Pointer<ffi.Char> mpv_event_name(
  mpv_event_id event,
) {
  return _mpv_event_name(
    event.value,
  );
}