summaryrefslogblamecommitdiffstats
path: root/native/src/subscription.rs
blob: c49e24d2ca94002448a5a86dea2fd85df62b8010 (plain) (tree)
1
2
3
4
5
6
7
8
9
                           
                               
 
                                                 
 
                                                                           
 
                                        
 
           
 
                   
 

                                        
 
use crate::{Event, Hasher};
use futures::stream::BoxStream;

pub type EventStream = BoxStream<'static, Event>;

pub type Subscription<T> = iced_core::Subscription<Hasher, EventStream, T>;

pub use iced_core::subscription::Recipe;

mod events;

use events::Events;

pub fn events() -> Subscription<Event> {
    Subscription::from_recipe(Events)
}