void OBClient::shapeHandler(const XShapeEvent &e)
{
otk::OtkEventHandler::shapeHandler(e);
-
- _shaped = e.shaped;
- frame->adjustShape();
+
+ if (e.kind == ShapeBounding) {
+ _shaped = e.shaped;
+ frame->adjustShape();
+ }
}
#endif
_area.setPos(x, y);
// move the frame to be in the requested position
- frame->adjustPosition();
+ if (frame) // this can be called while mapping, before frame exists
+ frame->adjustPosition();
}
void OBClient::unmapHandler(const XUnmapEvent &e)
{
+ if (ignore_unmaps) {
#ifdef DEBUG
- printf("UnmapNotify for 0x%lx\n", e.window);
+ printf("Ignored UnmapNotify for 0x%lx (event 0x%lx)\n", e.window, e.event);
#endif // DEBUG
-
- if (ignore_unmaps) {
ignore_unmaps--;
return;
}
+#ifdef DEBUG
+ printf("UnmapNotify for 0x%lx\n", e.window);
+#endif // DEBUG
+
OtkEventHandler::unmapHandler(e);
// this deletes us etc