autotests: Fix crash
If a test case is skipped, there will be no input devices.
This commit is contained in:
parent
7a1a1161cc
commit
15f6c910be
1 changed files with 9 additions and 3 deletions
|
@ -115,9 +115,15 @@ void WaylandTestApplication::createVirtualInputDevices()
|
|||
|
||||
void WaylandTestApplication::destroyVirtualInputDevices()
|
||||
{
|
||||
input()->removeInputDevice(m_virtualPointer.get());
|
||||
input()->removeInputDevice(m_virtualTouch.get());
|
||||
input()->removeInputDevice(m_virtualKeyboard.get());
|
||||
if (m_virtualPointer) {
|
||||
input()->removeInputDevice(m_virtualPointer.get());
|
||||
}
|
||||
if (m_virtualTouch) {
|
||||
input()->removeInputDevice(m_virtualTouch.get());
|
||||
}
|
||||
if (m_virtualKeyboard) {
|
||||
input()->removeInputDevice(m_virtualKeyboard.get());
|
||||
}
|
||||
}
|
||||
|
||||
void WaylandTestApplication::performStartup()
|
||||
|
|
Loading…
Reference in a new issue