vcl/source/window/menu.cxx | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-)
New commits: commit 5c147fc5fe0e77838b8e9bebd4ff215a80946980 Author: Xisco Fauli <xiscofa...@libreoffice.org> AuthorDate: Sun Oct 21 23:00:35 2018 +0200 Commit: Caolán McNamara <caol...@redhat.com> CommitDate: Mon Oct 22 12:43:08 2018 +0200 tdf#120703 (PVS): Recurring check. V571 The '!aDelData.isDeleted()' condition was already verified in line 359. Change-Id: Ie66aa65c024e30d34a4b0766ddad3fa24ce98644 Reviewed-on: https://gerrit.libreoffice.org/62163 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caol...@redhat.com> Tested-by: Caolán McNamara <caol...@redhat.com> diff --git a/vcl/source/window/menu.cxx b/vcl/source/window/menu.cxx index ba1138205a29..bcbca81b7c01 100644 --- a/vcl/source/window/menu.cxx +++ b/vcl/source/window/menu.cxx @@ -356,19 +356,18 @@ void Menu::Select() ImplMenuDelData aDelData( this ); ImplCallEventListeners( VclEventId::MenuSelect, GetItemPos( GetCurItemId() ) ); - if ( !aDelData.isDeleted() && !aSelectHdl.Call( this ) ) - { - if( !aDelData.isDeleted() ) - { - Menu* pStartMenu = ImplGetStartMenu(); - if ( pStartMenu && ( pStartMenu != this ) ) - { - pStartMenu->nSelectedId = nSelectedId; - pStartMenu->sSelectedIdent = sSelectedIdent; - pStartMenu->aSelectHdl.Call( this ); - } - } - } + if (aDelData.isDeleted()) + return; + if (aSelectHdl.Call(this)) + return; + if (aDelData.isDeleted()) + return; + Menu* pStartMenu = ImplGetStartMenu(); + if (!pStartMenu || (pStartMenu == this)) + return; + pStartMenu->nSelectedId = nSelectedId; + pStartMenu->sSelectedIdent = sSelectedIdent; + pStartMenu->aSelectHdl.Call( this ); } #if defined(MACOSX) _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits