Skip unprocessed key events in the time edit control so that it doesn't eat hotkeys
Originally committed to SVN as r6055.
This commit is contained in:
parent
cd3b9bfa37
commit
70d703255b
1 changed files with 4 additions and 9 deletions
|
@ -224,11 +224,7 @@ void TimeEdit::OnKeyDown(wxKeyEvent &event) {
|
|||
Refresh();
|
||||
|
||||
// Check if it's an acceptable key
|
||||
#ifdef __APPLE__
|
||||
if (!event.CmdDown()) {
|
||||
#else
|
||||
if (!event.ControlDown()) {
|
||||
#endif
|
||||
if (byFrame || !insertMode || (key != WXK_BACK && key != WXK_DELETE)) {
|
||||
// Reset selection first, if necessary
|
||||
if (!byFrame && insertMode) {
|
||||
|
@ -241,17 +237,16 @@ void TimeEdit::OnKeyDown(wxKeyEvent &event) {
|
|||
event.Skip();
|
||||
}
|
||||
}
|
||||
|
||||
else {
|
||||
// Copy
|
||||
if (key == 'C' || key == 'X') {
|
||||
CopyTime();
|
||||
}
|
||||
|
||||
// Paste
|
||||
if (key == 'V') {
|
||||
else if (key == 'V') {
|
||||
PasteTime();
|
||||
}
|
||||
else {
|
||||
event.Skip();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue