Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Gautam Chitnis
web-ui-redesign
Commits
c8540099
Commit
c8540099
authored
Mar 28, 2007
by
yoann
Browse files
* QT prefs: escape key closes the dialog
parent
c6e9c5ac
Changes
2
Hide whitespace changes
Inline
Side-by-side
modules/gui/qt4/dialogs/prefs_dialog.cpp
View file @
c8540099
...
...
@@ -37,6 +37,7 @@
#include
<QCheckBox>
#include
<QScrollArea>
#include
<QMessageBox>
#include
<QKeyEvent>
PrefsDialog
*
PrefsDialog
::
instance
=
NULL
;
...
...
@@ -268,3 +269,11 @@ void PrefsDialog::reset()
config_SaveConfigFile
(
p_intf
,
NULL
);
}
}
void
PrefsDialog
::
keyPressEvent
(
QKeyEvent
*
e
)
{
if
(
e
->
key
()
==
Qt
::
Key_Escape
)
{
cancel
();
}
}
modules/gui/qt4/dialogs/prefs_dialog.hpp
View file @
c8540099
...
...
@@ -79,13 +79,14 @@ private:
static
PrefsDialog
*
instance
;
private
slots
:
void
changePanel
(
QTreeWidgetItem
*
);
void
changeSimplePanel
(
QListWidgetItem
*
);
void
changePanel
(
QTreeWidgetItem
*
);
void
changeSimplePanel
(
QListWidgetItem
*
);
void
setAll
();
void
setSmall
();
void
save
();
void
cancel
();
void
reset
();
void
keyPressEvent
(
QKeyEvent
*
);
};
#endif
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment