diff options
author | Bogdan Buzea <buzea.bogdan@libreoffice.org> | 2024-10-21 08:25:34 +0200 |
---|---|---|
committer | David Gilbert <freedesktop@treblig.org> | 2024-10-27 01:24:45 +0200 |
commit | a74ef20928828d5879f136bf075e4a3e1f3f451e (patch) | |
tree | b2c48c442454e0c941f082220d41db094c27dc25 /dbaccess | |
parent | 3c9715a64c6552f3b4e920a435fa1ad10489882b (diff) |
tdf#163486: PVS: Identical branches
V1037 Two or more case-branches perform the same actions. Check lines: 817, 830
V1037 Two or more case-branches perform the same actions. Check lines: 1251, 1254
Change-Id: I4e121ec3b0c4465f5637b114d2e91e5b639c398c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175276
Tested-by: Jenkins
Reviewed-by: David Gilbert <freedesktop@treblig.org>
Diffstat (limited to 'dbaccess')
-rw-r--r-- | dbaccess/source/ui/app/AppController.cxx | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/dbaccess/source/ui/app/AppController.cxx b/dbaccess/source/ui/app/AppController.cxx index c433f8c83f44..ed10f38e660b 100644 --- a/dbaccess/source/ui/app/AppController.cxx +++ b/dbaccess/source/ui/app/AppController.cxx @@ -814,6 +814,8 @@ FeatureState OApplicationController::GetState(sal_uInt16 _nId) const aReturn.bChecked = getContainer()->getPreviewMode() == PreviewMode::Document; break; case ID_BROWSER_UNDO: + case SID_DB_APP_SENDREPORTTOWRITER: + case SID_DB_APP_DBADMIN: aReturn.bEnabled = false; break; case SID_MAIL_SENDDOC: @@ -825,10 +827,6 @@ FeatureState OApplicationController::GetState(sal_uInt16 _nId) const aReturn.bEnabled = E_REPORT == eType && getContainer()->getSelectionCount() > 0 && getContainer()->isALeafSelected(); } break; - case SID_DB_APP_SENDREPORTTOWRITER: - case SID_DB_APP_DBADMIN: - aReturn.bEnabled = false; - break; case SID_DB_APP_STATUS_TYPE: aReturn.bEnabled = m_xDataSource.is(); if ( aReturn.bEnabled ) @@ -1248,8 +1246,6 @@ void OApplicationController::Execute(sal_uInt16 _nId, const Sequence< PropertyVa case SID_DB_APP_QUERY_OPEN: case SID_DB_APP_FORM_OPEN: case SID_DB_APP_REPORT_OPEN: - doAction( _nId, ElementOpenMode::Normal ); - break; case SID_DB_APP_CONVERTTOVIEW: doAction( _nId, ElementOpenMode::Normal ); break; |