From 91d2ddc0fc80007c2f130788672d28c4e6d6abd5 Mon Sep 17 00:00:00 2001 From: Rik Hemsley Date: Sat, 28 Oct 2000 02:32:07 +0000 Subject: [PATCH] New anim for qwertz, it's no. 2, so IconifyAnimationStyle=2 in [WM] section of kdeglobals will enable it. svn path=/trunk/kdebase/kwin/; revision=69146 --- clients/riscos/Manager.cpp | 42 ++++++++++++++++++++++++++++++++++++++ clients/riscos/Static.cpp | 1 - 2 files changed, 42 insertions(+), 1 deletion(-) diff --git a/clients/riscos/Manager.cpp b/clients/riscos/Manager.cpp index 5f1a9f1ca9..da164a7720 100644 --- a/clients/riscos/Manager.cpp +++ b/clients/riscos/Manager.cpp @@ -487,6 +487,48 @@ void Manager::animate(bool iconify, int style) } break; + case 2: + { + // KVirc style ? Maybe. For qwertz. + + if (!iconify) // No animation for restore. + return; + + // Go away quick. + hide(); + qApp->syncX(); + + int stepCount = 12; + + QRect r(geometry()); + + int dx = r.width() / (stepCount * 2); + int dy = r.height() / (stepCount * 2); + + QPainter p(workspace()->desktopWidget()); + p.setRasterOp(Qt::NotROP); + + for (int step = 0; step < stepCount; step++) { + + r.moveBy(dx, dy); + r.setWidth(r.width() - 2 * dx); + r.setHeight(r.height() - 2 * dy); + + XGrabServer(qt_xdisplay()); + + p.drawRect(r); + p.flush(); + usleep(200); + p.drawRect(r); + + XUngrabServer(qt_xdisplay()); + + kapp->processEvents(); + } + } + break; + + default: { NETRect r = netWinInfo()->iconGeometry(); diff --git a/clients/riscos/Static.cpp b/clients/riscos/Static.cpp index cd0298fa7f..ad1ac20c2f 100644 --- a/clients/riscos/Static.cpp +++ b/clients/riscos/Static.cpp @@ -439,7 +439,6 @@ Static::update() // ------------------------------------------------------------------------- // Button backgrounds // ------------------------------------------------------------------------- - qDebug("buttonSize == %d", buttonSize); buttonSize -=2;