diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-10-19 09:08:35 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-10-21 15:25:56 +0200 |
commit | 5f9ffc31cd1b5433c354c7d39ce1d80fa0e57fc8 (patch) | |
tree | 8736f233563535eb3aa5fa019bb92a9970970428 /sw/qa/extras/indexing | |
parent | 81debfba86b1d67d1c2e0ecd9c10ca35c3e7de5e (diff) |
introduce SwNodeOffset strong typedef
for indexing into node children. Replaces various usage
of sal_uLong, tools::Long, sal_uInt32 with an underlying
type of sal_Int32.
Also add a NODE_OFFSET_MAX constant to replace usage
of ULONG_MAX
Change-Id: I2f466922e1ebc19029bb2883d2b29aa4c0614170
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123892
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw/qa/extras/indexing')
-rw-r--r-- | sw/qa/extras/indexing/SearchResultLocatorTest.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/qa/extras/indexing/SearchResultLocatorTest.cxx b/sw/qa/extras/indexing/SearchResultLocatorTest.cxx index 586c07b1e534..69aeba0003af 100644 --- a/sw/qa/extras/indexing/SearchResultLocatorTest.cxx +++ b/sw/qa/extras/indexing/SearchResultLocatorTest.cxx @@ -63,7 +63,7 @@ void SearchResultLocatorTest::testSearchResultLocator() sw::search::SearchResultLocator aLocator(pDoc); std::vector<sw::search::SearchIndexData> aDataVector; - aDataVector.emplace_back(sw::search::NodeType::WriterNode, 14); + aDataVector.emplace_back(sw::search::NodeType::WriterNode, SwNodeOffset(14)); sw::search::LocationResult aResult = aLocator.find(aDataVector); CPPUNIT_ASSERT_EQUAL(size_t(1), aResult.maRectangles.size()); @@ -146,7 +146,7 @@ void SearchResultLocatorTest::testSearchResultLocatorForSdrObjects() sw::search::SearchResultLocator aLocator(pDoc); std::vector<sw::search::SearchIndexData> aDataVector; - aDataVector.emplace_back(sw::search::NodeType::CommonNode, 1, u"Circle"); + aDataVector.emplace_back(sw::search::NodeType::CommonNode, SwNodeOffset(1), u"Circle"); sw::search::LocationResult aResult = aLocator.find(aDataVector); CPPUNIT_ASSERT_EQUAL(size_t(1), aResult.maRectangles.size()); |