CVS_SILENT removed exception for KDE 3.1 which worked around a problem of "eating" window borders,
no more necessary. svn path=/trunk/kdeartwork/kwin-styles/plastik/; revision=246927
This commit is contained in:
parent
013f743897
commit
b7547a0a87
1 changed files with 27 additions and 80 deletions
|
@ -669,87 +669,34 @@ void PlastikClient::maximizeChange(bool m)
|
||||||
{
|
{
|
||||||
if (!PlastikHandler::initialized()) return;
|
if (!PlastikHandler::initialized()) return;
|
||||||
|
|
||||||
// ifdef stuff doesn't seem to work.... whatever, this should now work great for all users
|
if( m && (maximizeMode() == MaximizeFull) && PlastikHandler::shrinkBorders() )
|
||||||
// except the kde cvs users who play around with the resize&move max. windows setting! :-)
|
{
|
||||||
|
topSpacer_->changeSize(1, 0, QSizePolicy::Expanding, QSizePolicy::Fixed);
|
||||||
|
bottomSpacer_->changeSize(1, 3, QSizePolicy::Expanding, QSizePolicy::Fixed);
|
||||||
|
leftSpacer_->changeSize(0, 1, QSizePolicy::Fixed, QSizePolicy::Expanding);
|
||||||
|
rightSpacer_->changeSize(0, 1, QSizePolicy::Fixed, QSizePolicy::Expanding);
|
||||||
|
|
||||||
// #if defined(KDE_MAKE_VERSION)
|
leftTitleSpacer_->changeSize(0, s_titleHeight,
|
||||||
// # if KDE_VERSION >= KDE_MAKE_VERSION(3,1,0)
|
QSizePolicy::Fixed, QSizePolicy::Fixed);
|
||||||
// if( m && (maximizeMode() == MaximizeFull) && PlastikHandler::shrinkBorders() )
|
rightTitleSpacer_->changeSize(0, s_titleHeight,
|
||||||
// {
|
QSizePolicy::Fixed, QSizePolicy::Fixed);
|
||||||
// topSpacer_->changeSize(1, 0, QSizePolicy::Expanding, QSizePolicy::Fixed);
|
}
|
||||||
// bottomSpacer_->changeSize(1, 3, QSizePolicy::Expanding, QSizePolicy::Fixed);
|
else
|
||||||
// leftSpacer_->changeSize(0, 1, QSizePolicy::Fixed, QSizePolicy::Expanding);
|
{
|
||||||
// rightSpacer_->changeSize(0, 1, QSizePolicy::Fixed, QSizePolicy::Expanding);
|
topSpacer_->changeSize(1, TOPMARGIN, QSizePolicy::Expanding, QSizePolicy::Fixed);
|
||||||
//
|
bottomSpacer_->changeSize(1, PlastikHandler::borderSize(),
|
||||||
// leftTitleSpacer_->changeSize(0, s_titleHeight,
|
QSizePolicy::Expanding, QSizePolicy::Fixed);
|
||||||
// QSizePolicy::Fixed, QSizePolicy::Fixed);
|
leftSpacer_->changeSize(PlastikHandler::borderSize(), 1,
|
||||||
// rightTitleSpacer_->changeSize(0, s_titleHeight,
|
QSizePolicy::Fixed, QSizePolicy::Expanding);
|
||||||
// QSizePolicy::Fixed, QSizePolicy::Fixed);
|
rightSpacer_->changeSize(PlastikHandler::borderSize(), 1,
|
||||||
// }
|
QSizePolicy::Fixed, QSizePolicy::Expanding);
|
||||||
// else
|
leftTitleSpacer_->changeSize(SIDETITLEMARGIN, s_titleHeight,
|
||||||
// {
|
QSizePolicy::Fixed, QSizePolicy::Fixed);
|
||||||
// topSpacer_->changeSize(1, TOPMARGIN, QSizePolicy::Expanding, QSizePolicy::Fixed);
|
rightTitleSpacer_->changeSize(SIDETITLEMARGIN, s_titleHeight,
|
||||||
// bottomSpacer_->changeSize(1, PlastikHandler::borderSize(),
|
QSizePolicy::Fixed, QSizePolicy::Fixed);
|
||||||
// QSizePolicy::Expanding, QSizePolicy::Fixed);
|
}
|
||||||
// leftSpacer_->changeSize(PlastikHandler::borderSize(), 1,
|
layout()->activate();
|
||||||
// QSizePolicy::Fixed, QSizePolicy::Expanding);
|
repaint( false );
|
||||||
// rightSpacer_->changeSize(PlastikHandler::borderSize(), 1,
|
|
||||||
// QSizePolicy::Fixed, QSizePolicy::Expanding);
|
|
||||||
// leftTitleSpacer_->changeSize(SIDETITLEMARGIN, s_titleHeight,
|
|
||||||
// QSizePolicy::Fixed, QSizePolicy::Fixed);
|
|
||||||
// rightTitleSpacer_->changeSize(SIDETITLEMARGIN, s_titleHeight,
|
|
||||||
// QSizePolicy::Fixed, QSizePolicy::Fixed);
|
|
||||||
// }
|
|
||||||
// layout()->activate();
|
|
||||||
// repaint( false );
|
|
||||||
// # else
|
|
||||||
/* In KDE 3.1, KWIN cuts the side borders if the option "resize and move maximized
|
|
||||||
* windows" is disabled (this behaviour seems to be abolished for KDE CVS).
|
|
||||||
* When we addidtionally remove the borders by our selves, this results in cutting
|
|
||||||
* parts of the UI. Bad!
|
|
||||||
* Let's try to handle this strange behaviour...
|
|
||||||
*/
|
|
||||||
if( m && (maximizeMode() == MaximizeFull) && PlastikHandler::shrinkBorders() )
|
|
||||||
{
|
|
||||||
topSpacer_->changeSize(1, 0, QSizePolicy::Expanding, QSizePolicy::Fixed);
|
|
||||||
bottomSpacer_->changeSize(1, 3, QSizePolicy::Expanding, QSizePolicy::Fixed);
|
|
||||||
if (! options->moveResizeMaximizedWindows) {
|
|
||||||
// normal size! KWin then cuts these borders on its own
|
|
||||||
leftSpacer_->changeSize(PlastikHandler::borderSize(), 1, QSizePolicy::Fixed, QSizePolicy::Expanding);
|
|
||||||
rightSpacer_->changeSize(PlastikHandler::borderSize(), 1, QSizePolicy::Fixed, QSizePolicy::Expanding);
|
|
||||||
|
|
||||||
leftTitleSpacer_->changeSize(PlastikHandler::borderSize(), s_titleHeight,
|
|
||||||
QSizePolicy::Fixed, QSizePolicy::Fixed);
|
|
||||||
rightTitleSpacer_->changeSize(PlastikHandler::borderSize(), s_titleHeight,
|
|
||||||
QSizePolicy::Fixed, QSizePolicy::Fixed);
|
|
||||||
} else {
|
|
||||||
leftSpacer_->changeSize(0, 1, QSizePolicy::Fixed, QSizePolicy::Expanding);
|
|
||||||
rightSpacer_->changeSize(0, 1, QSizePolicy::Fixed, QSizePolicy::Expanding);
|
|
||||||
|
|
||||||
leftTitleSpacer_->changeSize(0, s_titleHeight,
|
|
||||||
QSizePolicy::Fixed, QSizePolicy::Fixed);
|
|
||||||
rightTitleSpacer_->changeSize(0, s_titleHeight,
|
|
||||||
QSizePolicy::Fixed, QSizePolicy::Fixed);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
topSpacer_->changeSize(1, TOPMARGIN, QSizePolicy::Expanding, QSizePolicy::Fixed);
|
|
||||||
bottomSpacer_->changeSize(1, PlastikHandler::borderSize(),
|
|
||||||
QSizePolicy::Expanding, QSizePolicy::Fixed);
|
|
||||||
leftSpacer_->changeSize(PlastikHandler::borderSize(), 1,
|
|
||||||
QSizePolicy::Fixed, QSizePolicy::Expanding);
|
|
||||||
rightSpacer_->changeSize(PlastikHandler::borderSize(), 1,
|
|
||||||
QSizePolicy::Fixed, QSizePolicy::Expanding);
|
|
||||||
leftTitleSpacer_->changeSize(SIDETITLEMARGIN, s_titleHeight,
|
|
||||||
QSizePolicy::Fixed, QSizePolicy::Fixed);
|
|
||||||
rightTitleSpacer_->changeSize(SIDETITLEMARGIN, s_titleHeight,
|
|
||||||
QSizePolicy::Fixed, QSizePolicy::Fixed);
|
|
||||||
}
|
|
||||||
layout()->activate();
|
|
||||||
repaint( false );
|
|
||||||
// # endif
|
|
||||||
// #endif
|
|
||||||
|
|
||||||
if (m_button[ButtonMax])
|
if (m_button[ButtonMax])
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue