From kde-devel Tue Apr 26 15:09:57 2005 From: Stefan Nikolaus Date: Tue, 26 Apr 2005 15:09:57 +0000 To: kde-devel Subject: Re: Kicker/Taskbar: Mouseover effect w/ thumbnails Message-Id: <200504261710.00848.stefan.nikolaus () kdemail ! net> X-MARC-Message: https://marc.info/?l=kde-devel&m=111452823505328 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--===============1166885828==" --===============1166885828== Content-Type: multipart/signed; boundary="nextPart3317777.PSu2zUlU00"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit --nextPart3317777.PSu2zUlU00 Content-Type: multipart/mixed; boundary="Boundary-01=_FnlbCltL1BbmWJ9" Content-Transfer-Encoding: 7bit Content-Disposition: inline --Boundary-01=_FnlbCltL1BbmWJ9 Content-Type: text/plain; charset="iso-8859-15" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Okay, here's what I got so far... [1] The attached patch uses the XComposite, XRender and XFixes extensions to=20 generate thumbnails. The latter is needed for shaped windows, e.g. xeyes. Windows, that are minimized or reside on a different virtual desktop on=20 startup, will have no thumnails until they are restored or the desktop is=20 switched, respectively. I've put two options in taskbar.kcfg. One to enable the thumbnails, as=20 proposed by Aaron, and one to set the thumnails' maximum dimension in pixel= s.=20 I prefer this to a percentage size. As is, the scaling of the thumbnails is done by QImage::smoothScale(). You = can=20 switch to XRender scaling by #if 0-ing the QImage::smoothScale() code part. The pros for the QImage::smoothScale() method are the better look and the=20 proper handling of shaped windows. Using XRender, shaped windows are drawn = on=20 an opaque (black) background. If you don't scale it, it's shown with=20 transparent bg, but who wants "100% thumbnails". The advantage of XRender i= s=20 its speed. At least on my machine the QImage::smoothScale() method sucks in= =20 this way. I think, the two QPixmap/QImage conversions slow things down. Opinions and ideas how to improve one of the methods are welcome. Not having looked much into it, I see following approaches: QImage::smoothScale(): =2D do the smooth scaling on a QPixmap basis (saves the two QPixmap/QImage= =20 conversions) =2D write the window pixmap directly into a Qimage (saves one conversion) XRender: =2D create a mask for the shape windows, scale and apply it on the thumbnail =2D find another filter for the XRender scaling Bye, Stefan [1] due to the excellent Composite HOWTO of Fredrik H=F6glund and some insi= ghts=20 taken from Hans Oischinger's Kompose --Boundary-01=_FnlbCltL1BbmWJ9 Content-Type: text/x-diff; charset="iso-8859-15"; name="kdebase-check-xextensions.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="kdebase-check-xextensions.patch" Index: configure.in.in =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/kde/kdebase/configure.in.in,v retrieving revision 1.66 diff -u -p -r1.66 configure.in.in =2D-- configure.in.in 7 Feb 2005 12:27:53 -0000 1.66 +++ configure.in.in 26 Apr 2005 13:17:30 -0000 @@ -209,6 +209,30 @@ else fi AC_SUBST(LIB_XRENDER) =20 +dnl XComposite check +AC_CHECK_HEADER(X11/extensions/Xcomposite.h, [xcomposite_h=3Dyes], [xcompo= site_h=3Dno], [#include ]) +if test "$xcomposite_h" =3D yes; then + KDE_CHECK_LIB(Xcomposite, XCompositeQueryExtension, [ + LIB_XCOMPOSITE=3D-lXcomposite + AC_DEFINE_UNQUOTED(HAVE_XCOMPOSITE, 1, [Define if you have the XCompos= ite extension]) + ], [], -lXext -X11 $X_EXTRA_LIBS) +else + LIB_XCOMPOSITE=3D +fi +AC_SUBST(LIB_XCOMPOSITE) + +dnl XFixes check +AC_CHECK_HEADER(X11/extensions/Xfixes.h, [xfixes_h=3Dyes], [xfixes_h=3Dno]= , [#include ]) +if test "$xfixes_h" =3D yes; then + KDE_CHECK_LIB(Xfixes, XFixesQueryExtension, [ + LIB_XFIXES=3D-lXfixes + AC_DEFINE_UNQUOTED(HAVE_XFIXES, 1, [Define if you have the XFixes exte= nsion]) + ], [], -lXext -X11 $X_EXTRA_LIBS) +else + LIB_XFIXES=3D +fi +AC_SUBST(LIB_XFIXES) + LDFLAGS=3D"$ac_save_ldflags" dnl ----- end of X11 extension checks ----- =20 --Boundary-01=_FnlbCltL1BbmWJ9 Content-Type: text/x-diff; charset="iso-8859-15"; name="taskbar-windowgrab-2.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="taskbar-windowgrab-2.patch" ? Doxyfile ? api ? taskmanager/taskmanagerIface.h ? taskmanager/taskmanagerIface_skel.cpp Index: share/kickertip.cpp =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/kde/kdebase/kicker/share/kickertip.cpp,v retrieving revision 1.17 diff -u -p -r1.17 kickertip.cpp =2D-- share/kickertip.cpp 24 Apr 2005 19:14:56 -0000 1.17 +++ share/kickertip.cpp 26 Apr 2005 15:00:06 -0000 @@ -247,7 +247,7 @@ void KickerTip::displayInternal() textRect.moveBy(-textRect.left(), -textRect.top()); textRect.addCoords(0, 0, 2, 2); =20 =2D int margin =3D QMAX(m_icon.height() / 4, marginHint); + int margin =3D QMAX(QMAX(m_icon.width(), m_icon.height()) / 4, marginH= int); int height =3D QMAX(m_icon.height(), textRect.height()) + 2 * margin; int textX =3D m_icon.isNull() ? margin : 2 + m_icon.width() + 2 * marg= in; int width =3D textX + textRect.width() + margin; Index: taskbar/taskbar.kcfg =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/kde/kdebase/kicker/taskbar/taskbar.kcfg,v retrieving revision 1.8 diff -u -p -r1.8 taskbar.kcfg =2D-- taskbar/taskbar.kcfg 20 Apr 2005 21:14:26 -0000 1.8 +++ taskbar/taskbar.kcfg 26 Apr 2005 15:00:07 -0000 @@ -126,5 +126,13 @@ true + + true + + + + 100 + + Index: taskbar/taskcontainer.cpp =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/kde/kdebase/kicker/taskbar/taskcontainer.cpp,v retrieving revision 1.136 diff -u -p -r1.136 taskcontainer.cpp =2D-- taskbar/taskcontainer.cpp 25 Apr 2005 00:41:45 -0000 1.136 +++ taskbar/taskcontainer.cpp 26 Apr 2005 15:00:07 -0000 @@ -1469,21 +1469,15 @@ void TaskContainer::updateKickerTip(Kick } =20 QPixmap pixmap; =2D#if 0 =2D if (TaskbarSettings::showThumbnails() && + if (TaskBarSettings::showThumbnails() && m_filteredTasks.count() =3D=3D 1) { Task::Ptr t =3D m_filteredTasks.first(); =2D t->updateThumbnail(); =20 =2D if (t->hasThumbnail()) =2D { =2D pixmap.convertFromImage(t->thumbnail().convertToImage().smoo= thScale(64, 64)); =2D } + pixmap =3D t->thumbnail(TaskBarSettings::thumbnailMaxDimension()); } =20 if (pixmap.isNull()) =2D#endif { // try to load icon via net_wm pixmap =3D KWin::icon(tasks.first()->window(), Index: taskmanager/Makefile.am =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/kde/kdebase/kicker/taskmanager/Makefile.am,v retrieving revision 1.7 diff -u -p -r1.7 Makefile.am =2D-- taskmanager/Makefile.am 19 Apr 2005 20:06:42 -0000 1.7 +++ taskmanager/Makefile.am 26 Apr 2005 15:00:07 -0000 @@ -5,7 +5,7 @@ libtaskmanager_la_SOURCES =3D tasklmbmenu. libtaskmanager_la_METASOURCES =3D AUTO =20 libtaskmanager_la_LDFLAGS =3D $(all_libraries) -version-info 1:0:0 -no-und= efined =2Dlibtaskmanager_la_LIBADD =3D $(LIB_KDECORE) ../share/libkickermain.la +libtaskmanager_la_LIBADD =3D $(LIB_KDECORE) $(LIB_XFIXES) $(LIB_XRENDER) $= (LIB_XCOMPOSITE) ../share/libkickermain.la =20 messages: $(XGETTEXT) *.cpp *.h -o $(podir)/libtaskmanager.pot Index: taskmanager/taskmanager.cpp =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/kde/kdebase/kicker/taskmanager/taskmanager.cpp,v retrieving revision 1.104 diff -u -p -r1.104 taskmanager.cpp =2D-- taskmanager/taskmanager.cpp 25 Apr 2005 09:10:55 -0000 1.104 +++ taskmanager/taskmanager.cpp 26 Apr 2005 15:00:07 -0000 @@ -40,6 +40,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE=20 =20 TaskManager* TaskManager::m_self =3D 0; static KStaticDeleter staticTaskManagerDeleter; +bool TaskManager::m_usableXComposite =3D false; =20 TaskManager* TaskManager::the() { @@ -64,6 +65,10 @@ TaskManager::TaskManager() connect(m_winModule, SIGNAL(currentDesktopChanged(int)), SLOT(currentD= esktopChanged(int))); connect(m_winModule, SIGNAL(windowChanged(WId,unsigned int)), SLOT(win= dowChanged(WId,unsigned int))); =20 +#ifdef THUMBNAILING_POSSIBLE + initComposite(); +#endif // THUMBNAILING_POSSIBLE + // register existing windows const QValueList windows =3D m_winModule->windows(); QValueList::ConstIterator end(windows.end()); @@ -103,9 +108,87 @@ void TaskManager::configure_startup() _startup_info->setTimeout( c.readUnsignedNumEntry( "Timeout", 30 )); } =20 +void TaskManager::initComposite() +{ +#ifdef THUMBNAILING_POSSIBLE + Display *dpy =3D QPaintDevice::x11AppDisplay(); + + // XComposite extension check + int event_base, error_base; + if (XCompositeQueryExtension(dpy, &event_base, &error_base)) + { + int major =3D 0, minor =3D 99; // The highest version we support + + // Version check is needed. Otherwise, the server will return + // BadRequest for any operations other than QueryVersion. + XCompositeQueryVersion(dpy, &major, &minor); + kdDebug() << QString("XComposite %1.%2").arg(major).arg(minor) << = endl; + + // We use XCompositeNameWindowPixmap(), i.e. we need at least + // version 0.2. + if (major =3D=3D 0 && minor < 2) + { + return; + } + } + else + { + return; + } + + // XRender extension check + if (XRenderQueryExtension(dpy, &event_base, &error_base)) + { + int major =3D 0, minor =3D 99; // The highest version we support + + XRenderQueryVersion(dpy, &major, &minor); + kdDebug() << QString("XRender %1.%2").arg(major).arg(minor) << end= l; + + // We use SetPictureTransform() and SetPictureFilter(), i.e. we + // need at least version 0.6. + if (major =3D=3D 0 && minor < 6) + { + return; + } + } + else + { + return; + } + + // XFixes extension check + if (XFixesQueryExtension(dpy, &event_base, &error_base)) + { + int major =3D 3, minor =3D 99; // The highest version we support + + XFixesQueryVersion(dpy, &major, &minor); + kdDebug() << QString("XFixes %1.%2").arg(major).arg(minor) << endl; + + // We use Region objects, i.e. we need at least version 2.0. + if (major < 2) + { + return; + } + } + else + { + return; + } + + // if we get here, we've got usable extensions + m_usableXComposite =3D true; + + // redirecting windows to backing pixmaps + for (int i =3D 0; i < ScreenCount(dpy); i++) + { + XCompositeRedirectSubwindows(dpy, RootWindow(dpy, i), CompositeRed= irectAutomatic); + } +#endif // THUMBNAILING_POSSIBLE +} + Task::Ptr TaskManager::findTask(WId w) { =2D QMap::iterator it =3D m_tasksByWId.find(w); + Task::Dict::iterator it =3D m_tasksByWId.find(w); =20 if (it =3D=3D m_tasksByWId.end()) { @@ -302,10 +385,31 @@ void TaskManager::windowChanged(WId w, u { // moved to different desktop or is on all or change in iconificat= ion/withdrawnnes emit windowChanged(t); + + if (dirty & NET::WMState && m_usableXComposite && !t->isMinimized(= )) + { + // update on restoring a minimized window + updateWindowPixmap(w); + } } else if (dirty & NET::WMGeometry) { emit windowChangedGeometry(t); + + if (m_usableXComposite) + { + // update on size changes + updateWindowPixmap(w); + } + } +} + +void TaskManager::updateWindowPixmap(WId w) +{ + Task::Ptr task =3D findTask(w); + if (task) + { + task->updateWindowPixmap(); } } =20 @@ -456,6 +560,7 @@ Task::Task(WId win, QObject *parent, con : QObject(parent, name), _active(false), _win(win), + m_frameId(win), _info(KWin::windowInfo(_win, 0, NET::WM2AllowedActions)), _lastWidth(0), _lastHeight(0), @@ -463,7 +568,8 @@ Task::Task(WId win, QObject *parent, con _lastIcon(), _thumbSize(0.2), _thumb(), =2D _grab() + _grab(), + m_windowPixmap(0) { // try to load icon via net_wm _pixmap =3D KWin::icon(_win, 16, 16, true); @@ -480,11 +586,68 @@ Task::Task(WId win, QObject *parent, con =20 // load xapp icon if (_pixmap.isNull()) =2D _pixmap =3D SmallIcon("kcmx"); + { + _pixmap =3D SmallIcon("kcmx"); + } + +#ifdef THUMBNAILING_POSSIBLE + if (TaskManager::useXComposite()) + { + findWindowFrameId(); + if (!isMinimized() && isOnCurrentDesktop()) + { + updateWindowPixmap(); + } + } +#endif // THUMBNAILING_POSSIBLE } =20 Task::~Task() { +#ifdef THUMBNAILING_POSSIBLE + if (m_windowPixmap) + { + XFreePixmap(QPaintDevice::x11AppDisplay(), m_windowPixmap); + } +#endif // THUMBNAILING_POSSIBLE +} + +// Task::findWindowFrameId() +// Code was copied from Kompose. +// Copyright (C) 2004 Hans Oischinger +void Task::findWindowFrameId() +{ +#ifdef THUMBNAILING_POSSIBLE + Window target_win, parent, root; + Window *children; + uint nchildren; + + target_win =3D _win; + for (;;) + { + if (!XQueryTree(QPaintDevice::x11AppDisplay(), target_win, &root, + &parent, &children, &nchildren)) + { + break; + } + + if (children) + { + XFree(children); // it's a list, that's deallocated! + } + + if (!parent || parent =3D=3D root) + { + break; + } + else + { + target_win =3D parent; + } + } + + m_frameId =3D target_win; +#endif // THUMBNAILING_POSSIBLE } =20 void Task::refreshIcon() @@ -1104,6 +1267,117 @@ void Task::generateThumbnail() emit thumbnailChanged(); } =20 +QPixmap Task::thumbnail(int maxDimension) +{ + if (!TaskManager::useXComposite() || !m_windowPixmap) + { + return QPixmap(); + } + +#ifdef THUMBNAILING_POSSIBLE + Display *dpy =3D QPaintDevice::x11AppDisplay(); + + // We need to find out some things about the window, such as it's size, + // it's position on the screen, and the format of the pixel data + XWindowAttributes attr; + XGetWindowAttributes(dpy, m_frameId, &attr); + + XRenderPictFormat *format =3D XRenderFindVisualFormat(dpy, attr.visual= ); + bool hasAlpha =3D (format->type =3D=3D PictTypeDirect && + format->direct.alphaMask); + int x =3D attr.x; + int y =3D attr.y; + int width =3D attr.width; + int height =3D attr.height; + + // Create a Render picture so we can reference the window contents. + // We need to set the subwindow mode to IncludeInferiors, otherwise ch= ild + // widgets in the window won't be included when we draw it, which is n= ot + // what we want. + XRenderPictureAttributes pa; + pa.subwindow_mode =3D IncludeInferiors; // Don't clip child widgets + + Picture picture =3D XRenderCreatePicture(dpy, m_windowPixmap, format, = CPSubwindowMode, &pa); + + // Create a copy of the bounding region for the window + XserverRegion region =3D XFixesCreateRegionFromWindow(dpy, m_frameId, = WindowRegionBounding); + + XFixesSetPictureClipRegion(dpy, picture, 0, 0, region); + XFixesDestroyRegion(dpy, region); + + double factor; + if (width > height) + { + factor =3D (double)maxDimension / (double)width; + } + else + { + factor =3D (double)maxDimension / (double)height; + } + int thumbnailWidth =3D width * factor; + int thumbnailHeight =3D height * factor; + + QPixmap thumbnail(thumbnailWidth, thumbnailHeight); + thumbnail.fill(QApplication::palette().active().background()); +#if 1 + QPixmap full(width, height); + full.fill(QApplication::palette().active().background()); + + XRenderComposite(dpy, + hasAlpha ? PictOpOver : PictOpSrc, + picture, // src + None, // mask + full.x11RenderHandle(), // dst + 0, 0, // src offset + 0, 0, // mask offset + 0, 0, // dst offset + width, height); + + thumbnail.convertFromImage(full.convertToImage().smoothScale(thumbnail= Width, + thumbnailHeight)); +#else + // XRENDER scaling + XRenderSetPictureFilter( dpy, picture, FilterBilinear, 0, 0 ); + // Scaling matrix + XTransform xform =3D {{ + { XDoubleToFixed( 1 ), XDoubleToFixed( 0 ), XDoubleToFixed( 0= ) }, + { XDoubleToFixed( 0 ), XDoubleToFixed( 1 ), XDoubleToFixed( 0= ) }, + { XDoubleToFixed( 0 ), XDoubleToFixed( 0 ), XDoubleToFixed( factor= ) } + }}; + + XRenderSetPictureTransform(dpy, picture, &xform); + + XRenderComposite(QPaintDevice::x11AppDisplay(), + hasAlpha ? PictOpOver : PictOpSrc, + picture, // src + None, // mask + thumbnail.x11RenderHandle(), // dst + 0, 0, // src offset + 0, 0, // mask offset + 0, 0, // dst offset + thumbnailWidth, thumbnailHeight); +#endif + XRenderFreePicture(dpy, picture); + + return thumbnail; + +#endif // THUMBNAILING_POSSIBLE +} + +void Task::updateWindowPixmap() +{ +#ifdef THUMBNAILING_POSSIBLE + Display *dpy =3D QPaintDevice::x11AppDisplay(); + + if (m_windowPixmap) + { + XFreePixmap(dpy, m_windowPixmap); + } + + m_windowPixmap =3D XCompositeNameWindowPixmap(dpy, m_frameId); +#endif // THUMBNAILING_POSSIBLE +} + Startup::Startup(const KStartupInfoId& id, const KStartupInfoData& data, QObject * parent, const char *name) : QObject(parent, name), _id(id), _data(data) Index: taskmanager/taskmanager.h =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/kde/kdebase/kicker/taskmanager/taskmanager.h,v retrieving revision 1.69 diff -u -p -r1.69 taskmanager.h =2D-- taskmanager/taskmanager.h 24 Apr 2005 19:10:50 -0000 1.69 +++ taskmanager/taskmanager.h 26 Apr 2005 15:00:07 -0000 @@ -36,11 +36,24 @@ CONNECTION WITH THE SOFTWARE OR THE USE=20 #include #include =20 =2D#include #include #include #include =20 +#ifdef HAVE_CONFIG_H +#include +#endif + +#if defined(HAVE_XCOMPOSITE) && defined(HAVE_XRENDER) && defined(HAVE_XFIX= ES) +#include +#include +#include +#include +#if XCOMPOSITE_VERSION >=3D 00200 && (RENDER_MAJOR > 0 || RENDER_MINOR >= =3D 6) && XFIXES_VERSION >=3D 20000 +#define THUMBNAILING_POSSIBLE +#endif +#endif + class KWinModule; class TaskManager; =20 @@ -291,6 +304,10 @@ public: */ const QPixmap &thumbnail() const { return _thumb; } =20 + QPixmap thumbnail(int maxDimension); + + void updateWindowPixmap(); + public slots: // actions =20 @@ -426,9 +443,13 @@ protected slots: //* @internal void generateThumbnail(); =20 +protected: + void findWindowFrameId(); + private: bool _active; WId _win; + WId m_frameId; QPixmap _pixmap; KWin::WindowInfo _info; QValueList _transients; @@ -442,8 +463,7 @@ private: double _thumbSize; QPixmap _thumb; QPixmap _grab; =2D =2D class TaskPrivate *d; + Pixmap m_windowPixmap; }; =20 =20 @@ -596,6 +616,8 @@ public: =20 KWinModule* winModule() const { return m_winModule; } =20 + static bool useXComposite() { return m_usableXComposite; } + signals: /** * Emitted when a new task has started. @@ -653,8 +675,9 @@ protected slots: void gotStartupChange( const KStartupInfoId&, const KStartupInfoData& = ); =20 protected: =2D void configure_startup(); + void initComposite(); + void updateWindowPixmap(WId); =20 private: TaskManager(); @@ -668,6 +691,7 @@ private: bool m_trackGeometry; =20 static TaskManager* m_self; + static bool m_usableXComposite; =20 class TaskManagerPrivate *d; }; Index: taskmanager/taskrmbmenu.cpp =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/kde/kdebase/kicker/taskmanager/taskrmbmenu.cpp,v retrieving revision 1.20 diff -u -p -r1.20 taskrmbmenu.cpp =2D-- taskmanager/taskrmbmenu.cpp 24 Apr 2005 19:10:50 -0000 1.20 +++ taskmanager/taskrmbmenu.cpp 26 Apr 2005 15:00:07 -0000 @@ -29,6 +29,10 @@ CONNECTION WITH THE SOFTWARE OR THE USE=20 =20 #include "taskmanager.h" =20 +#ifdef THUMBNAILING_POSSIBLE +#include +#endif + #include "taskrmbmenu.h" #include "taskrmbmenu.moc" =20 --Boundary-01=_FnlbCltL1BbmWJ9-- --nextPart3317777.PSu2zUlU00 Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.5 (GNU/Linux) iD8DBQBCblnIpfDn2DABIpcRAgo1AJ9q4rCSkjl2CdegKAe7ICnM4pF6BgCcC3kQ N11nKQMvzvnqWuDYz/iv+R8= =f3mY -----END PGP SIGNATURE----- --nextPart3317777.PSu2zUlU00-- --===============1166885828== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline >> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe << --===============1166885828==--