1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
//! Phone connection events, for [`ConnectionService`](crate::service::ConnectionService). /// The phone app, or a PebbleKit companion app, connected or disconnected. pub enum Event { AppConnected, AppDisconnected, PebbleKitConnected, PebbleKitDisconnected, } /// What's connected right now. pub struct State { /// The Pebble phone app. pub app: bool, /// A PebbleKit companion app. pub pebblekit: bool, } bitflags::bitflags! { /// Which connections to report on. pub struct SubscribeTo: u8 { const APP = 1; const PEBBLEKIT = 1 << 1; }}