wearable_rotary 1.0.2 copy "wearable_rotary: ^1.0.2" to clipboard
wearable_rotary: ^1.0.2 copied to clipboard

outdated

Flutter plugin that can listen to rotary events on Galaxy watch devices.

wearable_rotary #

pub package

Plugin that can listen to rotary events on Galaxy watch devices.

Usage #

To use this plugin, add wearable_rotary as a dependency in your pubspec.yaml file.

dependencies:
  wearable_rotary: ^1.0.2

Then, import wearable_rotary in your Dart code.

// Import the package.
import 'package:wearable_rotary/wearable_rotary.dart';

// Be informed when an event (RotaryEvent.clockwise or RotaryEvent.counterClockwise) occurs.
StreamSubscription<RotaryEvent> rotarySubscription =
    rotaryEvents.listen((RotaryEvent event) {
  if (event == RotaryEvent.clockwise) {
    // Do something.
  } else if (event == RotaryEvent.counterClockwise) {
    // Do something.
  }
});

// Be sure to cancel on dispose.
rotarySubscription.cancel();

Supported devices #

  • Galaxy Watch series (running Tizen 4.0 or later)
21
likes
130
points
507
downloads

Publisher

verified publishertizen.org

Weekly Downloads

Flutter plugin that can listen to rotary events on Galaxy watch devices.

Homepage
Repository (GitHub)

Documentation

API reference

License

unknown (license)

Dependencies

flutter

More

Packages that depend on wearable_rotary