ActionRef

public struct ActionRef : ActionProtocol

AtkAction should be implemented by instances of AtkObject classes with which the user can interact directly, i.e. buttons, checkboxes, scrollbars, e.g. components which are not “passive” providers of UI information.

Exceptions: when the user interaction is already covered by another appropriate interface such as AtkEditableText (insert/delete text, etc.) or AtkValue (set value) then these actions should not be exposed by AtkAction as well.

Though most UI interactions on components should be invocable via keyboard as well as mouse, there will generally be a close mapping between “mouse actions” that are possible on a component and the AtkActions. Where mouse and keyboard actions are redundant in effect, AtkAction should expose only one action rather than exposing redundant actions if possible. By convention we have been using “mouse centric” terminology for AtkAction names.

The ActionRef type acts as a lightweight Swift reference to an underlying AtkAction instance. It exposes methods that can operate on this data type through ActionProtocol conformance. Use ActionRef only as an unowned reference to an existing AtkAction instance.

  • ptr
    Untyped pointer to the underlying `AtkAction` instance.
    

    For type-safe access, use the generated, typed pointer action_ptr property instead.

    Declaration

    Swift

    public let ptr: UnsafeMutableRawPointer!

Action Interface

  • Designated initialiser from the underlying C data type

    Declaration

    Swift

    @inlinable
    init(_ p: UnsafeMutablePointer<AtkAction>)
  • Designated initialiser from a constant pointer to the underlying C data type

    Declaration

    Swift

    @inlinable
    init(_ p: UnsafePointer<AtkAction>)
  • Conditional initialiser from an optional pointer to the underlying C data type

    Declaration

    Swift

    @inlinable
    init!(_ maybePointer: UnsafeMutablePointer<AtkAction>?)
  • Conditional initialiser from an optional, non-mutable pointer to the underlying C data type

    Declaration

    Swift

    @inlinable
    init!(_ maybePointer: UnsafePointer<AtkAction>?)
  • Conditional initialiser from an optional gpointer

    Declaration

    Swift

    @inlinable
    init!(gpointer g: gpointer?)
  • Conditional initialiser from an optional, non-mutable gconstpointer

    Declaration

    Swift

    @inlinable
    init!(gconstpointer g: gconstpointer?)
  • Reference intialiser for a related type that implements ActionProtocol

    Declaration

    Swift

    @inlinable
    init<T>(_ other: T) where T : ActionProtocol
  • Unsafe typed initialiser. Do not use unless you know the underlying data type the pointer points to conforms to ActionProtocol.

    Declaration

    Swift

    @inlinable
    init<T>(cPointer: UnsafeMutablePointer<T>)
  • Unsafe typed initialiser. Do not use unless you know the underlying data type the pointer points to conforms to ActionProtocol.

    Declaration

    Swift

    @inlinable
    init<T>(constPointer: UnsafePointer<T>)
  • Unsafe untyped initialiser. Do not use unless you know the underlying data type the pointer points to conforms to ActionProtocol.

    Declaration

    Swift

    @inlinable
    init(mutating raw: UnsafeRawPointer)
  • Unsafe untyped initialiser. Do not use unless you know the underlying data type the pointer points to conforms to ActionProtocol.

    Declaration

    Swift

    @inlinable
    init(raw: UnsafeMutableRawPointer)
  • Unsafe untyped initialiser. Do not use unless you know the underlying data type the pointer points to conforms to ActionProtocol.

    Declaration

    Swift

    @inlinable
    init(opaquePointer: OpaquePointer)