Kaydet (Commit) c135f51b authored tarafından Noel Grandin's avatar Noel Grandin

loplugin:returnconstant in XclExpAutofilter

Change-Id: Ibd57de5b8309048ec29e869f3058b0a8bb26df71
Reviewed-on: https://gerrit.libreoffice.org/59134
Tested-by: Jenkins
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst 9278de7a
......@@ -702,7 +702,10 @@ bool XclExpAutofilter::AddEntry( const ScQueryEntry& rEntry )
return true;
if (GetOutput() != EXC_OUTPUT_BINARY && rItems.size() > 1)
return AddMultiValueEntry(rEntry);
{
AddMultiValueEntry(rEntry);
return true;
}
bool bConflict = false;
OUString sText;
......@@ -809,15 +812,13 @@ bool XclExpAutofilter::AddEntry( const ScQueryEntry& rEntry )
return bConflict;
}
bool XclExpAutofilter::AddMultiValueEntry( const ScQueryEntry& rEntry )
void XclExpAutofilter::AddMultiValueEntry( const ScQueryEntry& rEntry )
{
meType = MultiValue;
const ScQueryEntry::QueryItemsType& rItems = rEntry.GetQueryItems();
ScQueryEntry::QueryItemsType::const_iterator itr = rItems.begin(), itrEnd = rItems.end();
for (; itr != itrEnd; ++itr)
maMultiValues.push_back(itr->maString.getString());
return false;
}
void XclExpAutofilter::WriteBody( XclExpStream& rStrm )
......
......@@ -393,7 +393,7 @@ public:
bool HasCondition() const;
bool AddEntry( const ScQueryEntry& rEntry );
bool AddMultiValueEntry( const ScQueryEntry& rEntry );
void AddMultiValueEntry( const ScQueryEntry& rEntry );
virtual void SaveXml( XclExpXmlStream& rStrm ) override;
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment