Skip to content

addObserver cannot take multiple NSKeyValueObservingOptions #2732

@dickermoshe

Description

@dickermoshe
Observed(player).addObserver(
      observer,
      forKeyPath: "timeControlStatus".toNSString(),
      options:
          NSKeyValueObservingOptions.NSKeyValueObservingOptionInitial | // ERROR: The operator '|' isn't defined for the type 'NSKeyValueObservingOptions'.

          NSKeyValueObservingOptions.NSKeyValueObservingOptionNew,
      context: nullptr,
    );

addObserver should take an int instead of an enum.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions