fixed drawFloatFrame for shaded maximized windows

svn path=/trunk/KDE/kdebase/workspace/; revision=1032310
This commit is contained in:
Hugo Pereira Da Costa 2009-10-07 14:23:14 +00:00
parent ac18f02c48
commit f957a7b7cd
4 changed files with 22 additions and 6 deletions

View file

@ -1,3 +1,14 @@
# $Id: CMakeLists.txt,v 1.39 2009/09/13 00:33:34 hpereira Exp $
find_package (KDE4 REQUIRED)
add_definitions (-DQT3_SUPPORT -DQT3_SUPPORT_WARNINGS)
include (KDE4Defaults)
include (MacroLibrary)
add_definitions (${QT_DEFINITIONS} ${KDE4_DEFINITIONS})
include_directories (${KDE4_INCLUDES} ${CMAKE_BINARY_DIR})
########### add version number into compilation defines
add_definitions ( -DAPP_VERSION=\\\"${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}\\\")
add_subdirectory( config )
@ -30,5 +41,5 @@ target_link_libraries(
install(TARGETS kwin3_oxygen DESTINATION ${PLUGIN_INSTALL_DIR} )
########### install files ###############
install( FILES oxygenclient.desktop DESTINATION ${DATA_INSTALL_DIR}/kwin/ )
install( FILES oxygenclient.desktop DESTINATION ${DATA_INSTALL_DIR}/kwin/ )

View file

@ -63,6 +63,10 @@ namespace Oxygen
ButtonTypeCount
};
#if !KDE_IS_VERSION(4,3,90)
enum{ SettingCompositing = 1 << 6 };
#endif
//! maximum index/frame used for animations
static const int maxAnimationIndex = 256;

View file

@ -189,8 +189,8 @@ namespace Oxygen
{ client_.renderSeparator( &painter, rect(), this, color ); }
// translate buttons up if window maximized
if(client_.isMaximized())
{ painter.translate( 0, -1 ); }
// if(client_.isMaximized())
// { painter.translate( 0, -1 ); }
// for menu button the application icon is used
if (type_ == ButtonMenu)

View file

@ -933,11 +933,12 @@ namespace Oxygen
} else if( isShade() ) {
// adjust frame so that only the bottom part of the frame is drawn
// for shaded maximized windows adjust frame and draw the bottom part of it
helper().drawFloatFrame(
&painter, frame.adjusted( -4, -4, 4, 0 ), backgroundPalette( widget(), palette ).color( widget()->backgroundRole() ),
&painter, frame.adjusted( -4, 0, 4, 0 ), backgroundPalette( widget(), palette ).color( widget()->backgroundRole() ),
!compositingActive(), isActive(),
KDecoration::options()->color(ColorTitleBar)
KDecoration::options()->color(ColorTitleBar),
TileSet::Bottom
);
}