diff options
Diffstat (limited to 'sfx2/source/doc/objmisc.cxx')
-rw-r--r-- | sfx2/source/doc/objmisc.cxx | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/sfx2/source/doc/objmisc.cxx b/sfx2/source/doc/objmisc.cxx index 5af5ddfdf2f0..3254eb18d7b0 100644 --- a/sfx2/source/doc/objmisc.cxx +++ b/sfx2/source/doc/objmisc.cxx @@ -112,6 +112,7 @@ #include <sfx2/strings.hrc> #include <workwin.hxx> #include <sfx2/sfxdlg.hxx> +#include <sfx2/infobar.hxx> #include <appbaslib.hxx> #include <openflag.hxx> #include "objstor.hxx" @@ -202,6 +203,24 @@ void SfxObjectShell::FlushDocInfo() (delay > 0) || !url.isEmpty() ); } +void SfxObjectShell::AppendInfoBarWhenReady(const OUString& sId, const OUString& sPrimaryMessage, + const OUString& sSecondaryMessage, + InfobarType aInfobarType, bool bShowCloseButton) +{ + InfobarData aInfobarData; + aInfobarData.msId = sId; + aInfobarData.msPrimaryMessage = sPrimaryMessage; + aInfobarData.msSecondaryMessage = sSecondaryMessage; + aInfobarData.maInfobarType = aInfobarType; + aInfobarData.mbShowCloseButton = bShowCloseButton; + Get_Impl()->m_aPendingInfobars.emplace_back(aInfobarData); +} + +std::vector<InfobarData>& SfxObjectShell::getPendingInfobars() +{ + return Get_Impl()->m_aPendingInfobars; +} + void SfxObjectShell::SetError(ErrCode lErr) { if (pImpl->lErr==ERRCODE_NONE) |