Add a keyboard shortcut to quit the application.
This commit is contained in:
5
XS7.cpp
5
XS7.cpp
@@ -110,6 +110,11 @@ void XS7::OnDpkDoubleClick ( wxMouseEvent& evt )
|
|||||||
|
|
||||||
void XS7::OnAppKeyPressed(wxKeyEvent& evt)
|
void XS7::OnAppKeyPressed(wxKeyEvent& evt)
|
||||||
{
|
{
|
||||||
|
if (evt.ControlDown())
|
||||||
|
{
|
||||||
|
if (evt.GetKeyCode() == 'Q')
|
||||||
|
Close();
|
||||||
|
}
|
||||||
if (evt.GetKeyCode() == WXK_ESCAPE)
|
if (evt.GetKeyCode() == WXK_ESCAPE)
|
||||||
if (m_insaneWidget)
|
if (m_insaneWidget)
|
||||||
m_insaneWidget->CancelScanning();
|
m_insaneWidget->CancelScanning();
|
||||||
|
|||||||
Reference in New Issue
Block a user