Fix regression in the XKB rule parser
QXmlStreamReader::readElementText() changes the parser state, so we need to use the latest state rather for checking whether we have reached an end element.
QXmlStreamReader::readElementText() changes the parser state, so we need to use the latest state rather for checking whether we have reached an end element.