[oxygen] Use KCommonDecoration::palette() to get the QPalette to use

Instead of getting the palette of the widget we access the decoration
to have Oxygen follow the color scheme defined on a window.
icc-effect-5.14.5
Martin Gräßlin 2013-10-14 07:23:54 +02:00
parent 23a510c0b5
commit 7360d5b79e
2 changed files with 2 additions and 2 deletions

View File

@ -113,7 +113,7 @@ namespace Oxygen
void Button::paint( QPainter& painter )
{
QPalette palette( this->palette() );
QPalette palette( _client.palette() );
palette.setCurrentColorGroup( isActive() ? QPalette::Active : QPalette::Inactive);
if(

View File

@ -1531,7 +1531,7 @@ namespace Oxygen
{
// palette
QPalette palette = widget()->palette();
QPalette palette = KCommonDecoration::palette();
palette.setCurrentColorGroup( (isActive() ) ? QPalette::Active : QPalette::Inactive );
// define frame