Refactor some QML.