Changeset View
Changeset View
Standalone View
Standalone View
backends/fake/parser.cpp
Show First 20 Lines • Show All 186 Lines • ▼ Show 20 Line(s) | 113 | { | |||
---|---|---|---|---|---|
187 | if (map.contains("size")) { | 187 | if (map.contains("size")) { | ||
188 | output->setSize(Parser::sizeFromJson(map["size"].toMap())); | 188 | output->setSize(Parser::sizeFromJson(map["size"].toMap())); | ||
189 | map.remove(QLatin1Literal("size")); | 189 | map.remove(QLatin1Literal("size")); | ||
190 | } | 190 | } | ||
191 | 191 | | |||
192 | if (map.contains("scale")) { | 192 | if (map.contains("scale")) { | ||
193 | qDebug() << "Scale found:" << map["scale"].toReal(); | 193 | qDebug() << "Scale found:" << map["scale"].toReal(); | ||
194 | output->setScale(map["scale"].toReal()); | 194 | output->setScale(map["scale"].toReal()); | ||
195 | map.remove(QLatin1Literal("size")); | 195 | map.remove(QLatin1Literal("scale")); | ||
196 | } | 196 | } | ||
197 | 197 | | |||
198 | //Remove some extra properties that we do not want or need special treatment | 198 | //Remove some extra properties that we do not want or need special treatment | ||
199 | map.remove(QLatin1Literal("edid")); | 199 | map.remove(QLatin1Literal("edid")); | ||
200 | 200 | | |||
201 | Parser::qvariant2qobject(map, output.data()); | 201 | Parser::qvariant2qobject(map, output.data()); | ||
202 | return output; | 202 | return output; | ||
203 | } | 203 | } | ||
▲ Show 20 Lines • Show All 54 Lines • Show Last 20 Lines |