summaryrefslogtreecommitdiff
path: root/svl
diff options
context:
space:
mode:
authorKohei Yoshida <kohei.yoshida@collabora.com>2013-10-09 10:08:06 -0400
committerKohei Yoshida <kohei.yoshida@collabora.com>2013-10-11 12:14:24 -0400
commitcff2f333aecdb8911736d919e3c5252320100d7e (patch)
tree1fd15eecf719e0b45c257db80ff55b91e118b417 /svl
parenta11e224e07a4fda0de64a9a0a181f6034e08d2e5 (diff)
Add isEmpty() to SharedString. This simplies a lot of its call sites.
Change-Id: I0ebc43abe59ac317c053a4f606dbe376d85c03b0
Diffstat (limited to 'svl')
-rw-r--r--svl/source/misc/sharedstring.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/svl/source/misc/sharedstring.cxx b/svl/source/misc/sharedstring.cxx
index 5eb3af5cbbf4..9c0cad2f73af 100644
--- a/svl/source/misc/sharedstring.cxx
+++ b/svl/source/misc/sharedstring.cxx
@@ -113,6 +113,11 @@ bool SharedString::isValid() const
return mpData != NULL;
}
+bool SharedString::isEmpty() const
+{
+ return mpData == NULL || mpData->length == 0;
+}
+
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */