fn write(&mut self, event: Event) {
        let epoch = self.epoch();

        match event {
            Event::Key(event) => {
                self.key = Snapshot { epoch: epoch + 1, event }
            },
            Event::Resize(event) => {
                self.resize = Snapshot { epoch: epoch + 1, event }
            },
        }
    }
/// Writes an event into the channel. Advances current epoch.
Writes an event into the channel. Advances current epoch.
Writes an event into the channel . Advances current epoch .
fn write(&mut self, event: Event) {
        let epoch = self.epoch();
        match event {
            Event::Key(event) => {
                self.key = Snapshot { epoch: epoch + 1, event }
            },
            Event::Resize(event) => {
                self.resize = Snapshot { epoch: epoch + 1, event }
            },
        }
    }
fn write ( & mut self , event : Event ) { let epoch = self . epoch ( ) ; match event { Event :: Key ( event ) => { self . key = Snapshot { epoch : epoch + 1 , event } } , Event :: Resize ( event ) => { self . resize = Snapshot { epoch : epoch + 1 , event } } , } }
Writes an event into the channel.
Writes an event into the channel .
&mut self
event
Event
&mut self
event
Event