summaryrefslogtreecommitdiff
path: root/src/svg
diff options
context:
space:
mode:
authorAriya Hidayat <ariya.hidayat@nokia.com>2009-08-31 15:42:43 +0200
committerAriya Hidayat <ariya.hidayat@nokia.com>2009-08-31 16:01:47 +0200
commit940b0b9e51f234f251d332f729531d6e9c3cea84 (patch)
tree6a220c857481d55d4d378bff12f5c83541db8f49 /src/svg
parenta8c5ded0de4b466b348080bfdef3107af39ed508 (diff)
Faster cut-off when SVG "display" attribute is not explicitly set.
Reviewed-by: Kim
Diffstat (limited to 'src/svg')
-rw-r--r--src/svg/qsvghandler.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/svg/qsvghandler.cpp b/src/svg/qsvghandler.cpp
index 2fec21531d..8a68cc39b6 100644
--- a/src/svg/qsvghandler.cpp
+++ b/src/svg/qsvghandler.cpp
@@ -2003,8 +2003,9 @@ static void parseOthers(QSvgNode *node,
const QSvgAttributes &attributes,
QSvgHandler *)
{
- QString displayStr = attributes.display.toString();
- displayStr = displayStr.trimmed();
+ if (attributes.display.isEmpty())
+ return;
+ QString displayStr = attributes.display.toString().trimmed();
if (!displayStr.isEmpty()) {
node->setDisplayMode(displayStringToEnum(displayStr));