Remove unused method QKeyMapper::clearMappings()

The plumbing from QKeyMapper to the platform specific key mappers
via QPA was never done, so this method is unused. The code path
in QKeyMapper that would trigger it would be changeKeyboard(),
but that's already handled in QCocoaKeyMapper, and wouldn't be
initiated from the cross platform code in any case.

Change-Id: Ibc0c419627fc0430d028945038c1f2fbafe42d4b
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
This commit is contained in:
Tor Arne Vestbø 2020-07-09 19:37:09 +02:00
parent f08c15c3de
commit 9ac5273d03
4 changed files with 0 additions and 15 deletions

View File

@ -89,8 +89,6 @@ QList<int> QKeyMapper::possibleKeys(QKeyEvent *e)
extern bool qt_sendSpontaneousEvent(QObject *receiver, QEvent *event); // in qapplication_*.cpp
void QKeyMapper::changeKeyboard()
{
instance()->d_func()->clearMappings();
// ## TODO: Support KeyboardLayoutChange on QPA
#if 0
// inform all toplevel widgets of the change
@ -125,11 +123,6 @@ QKeyMapperPrivate::QKeyMapperPrivate()
}
QKeyMapperPrivate::~QKeyMapperPrivate()
{
// clearMappings();
}
void QKeyMapperPrivate::clearMappings()
{
}

View File

@ -88,7 +88,6 @@ public:
QKeyMapperPrivate();
~QKeyMapperPrivate();
void clearMappings();
QList<int> possibleKeys(QKeyEvent *e);
QLocale keyboardInputLocale;

View File

@ -92,7 +92,6 @@ private:
bool updateKeyboard();
void deleteLayouts();
KeyboardLayoutItem *keyMapForKey(unsigned short macVirtualKey, QChar unicodeKey) const;
void clearMappings();
QCFType<TISInputSourceRef> m_currentInputSource = nullptr;

View File

@ -440,12 +440,6 @@ void QCocoaKeyMapper::deleteLayouts()
}
}
void QCocoaKeyMapper::clearMappings()
{
deleteLayouts();
updateKeyboard();
}
static constexpr Qt::KeyboardModifiers modifierCombinations[] = {
Qt::NoModifier, // 0
Qt::ShiftModifier, // 1