}
/*! \internal
- Returns the current state of the statemachine
-*/
-QKeySequence::SequenceMatch QShortcutMap::state()
-{
- Q_D(QShortcutMap);
- return d->currentState;
-}
-
-/*! \internal
Uses ShortcutOverride event to see if any widgets want to override
the event. If not, uses nextState(QKeyEvent) to check for a grabbed
Shortcut, and dispatchEvent() is found an identical.
#endif // QT_NO_ACTION
/*! \internal
- Converts keyboard button states into modifier states
-*/
-int QShortcutMap::translateModifiers(Qt::KeyboardModifiers modifiers)
-{
- int result = 0;
- if (modifiers & Qt::ShiftModifier)
- result |= Qt::SHIFT;
- if (modifiers & Qt::ControlModifier)
- result |= Qt::CTRL;
- if (modifiers & Qt::MetaModifier)
- result |= Qt::META;
- if (modifiers & Qt::AltModifier)
- result |= Qt::ALT;
- return result;
-}
-
-/*! \internal
- Returns the vector of QShortcutEntry's matching the last Identical state.
-*/
-QVector<const QShortcutEntry*> QShortcutMap::matches() const
-{
- Q_D(const QShortcutMap);
- return d->identicals;
-}
-
-/*! \internal
Dispatches QShortcutEvents to widgets who grabbed the matched key sequence.
*/
void QShortcutMap::dispatchEvent(QKeyEvent *e)
void resetState();
QKeySequence::SequenceMatch nextState(QKeyEvent *e);
- QKeySequence::SequenceMatch state();
void dispatchEvent(QKeyEvent *e);
bool tryShortcutEvent(QObject *o, QKeyEvent *e);
QKeySequence::SequenceMatch find(QKeyEvent *e);
QKeySequence::SequenceMatch matches(const QKeySequence &seq1, const QKeySequence &seq2) const;
- QVector<const QShortcutEntry *> matches() const;
void createNewSequences(QKeyEvent *e, QVector<QKeySequence> &ksl);
void clearSequence(QVector<QKeySequence> &ksl);
bool correctContext(const QShortcutEntry &item) const;
- int translateModifiers(Qt::KeyboardModifiers modifiers);
};
#endif // QT_NO_SHORTCUT