[kompmgr] removed /kompmgr/ shapable tag if only the deco is shaped
svn path=/trunk/kdebase/kwin/; revision=380839
This commit is contained in:
parent
bb92b37e08
commit
270a071454
6 changed files with 20 additions and 0 deletions
|
@ -75,6 +75,9 @@ Atoms::Atoms()
|
|||
|
||||
atoms[n] = &net_wm_window_shade;
|
||||
names[n++] = (char*) "_KDE_WM_WINDOW_SHADE";
|
||||
|
||||
atoms[n] = &net_wm_window_shapable;
|
||||
names[n++] = (char*) "_KDE_WM_WINDOW_SHAPABLE";
|
||||
|
||||
Atom fake;
|
||||
atoms[n] = &fake;
|
||||
|
|
1
atoms.h
1
atoms.h
|
@ -40,6 +40,7 @@ class Atoms
|
|||
Atom net_wm_window_opacity;
|
||||
Atom net_wm_window_shadow;
|
||||
Atom net_wm_window_shade;
|
||||
Atom net_wm_window_shapable;
|
||||
Atom xdnd_aware;
|
||||
Atom xdnd_position;
|
||||
};
|
||||
|
|
13
client.cpp
13
client.cpp
|
@ -358,6 +358,7 @@ void Client::detectNoBorder()
|
|||
default:
|
||||
assert( false );
|
||||
}
|
||||
setShapable(FALSE);
|
||||
}
|
||||
|
||||
void Client::updateFrameStrut()
|
||||
|
@ -419,12 +420,18 @@ void Client::setUserNoBorder( bool set )
|
|||
void Client::updateShape()
|
||||
{
|
||||
if ( shape() )
|
||||
{
|
||||
XShapeCombineShape(qt_xdisplay(), frameId(), ShapeBounding,
|
||||
clientPos().x(), clientPos().y(),
|
||||
window(), ShapeBounding, ShapeSet);
|
||||
setShapable(TRUE);
|
||||
}
|
||||
else
|
||||
{
|
||||
XShapeCombineMask( qt_xdisplay(), frameId(), ShapeBounding, 0, 0,
|
||||
None, ShapeSet);
|
||||
setShapable(TRUE);
|
||||
}
|
||||
// workaround for #19644 - shaped windows shouldn't have decoration
|
||||
if( shape() && !noBorder())
|
||||
{
|
||||
|
@ -467,6 +474,12 @@ QRegion Client::mask() const
|
|||
return QRegion( 0, 0, width(), height());
|
||||
return _mask;
|
||||
}
|
||||
|
||||
void Client::setShapable(bool b)
|
||||
{
|
||||
uint tmp = b?1:0;
|
||||
XChangeProperty(qt_xdisplay(), frameId(), atoms->net_wm_window_shapable, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &tmp, 1L);
|
||||
}
|
||||
|
||||
void Client::hideClient( bool hide )
|
||||
{
|
||||
|
|
1
client.h
1
client.h
|
@ -292,6 +292,7 @@ class Client : public QObject, public KDecorationDefines
|
|||
bool isBMP();
|
||||
void setBMP(bool b);
|
||||
bool touches(const Client* c);
|
||||
void setShapable(bool b);
|
||||
|
||||
private slots:
|
||||
void autoRaise();
|
||||
|
|
|
@ -186,6 +186,7 @@ unsigned long Options::updateSettings()
|
|||
activeWindowShadowSize = config->readNumEntry("ActiveWindowShadowSize", 100);
|
||||
inactiveWindowShadowSize = config->readNumEntry("InactiveWindowShadowSize", 100);
|
||||
dockShadowSize = config->readNumEntry("DockShadowSize", 100);
|
||||
removeShadowsOnResize = config->readBoolEntry("RemoveShadowsOnResize", true);
|
||||
if (resetKompmgr = config->readBoolEntry("ResetKompmgr", false))
|
||||
config->writeEntry("ResetKompmgr",FALSE);
|
||||
|
||||
|
|
|
@ -264,6 +264,7 @@ class Options : public KDecorationOptions
|
|||
uint inactiveWindowOpacity;
|
||||
bool translucentMovingWindows;
|
||||
uint movingWindowOpacity;
|
||||
bool removeShadowsOnResize;
|
||||
bool translucentDocks;
|
||||
uint dockOpacity;
|
||||
bool keepAboveAsActive;
|
||||
|
|
Loading…
Reference in a new issue