tdf#125384 allow setting initial tabpage before dialog is running

Change-Id: I79ad38e05e6b66089a0ed47d4054d416b8c61ff8
Reviewed-on: https://gerrit.libreoffice.org/72633
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
diff --git a/sfx2/source/dialog/tabdlg.cxx b/sfx2/source/dialog/tabdlg.cxx
index 65d0e1e..32ab60c 100644
--- a/sfx2/source/dialog/tabdlg.cxx
+++ b/sfx2/source/dialog/tabdlg.cxx
@@ -1535,9 +1535,8 @@ IMPL_LINK(SfxTabDialogController, DeactivatePageHdl, const OString&, rPage, bool
    }

    VclPtr<SfxTabPage> pPage = pDataObject->pTabPage;
    DBG_ASSERT( pPage, "no active Page" );
    if (!pPage)
        return false;
        return true;

    DeactivateRC nRet = DeactivateRC::LeavePage;