Frame Source Listener

Defined under the namespace Scandit.Datacapture.Core

FrameSourceListener
interface FrameSourceListener

Added in version 6.1.0

didChangeState(frameSource, newState)
didChangeState?(frameSource: FrameSource,
        newState: FrameSourceState): void

Added in version 6.1.0

Called whenever the frame source’s FrameSource.getCurrentState changes, typically after FrameSource.switchToDesiredState(). Depending on the frame source and platform, the new state can be one of the transition values listed on FrameSourceState, such as FrameSourceState.Starting or FrameSourceState.Stopping, reported before the state the transition leads to.

Adding a listener does not trigger this callback; read FrameSource.getCurrentState to get the state at the time the listener is added.