summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAbdiel Janulgue <abdiel.janulgue@nokia.com>2010-09-14 13:31:09 +0300
committerAbdiel Janulgue <abdiel.janulgue@nokia.com>2010-09-14 13:31:09 +0300
commite7bd46b423eeef5e2a2611175f2f8b29796358a7 (patch)
tree533d40e552621579127fb2e5c7b932016f7c878c
parentd4f20c59ecb1bfa85f0c868886f8a96311449ab9 (diff)
Fixes: NB#180786 - QWidget::show() does not fire subsequent X11 window map requests0.6.1-1
Details: Use SaveSets in maprequest in case WM crashes, window is still visible RevBy: TrustMe
-rw-r--r--debian/changelog6
-rw-r--r--src/mcompositemanager.cpp15
2 files changed, 15 insertions, 6 deletions
diff --git a/debian/changelog b/debian/changelog
index b504d84..f732a83 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+mcompositor (0.6.1-1) unstable; urgency=low
+
+ * Fixes: NB#180786 - QWidget::show() does not fire subsequent X11 window map requests
+
+ -- Abdiel Janulgue <abj@codefuassasin.research.nokia.com> Tue, 14 Sep 2010 13:29:10 +0300
+
mcompositor (0.6.0-1) unstable; urgency=low
* Fixes: NB#186402 - The application is getting minimized on clicking close button
diff --git a/src/mcompositemanager.cpp b/src/mcompositemanager.cpp
index 1aee9d7..61bbd05 100644
--- a/src/mcompositemanager.cpp
+++ b/src/mcompositemanager.cpp
@@ -1020,6 +1020,8 @@ void MCompositeManagerPrivate::unmapEvent(XUnmapEvent *e)
wpc = prop_caches.value(e->window);
wpc->setBeingMapped(false);
wpc->setIsMapped(false);
+ if (!wpc->isInputOnly())
+ XRemoveFromSaveSet(QX11Info::display(), e->window);
}
// do not keep unmapped windows in windows_as_mapped list
@@ -1076,7 +1078,6 @@ void MCompositeManagerPrivate::unmapEvent(XUnmapEvent *e)
XReparentWindow(QX11Info::display(), e->window,
RootWindow(QX11Info::display(), 0), 0, 0);
setWindowState(e->window, IconicState);
- XRemoveFromSaveSet(QX11Info::display(), e->window);
framed_windows.remove(e->window);
XUngrabServer(QX11Info::display());
delete fd.frame;
@@ -1326,6 +1327,8 @@ void MCompositeManagerPrivate::mapRequestEvent(XMapRequestEvent *e)
// we know the parent due to SubstructureRedirectMask on root window
pc->setParentWindow(RootWindow(dpy, 0));
}
+ if(!pc->isInputOnly())
+ XAddToSaveSet(QX11Info::display(), e->window);
MCompAtoms::Type wtype = pc->windowType();
QRect a = pc->realGeometry();
@@ -1382,8 +1385,6 @@ void MCompositeManagerPrivate::mapRequestEvent(XMapRequestEvent *e)
pc->setBeingMapped(true);
if (needDecoration(e->window, pc)) {
- XAddToSaveSet(QX11Info::display(), e->window);
-
if (MDecoratorFrame::instance()->decoratorItem()) {
enableCompositing();
MapRequesterPrivate::instance()->requestMap(e->window);
@@ -2003,12 +2004,13 @@ void MCompositeManagerPrivate::mapEvent(XMapEvent *e)
pc = item->propertyCache();
if (!pc) return;
}
- // Compositing is assumed to be enabled at this point if a window
+ // Compositing is always assumed to be enabled at this point if a window
// has alpha channels
if (!compositing && (pc && pc->hasAlpha())) {
qWarning("mapEvent(): compositing not enabled!");
- return;
+ enableCompositing(true);
}
+
if (item && pc) {
if (wtype == MCompAtoms::NORMAL)
pc->setWindowTypeAtom(ATOM(_NET_WM_WINDOW_TYPE_NORMAL));
@@ -3246,7 +3248,8 @@ bool MCompositeManager::isCompositing()
void MCompositeManager::debug(const QString& d)
{
- _log("%s\n", d.toAscii());
+ const char* msg = d.toAscii();
+ _log("%s\n", msg);
}
#include "mcompositemanager.moc"