mirror of
https://github.com/FliegendeWurst/cursive.git
synced 2024-11-27 11:16:03 +00:00
Remove outdated comment from button.rs (#508)
Before commit f9c9e56518
, this match
interpreted the key code 10 as the Enter key. Since it now uses the
Key::Enter variant instead, the comment explaining the magic number is
no longer needed.
This commit is contained in:
parent
3ab4f9b0f7
commit
f694e2ae25
@ -169,7 +169,6 @@ impl View for Button {
|
||||
let width = self.label.width();
|
||||
let self_offset = HAlign::Center.get_offset(width, self.last_size.x);
|
||||
match event {
|
||||
// 10 is the ascii code for '\n', that is the return key
|
||||
Event::Key(Key::Enter) => {
|
||||
EventResult::Consumed(Some(self.callback.clone()))
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user