blob: 8f33fa685ae98267c4fd2a8ed61849dbcc29571d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
fn main() {
'running: loop {
for event in event_pump.poll_iter() {
match event {
Event::Quit {..} | Event::KeyDown { keycode: Some(Keycode::Escape), .. } => break 'running,
}
}
}
}
fn main2() {
'running: loop {
for event in event_pump.poll_iter() {
match event {
Event::Quit {..} |
Event::KeyDownXXXXXXXXXXXXX { keycode: Some(Keycode::Escape), .. } => break 'running,
}
}
}
}
|