summaryrefslogtreecommitdiff
path: root/sfx2/source
diff options
context:
space:
mode:
Diffstat (limited to 'sfx2/source')
-rw-r--r--sfx2/source/dialog/infobar.cxx13
-rw-r--r--sfx2/source/view/viewfrm.cxx8
2 files changed, 16 insertions, 5 deletions
diff --git a/sfx2/source/dialog/infobar.cxx b/sfx2/source/dialog/infobar.cxx
index f34f23cfcfa5..b108d3bb1444 100644
--- a/sfx2/source/dialog/infobar.cxx
+++ b/sfx2/source/dialog/infobar.cxx
@@ -131,7 +131,8 @@ void SfxCloseButton::setForegroundColor(const basegfx::BColor& rColor)
SfxInfoBarWindow::SfxInfoBarWindow(vcl::Window* pParent, const OUString& sId,
const OUString& sMessage,
const basegfx::BColor* pBackgroundColor,
- const basegfx::BColor* pForegroundColor ) :
+ const basegfx::BColor* pForegroundColor,
+ const basegfx::BColor* pMessageColor ) :
Window(pParent, 0),
m_sId(sId),
m_pMessage(VclPtr<FixedText>::Create(this, 0)),
@@ -149,6 +150,8 @@ SfxInfoBarWindow::SfxInfoBarWindow(vcl::Window* pParent, const OUString& sId,
m_aForegroundColor = *pForegroundColor;
static_cast<SfxCloseButton*>(m_pCloseBtn.get())->setForegroundColor(m_aForegroundColor);
}
+ if (pMessageColor)
+ m_pMessage->SetControlForeground(Color(*pMessageColor));
sal_Int32 nScaleFactor = GetDPIScaleFactor();
long nWidth = pParent->GetSizePixel().getWidth();
@@ -277,11 +280,15 @@ void SfxInfoBarContainerWindow::dispose()
Window::dispose();
}
-SfxInfoBarWindow* SfxInfoBarContainerWindow::appendInfoBar(const OUString& sId, const OUString& sMessage, const basegfx::BColor* pBackgroundColor, const basegfx::BColor* pForegroundColor)
+SfxInfoBarWindow* SfxInfoBarContainerWindow::appendInfoBar(const OUString& sId,
+ const OUString& sMessage,
+ const basegfx::BColor* pBackgroundColor,
+ const basegfx::BColor* pForegroundColor,
+ const basegfx::BColor* pMessageColor)
{
Size aSize = GetSizePixel();
- VclPtrInstance<SfxInfoBarWindow> pInfoBar(this, sId, sMessage, pBackgroundColor, pForegroundColor);
+ VclPtrInstance<SfxInfoBarWindow> pInfoBar(this, sId, sMessage, pBackgroundColor, pForegroundColor, pMessageColor);
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 068bbcd891bb..65b8b0cc9fd1 100644
--- a/sfx2/source/view/viewfrm.cxx
+++ b/sfx2/source/view/viewfrm.cxx
@@ -3191,7 +3191,11 @@ void SfxViewFrame::SetViewFrame( SfxViewFrame* pFrame )
SfxGetpApp()->SetViewFrame_Impl( pFrame );
}
-SfxInfoBarWindow* SfxViewFrame::AppendInfoBar( const OUString& sId, const OUString& sMessage, const basegfx::BColor* pBackgroundColor, const basegfx::BColor* pForegroundColor )
+SfxInfoBarWindow* SfxViewFrame::AppendInfoBar( const OUString& sId,
+ const OUString& sMessage,
+ const basegfx::BColor* pBackgroundColor,
+ const basegfx::BColor* pForegroundColor,
+ const basegfx::BColor* pMessageColor )
{
const sal_uInt16 nId = SfxInfoBarContainerChild::GetChildWindowId();
@@ -3203,7 +3207,7 @@ SfxInfoBarWindow* SfxViewFrame::AppendInfoBar( const OUString& sId, const OUStri
if (pChild)
{
SfxInfoBarContainerWindow* pInfoBarContainer = static_cast<SfxInfoBarContainerWindow*>(pChild->GetWindow());
- SfxInfoBarWindow* pInfoBar = pInfoBarContainer->appendInfoBar(sId, sMessage, pBackgroundColor, pForegroundColor);
+ SfxInfoBarWindow* pInfoBar = pInfoBarContainer->appendInfoBar(sId, sMessage, pBackgroundColor, pForegroundColor, pMessageColor);
ShowChildWindow(nId);
return pInfoBar;
}