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:
Robin Krahl 2020-10-06 21:31:40 +02:00 committed by GitHub
parent 3ab4f9b0f7
commit f694e2ae25
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -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()))
}