aboutsummaryrefslogtreecommitdiff
path: root/xmlutils.cc
diff options
context:
space:
mode:
Diffstat (limited to 'xmlutils.cc')
-rw-r--r--xmlutils.cc13
1 files changed, 13 insertions, 0 deletions
diff --git a/xmlutils.cc b/xmlutils.cc
new file mode 100644
index 0000000..350949c
--- /dev/null
+++ b/xmlutils.cc
@@ -0,0 +1,13 @@
+#include "xmlutils.h"
+
+bool advanceToFirstChildElement(QXmlStreamReader &r, const char *tag)
+{
+ while (r.readNextStartElement()) {
+ if (r.name() == tag) {
+ return true;
+ } else {
+ r.skipCurrentElement();
+ }
+ }
+ return false;
+}