diff options
author | Armin Le Grand (Allotropia) <armin.le.grand@me.com> | 2021-06-09 13:33:26 +0200 |
---|---|---|
committer | Armin Le Grand <Armin.Le.Grand@me.com> | 2021-06-09 17:12:59 +0200 |
commit | bcc28948d0fd7b4f005a13db923c3e853d74817c (patch) | |
tree | 513f3b35c4d2c020bbca221ffb4861b01dcbfb9f /cui | |
parent | 33b4198735af8d9398e63887187b86b4176cac82 (diff) |
tdf#130428 remove unnecessary usage of SfxItemState::UNKNOWN
See task, slowly trying to reduce usages of that flag
Change-Id: I50dc8e21e2f5e82e21bf335d63d07cee1ee18d01
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116913
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
Tested-by: Jenkins
Diffstat (limited to 'cui')
-rw-r--r-- | cui/source/options/optpath.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/cui/source/options/optpath.cxx b/cui/source/options/optpath.cxx index e1f638faa673..e0f940219016 100644 --- a/cui/source/options/optpath.cxx +++ b/cui/source/options/optpath.cxx @@ -77,14 +77,14 @@ namespace { struct PathUserData_Impl { SvtPathOptions::Paths nRealId; - SfxItemState eState; + bool bItemStateSet; OUString sUserPath; OUString sWritablePath; bool bReadOnly; explicit PathUserData_Impl(SvtPathOptions::Paths nId) : nRealId(nId) - , eState(SfxItemState::UNKNOWN) + , bItemStateSet(false) , bReadOnly(false) { } @@ -227,7 +227,7 @@ bool SvxPathTabPage::FillItemSet( SfxItemSet* ) { PathUserData_Impl* pPathImpl = reinterpret_cast<PathUserData_Impl*>(m_xPathBox->get_id(i).toInt64()); SvtPathOptions::Paths nRealId = pPathImpl->nRealId; - if (pPathImpl->eState == SfxItemState::SET) + if (pPathImpl->bItemStateSet ) SetPathList( nRealId, pPathImpl->sUserPath, pPathImpl->sWritablePath ); } return true; @@ -403,7 +403,7 @@ IMPL_LINK_NOARG(SvxPathTabPage, StandardHdl_Impl, weld::Button&, void) } } m_xPathBox->set_text(rEntry, Convert_Impl(sTemp), 1); - pPathImpl->eState = SfxItemState::SET; + pPathImpl->bItemStateSet = true; pPathImpl->sUserPath = sUserPath.makeStringAndClear(); pPathImpl->sWritablePath = sWritablePath; } @@ -448,7 +448,7 @@ void SvxPathTabPage::ChangeCurrentEntry( const OUString& _rFolder ) return; m_xPathBox->set_text(nEntry, Convert_Impl(sNewPathStr), 1); - pPathImpl->eState = SfxItemState::SET; + pPathImpl->bItemStateSet = true; pPathImpl->sWritablePath = sNewPathStr; if ( SvtPathOptions::Paths::Work == pPathImpl->nRealId ) { @@ -530,7 +530,7 @@ IMPL_LINK_NOARG(SvxPathTabPage, PathHdl_Impl, weld::Button&, void) m_xPathBox->set_text(nEntry, Convert_Impl(sFullPath), 1); // save modified flag - pPathImpl->eState = SfxItemState::SET; + pPathImpl->bItemStateSet = true; pPathImpl->sUserPath = sUser; pPathImpl->sWritablePath = sWritable; } |