summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2016-02-17 15:22:28 +0100
committerMiklos Vajna <vmiklos@collabora.co.uk>2016-02-17 16:47:36 +0100
commit946e12ac87237a1885fd3996a5549f56cc7de3a3 (patch)
tree2b7aa217f2262209623f8bcc0226430e2081be93 /sfx2
parent9da5675de3ca8a047bf45fd601522a6337efb78e (diff)
sfx2 infobar: allow setting the message style
Change-Id: I73151a78d1b396179776847d6fbb2da1dd8755e8
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/dialog/infobar.cxx10
-rw-r--r--sfx2/source/view/viewfrm.cxx5
2 files changed, 9 insertions, 6 deletions
diff --git a/sfx2/source/dialog/infobar.cxx b/sfx2/source/dialog/infobar.cxx
index b108d3bb1444..e48aaaab8201 100644
--- a/sfx2/source/dialog/infobar.cxx
+++ b/sfx2/source/dialog/infobar.cxx
@@ -132,10 +132,11 @@ SfxInfoBarWindow::SfxInfoBarWindow(vcl::Window* pParent, const OUString& sId,
const OUString& sMessage,
const basegfx::BColor* pBackgroundColor,
const basegfx::BColor* pForegroundColor,
- const basegfx::BColor* pMessageColor ) :
+ const basegfx::BColor* pMessageColor,
+ WinBits nMessageStyle ) :
Window(pParent, 0),
m_sId(sId),
- m_pMessage(VclPtr<FixedText>::Create(this, 0)),
+ m_pMessage(VclPtr<FixedText>::Create(this, nMessageStyle)),
m_pCloseBtn(VclPtr<SfxCloseButton>::Create(this)),
m_aActionBtns()
{
@@ -284,11 +285,12 @@ SfxInfoBarWindow* SfxInfoBarContainerWindow::appendInfoBar(const OUString& sId,
const OUString& sMessage,
const basegfx::BColor* pBackgroundColor,
const basegfx::BColor* pForegroundColor,
- const basegfx::BColor* pMessageColor)
+ const basegfx::BColor* pMessageColor,
+ WinBits nMessageStyle)
{
Size aSize = GetSizePixel();
- VclPtrInstance<SfxInfoBarWindow> pInfoBar(this, sId, sMessage, pBackgroundColor, pForegroundColor, pMessageColor);
+ VclPtrInstance<SfxInfoBarWindow> pInfoBar(this, sId, sMessage, pBackgroundColor, pForegroundColor, pMessageColor, nMessageStyle);
pInfoBar->SetPosPixel(Point(0, aSize.getHeight()));
pInfoBar->Show();
m_pInfoBars.push_back(pInfoBar);
diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx
index 65b8b0cc9fd1..46a718c8eefa 100644
--- a/sfx2/source/view/viewfrm.cxx
+++ b/sfx2/source/view/viewfrm.cxx
@@ -3195,7 +3195,8 @@ SfxInfoBarWindow* SfxViewFrame::AppendInfoBar( const OUString& sId,
const OUString& sMessage,
const basegfx::BColor* pBackgroundColor,
const basegfx::BColor* pForegroundColor,
- const basegfx::BColor* pMessageColor )
+ const basegfx::BColor* pMessageColor,
+ WinBits nMessageStyle )
{
const sal_uInt16 nId = SfxInfoBarContainerChild::GetChildWindowId();
@@ -3207,7 +3208,7 @@ SfxInfoBarWindow* SfxViewFrame::AppendInfoBar( const OUString& sId,
if (pChild)
{
SfxInfoBarContainerWindow* pInfoBarContainer = static_cast<SfxInfoBarContainerWindow*>(pChild->GetWindow());
- SfxInfoBarWindow* pInfoBar = pInfoBarContainer->appendInfoBar(sId, sMessage, pBackgroundColor, pForegroundColor, pMessageColor);
+ SfxInfoBarWindow* pInfoBar = pInfoBarContainer->appendInfoBar(sId, sMessage, pBackgroundColor, pForegroundColor, pMessageColor, nMessageStyle);
ShowChildWindow(nId);
return pInfoBar;
}