Commit edcd0112 authored by Luboš Luňák's avatar Luboš Luňák
Browse files

Allow minimizing of modal dialogs, simply meaning that their main window

will be minimized too. Also don't disable the minimize animation for the dialog.
(bnc#431378)


svn path=/trunk/KDE/kdebase/workspace/; revision=908237
parent 7102a6d8
......@@ -636,11 +636,15 @@ bool Client::isMinimizable() const
if( !shown_mainwindow )
return true;
}
#if 0
// This is here because kicker's taskbar doesn't provide separate entries
// for windows with an explicitly given parent
// TODO: perhaps this should be redone
// Disabled for now, since at least modal dialogs should be minimizable
// (resulting in the mainwindow being minimized too).
if( transientFor() != NULL )
return false;
#endif
if( !wantsTabFocus() ) // SELI, TODO: - NET::Utility? why wantsTabFocus() - skiptaskbar? ?
return false;
return true;
......
......@@ -387,10 +387,15 @@ void Workspace::updateMinimizedOfTransients( Client* c )
if( !(*it)->isMinimized()
&& !(*it)->isTopMenu() ) // topmenus are not minimized, they're hidden
{
(*it)->minimize( true ); // avoid animation
(*it)->minimize();
updateMinimizedOfTransients( (*it) );
}
}
if( c->isModal()) // if a modal dialog is minimized, minimize its mainwindow too
{
foreach( Client* c2, c->mainClients())
c2->minimize();
}
}
else
{ // else unmiminize the transients
......@@ -401,10 +406,15 @@ void Workspace::updateMinimizedOfTransients( Client* c )
if( (*it)->isMinimized()
&& !(*it)->isTopMenu())
{
(*it)->unminimize( true ); // avoid animation
(*it)->unminimize();
updateMinimizedOfTransients( (*it) );
}
}
if( c->isModal())
{
foreach( Client* c2, c->mainClients())
c2->unminimize();
}
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment