Ok, one more subtle fix: If the WM_CLASS components differ, use complete
WM_CLASS. This allows e.g. having extra settings for one specific Konsole, all that's needed is to launch it as "konsole -name konsole_special", and make KWin's window-specific settings match for complete window class "konsole_special konsole". Generic Konsole settings will apply to all Konsole's, while these specific ones will apply only to instances using -name. The nice advantage is this shouldn't have all those weird issues kstart has (die, kstart, die!). svn path=/trunk/kdebase/kwin/; revision=360769
This commit is contained in:
parent
27be3a1885
commit
a24fc0b2a0
1 changed files with 13 additions and 3 deletions
|
@ -150,11 +150,21 @@ static Rules* findRule( const QValueList< Rules* >& rules, Window wid )
|
|||
if( !role.isEmpty()
|
||||
&& role != "unknown" && role != "unnamed" ) // Qt sets this if not specified
|
||||
{
|
||||
ret->wmclasscomplete = false;
|
||||
ret->wmclass = wmclass_class;
|
||||
ret->wmclassmatch = Rules::ExactMatch;
|
||||
ret->windowrole = role;
|
||||
ret->windowrolematch = Rules::ExactMatch;
|
||||
if( wmclass_name == wmclass_class )
|
||||
{
|
||||
ret->wmclasscomplete = false;
|
||||
ret->wmclass = wmclass_class;
|
||||
ret->wmclassmatch = Rules::ExactMatch;
|
||||
}
|
||||
else
|
||||
{
|
||||
// WM_CLASS components differ - perhaps the app got -name argument
|
||||
ret->wmclasscomplete = true;
|
||||
ret->wmclass = wmclass_name + ' ' + wmclass_class;
|
||||
ret->wmclassmatch = Rules::ExactMatch;
|
||||
}
|
||||
}
|
||||
else // no role set
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue