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

loplugin:useuniqueptr in ScAccessiblePreviewCell

Change-Id: I99b9809b3924285b4f0d58905352777b948ee592
Reviewed-on: https://gerrit.libreoffice.org/56546
Tested-by: Jenkins
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst ceff8f73
......@@ -74,8 +74,7 @@ void SAL_CALL ScAccessiblePreviewCell::disposing()
mpViewShell = nullptr;
}
if (mpTextHelper)
DELETEZ(mpTextHelper);
mpTextHelper.reset();
ScAccessibleCellBase::disposing();
}
......@@ -271,10 +270,10 @@ void ScAccessiblePreviewCell::CreateTextHelper()
{
if (!mpTextHelper)
{
mpTextHelper = new ::accessibility::AccessibleTextHelper(
mpTextHelper.reset( new ::accessibility::AccessibleTextHelper(
o3tl::make_unique<ScAccessibilityEditSource>(
o3tl::make_unique<ScAccessiblePreviewCellTextData>(
mpViewShell, maCellAddress)));
mpViewShell, maCellAddress))) );
mpTextHelper->SetEventSource( this );
// paragraphs in preview are transient
......
......@@ -85,7 +85,7 @@ protected:
private:
ScPreviewShell* mpViewShell;
accessibility::AccessibleTextHelper* mpTextHelper;
std::unique_ptr<accessibility::AccessibleTextHelper> mpTextHelper;
bool IsDefunc(
const css::uno::Reference<css::accessibility::XAccessibleStateSet>& rxParentStates);
......
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