mirror of
https://bitbucket.org/smil3y/katie.git
synced 2025-02-25 03:12:56 +00:00
mark QShortcut warning cases as unlikely
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
a411026929
commit
1b72cc642a
1 changed files with 2 additions and 2 deletions
|
@ -33,7 +33,7 @@
|
|||
QT_BEGIN_NAMESPACE
|
||||
|
||||
#define QAPP_CHECK(functionName) \
|
||||
if (!qApp) { \
|
||||
if (Q_UNLIKELY(!qApp)) { \
|
||||
qWarning("QShortcut: Initialize QApplication before calling '" functionName "'."); \
|
||||
return; \
|
||||
}
|
||||
|
@ -140,7 +140,7 @@ public:
|
|||
void QShortcutPrivate::redoGrab(QShortcutMap &map)
|
||||
{
|
||||
Q_Q(QShortcut);
|
||||
if (!parent) {
|
||||
if (Q_UNLIKELY(!parent)) {
|
||||
qWarning("QShortcut: No widget parent defined");
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue