[Libreoffice-commits] .: vcl/inc vcl/source vcl/unx
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Mon Dec 3 05:40:52 PST 2012
vcl/inc/svdata.hxx | 3 +++
vcl/source/control/ilstbox.cxx | 16 +++++++++++++---
vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx | 2 ++
3 files changed, 18 insertions(+), 3 deletions(-)
New commits:
commit 9ea7b2053eea6cf9e97f4846d97f741eed426033
Author: Ivan Timofeev <timofeev.i.s at gmail.com>
Date: Mon Dec 3 17:27:14 2012 +0400
fdo#45651: fix drop down listbox text color with dark gtk theme
Change-Id: I9ba0b27924d1698bad2c34da75fff57f75a737f0
diff --git a/vcl/inc/svdata.hxx b/vcl/inc/svdata.hxx
index 974a67f..f7dcbd6 100644
--- a/vcl/inc/svdata.hxx
+++ b/vcl/inc/svdata.hxx
@@ -295,6 +295,9 @@ struct ImplSVNWFData
// window background before drawing the native
// checkbox
bool mbCanDrawWidgetAnySize:1; // set to true currently on gtk
+
+ /// entire drop down listbox resembles a button, no textarea/button parts (as currently on Windows)
+ bool mbDDListBoxNoTextArea:1;
};
diff --git a/vcl/source/control/ilstbox.cxx b/vcl/source/control/ilstbox.cxx
index 34fd3fb..e7bbca6 100644
--- a/vcl/source/control/ilstbox.cxx
+++ b/vcl/source/control/ilstbox.cxx
@@ -2918,10 +2918,20 @@ void ImplWin::ImplDraw( bool bLayout )
else
{
Color aColor;
- if( bNativeOK && (nState & CTRL_STATE_ROLLOVER) )
- aColor = rStyleSettings.GetFieldRolloverTextColor();
+ if( ImplGetSVData()->maNWFData.mbDDListBoxNoTextArea )
+ {
+ if( bNativeOK && (nState & CTRL_STATE_ROLLOVER) )
+ aColor = rStyleSettings.GetButtonRolloverTextColor();
+ else
+ aColor = rStyleSettings.GetButtonTextColor();
+ }
else
- aColor = rStyleSettings.GetFieldTextColor();
+ {
+ if( bNativeOK && (nState & CTRL_STATE_ROLLOVER) )
+ aColor = rStyleSettings.GetFieldRolloverTextColor();
+ else
+ aColor = rStyleSettings.GetFieldTextColor();
+ }
if( IsControlForeground() )
aColor = GetControlForeground();
SetTextColor( aColor );
diff --git a/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx b/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
index 839750d..46a4c01 100644
--- a/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
+++ b/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
@@ -428,6 +428,8 @@ void GtkData::initNWF( void )
// omit GetNativeControl while painting (see brdwin.cxx)
pSVData->maNWFData.mbCanDrawWidgetAnySize = true;
+ pSVData->maNWFData.mbDDListBoxNoTextArea = true;
+
int nScreens = GetGtkSalData()->GetGtkDisplay()->GetXScreenCount();
gWidgetData = WidgetDataVector( nScreens );
for( int i = 0; i < nScreens; i++ )
More information about the Libreoffice-commits
mailing list