Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions wxTerminal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1156,11 +1156,13 @@ extern "C" void do_keyact(int);
void
wxTerminal::OnChar(wxKeyEvent& event)
{
if(event.HasModifiers()) {
//If the key event has control or alt pressed, let something else handle it
//If the key event has control or alt pressed, let something else handle it
int modCode = (int) event.GetModifiers();
if((modCode == wxMOD_ALT) || (modCode == wxMOD_CONTROL)) {
Copy link
Owner

@jrincayc jrincayc Apr 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm, we use shift with some control functions, so should this be:
if((modCode == wxMOD_ALT) || (modCode == wxMOD_CONTROL) || (modCode == (wxMOD_CONTROL | wxMOD_SHIFT)))

Copy link
Owner

@jrincayc jrincayc Apr 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or another possibility (that I have not tested) is to filter out wxMOD_ALTGR :
if(event.HasModifiers() && event.getModifiers() != wxMOD_ALTGR)

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Basically, the submitted pull request breaks Ctrl++ since that needs shift and control, so please fix, and then I can merge this. Thanks.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed myself.

event.Skip();
return;
}

ClearSelection();
int
keyCode = 0,
Expand Down