Hello community,
here is the log from the commit of package kdelibs3
checked in at Tue Nov 7 01:00:42 CET 2006.
--------
--- KDE/kdelibs3/kdelibs3.changes 2006-11-05 01:22:21.000000000 +0100
+++ /mounts/work_src_done/STABLE/kdelibs3/kdelibs3.changes 2006-11-06 20:53:55.000000000 +0100
@@ -1,0 +2,5 @@
+Mon Nov 6 20:53:48 CET 2006 - dmueller@suse.de
+
+- add patch for drop shadows in kickoff
+
+-------------------------------------------------------------------
New:
----
kickoff-drop-shadow.diff
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ kdelibs3-devel-doc.spec ++++++
--- /var/tmp/diff_new_pack.suwkZd/_old 2006-11-07 01:00:10.000000000 +0100
+++ /var/tmp/diff_new_pack.suwkZd/_new 2006-11-07 01:00:10.000000000 +0100
@@ -18,7 +18,7 @@
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Summary: Additional Package Documentation
Version: 3.5.5
-Release: 26
+Release: 28
%define kdelibs_patch_level b
BuildArch: noarch
Requires: kdelibs3 qt3-devel-doc
++++++ kdelibs3.spec ++++++
--- /var/tmp/diff_new_pack.suwkZd/_old 2006-11-07 01:00:10.000000000 +0100
+++ /var/tmp/diff_new_pack.suwkZd/_new 2006-11-07 01:00:10.000000000 +0100
@@ -21,7 +21,7 @@
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Summary: KDE Base Libraries
Version: 3.5.5
-Release: 26
+Release: 29
Obsoletes: kde3-i18n kups keramik kdelibs3-cups kdelibs3-33addons
Provides: kups keramik kdelibs3-cups kdelibs3-33addons
Provides: kdelibs3_base = 3.3
@@ -104,6 +104,7 @@
Patch114: no-progress-for-beagle-status-query.diff
Patch115: xdgdata-pixmap.diff
Patch116: dnd-utf8-fix.diff
+Patch117: kickoff-drop-shadow.diff
%description
This package contains kdelibs, one of the basic packages of the K
@@ -275,6 +276,7 @@
%patch114
%patch115
%patch116
+%patch117
tar xfvj %SOURCE12
#
# define KDE version exactly
@@ -746,6 +748,8 @@
/opt/kde3/%_lib/libkwalletclient.so
%changelog -n kdelibs3
+* Mon Nov 06 2006 - dmueller@suse.de
+- add patch for drop shadows in kickoff
* Sun Nov 05 2006 - stbinner@suse.de
- fix dnd-utf8-fix.diff
* Sat Nov 04 2006 - stbinner@suse.de
++++++ testkhtml.spec ++++++
--- /var/tmp/diff_new_pack.suwkZd/_old 2006-11-07 01:00:10.000000000 +0100
+++ /var/tmp/diff_new_pack.suwkZd/_new 2006-11-07 01:00:10.000000000 +0100
@@ -16,7 +16,7 @@
License: BSD License and BSD-like, Other License(s), see package
Group: System/GUI/KDE
Version: 3.5.5
-Release: 28
+Release: 30
Summary: Internal: regression testing for konqueror renderer
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Source0: kdelibs-%{version}.tar.bz2
++++++ kickoff-drop-shadow.diff ++++++
--- kdefx/kstyle.cpp
+++ kdefx/kstyle.cpp
@@ -31,6 +31,7 @@
#include
#include
+#include
#include
#include
#include
@@ -79,7 +80,7 @@
QWidget* w1;
QWidget* w2;
};
- typedef QMap ShadowMap;
+ typedef QMap ShadowMap;
static ShadowMap *_shadowMap = 0;
QSingleCleanupHandler<ShadowMap> cleanupShadowMap;
ShadowMap &shadowMap() {
@@ -113,8 +114,13 @@
const double shadow_strip[4] =
{ 0.565, 0.675, 0.835, 0.945 };
-}
+ static bool useDropShadow(QWidget* w)
+ {
+ return w && w->metaObject() &&
+ w->metaObject()->findProperty("KStyleMenuDropShadow") != -1;
+ }
+}
namespace
{
@@ -128,12 +134,12 @@
protected:
void blendToColor(const QColor &col);
- void blendToPixmap(const QColorGroup &cg, const QPopupMenu* p);
+ void blendToPixmap(const QColorGroup &cg, const QWidget* p);
#ifdef HAVE_XRENDER
- void XRenderBlendToPixmap(const QPopupMenu* p);
+ void XRenderBlendToPixmap(const QWidget* p);
#endif
- void createShadowWindows(const QPopupMenu* p);
- void removeShadowWindows(const QPopupMenu* p);
+ void createShadowWindows(const QWidget* p);
+ void removeShadowWindows(const QWidget* p);
void rightShadow(QImage& dst);
void bottomShadow(QImage& dst);
private:
@@ -254,8 +260,16 @@
widget->installEventFilter(this);
}
}
-}
+ if (widget->isTopLevel())
+ {
+ if (!d->menuHandler && useDropShadow(widget))
+ d->menuHandler = new TransparencyHandler(this, Disabled, 1.0, true);
+ if (d->menuHandler && useDropShadow(widget))
+ widget->installEventFilter(d->menuHandler);
+ }
+}
+
void KStyle::unPolish( QWidget* widget )
{
@@ -265,8 +279,10 @@
QFrame::Shape shape = frame->frameShape();
if (shape == QFrame::ToolBarPanel || shape == QFrame::MenuBarPanel)
widget->removeEventFilter(this);
- }
+ }
}
+ if (widget->isTopLevel() && d->menuHandler && useDropShadow(widget))
+ widget->removeEventFilter(d->menuHandler);
}
@@ -1933,7 +1949,7 @@
}
// Create a shadow of thickness 4.
-void TransparencyHandler::createShadowWindows(const QPopupMenu* p)
+void TransparencyHandler::createShadowWindows(const QWidget* p)
{
#ifdef Q_WS_X11
int x2 = p->x()+p->width();
@@ -1980,7 +1996,7 @@
#endif
}
-void TransparencyHandler::removeShadowWindows(const QPopupMenu* p)
+void TransparencyHandler::removeShadowWindows(const QWidget* p)
{
#ifdef Q_WS_X11
ShadowMap::iterator it = shadowMap().find(p);
@@ -2006,7 +2022,7 @@
// Copyright (C) 2000 Daniel M. Duley
// Added 'fake' menu shadows <04-Jul-2002> -- Karol
- QPopupMenu* p = (QPopupMenu*)object;
+ QWidget* p = (QWidget*)object;
QEvent::Type et = event->type();
if (et == QEvent::Show)
@@ -2045,13 +2061,23 @@
// * shadows after duplicate show events.
// * TODO : determine real cause for duplicate events
// * till 20021005
- if (dropShadow && p->width() > 16 && p->height() > 16 && !shadowMap().contains( p ))
+ if ((dropShadow || useDropShadow(p))
+ && p->width() > 16 && p->height() > 16 && !shadowMap().contains( p ))
createShadowWindows(p);
}
+ else if (et == QEvent::Resize && p->isShown() && p->isTopLevel())
+ {
+ // Handle drop shadow
+ if (dropShadow || useDropShadow(p))
+ {
+ removeShadowWindows(p);
+ createShadowWindows(p);
+ }
+ }
else if (et == QEvent::Hide)
{
// Handle drop shadow
- if (dropShadow)
+ if (dropShadow || useDropShadow(p))
removeShadowWindows(p);
// Handle translucency
@@ -2076,7 +2102,7 @@
}
-void TransparencyHandler::blendToPixmap(const QColorGroup &cg, const QPopupMenu* p)
+void TransparencyHandler::blendToPixmap(const QColorGroup &cg, const QWidget* p)
{
if (opacity < 0.0 || opacity > 1.0)
return;
@@ -2089,7 +2115,10 @@
return;
// Allow styles to define the blend pixmap - allows for some interesting effects.
- kstyle->renderMenuBlendPixmap( blendPix, cg, p );
+ if (::qt_cast(p))
+ kstyle->renderMenuBlendPixmap( blendPix, cg, ::qt_cast(p) );
+ else
+ blendPix.fill(cg.button()); // Just tint as the default behavior
QImage blendImg = blendPix.convertToImage();
QImage backImg = pix.convertToImage();
@@ -2102,13 +2131,17 @@
// Here we go, use XRender in all its glory.
// NOTE: This is actually a bit slower than the above routines
// on non-accelerated displays. -- Karol.
-void TransparencyHandler::XRenderBlendToPixmap(const QPopupMenu* p)
+void TransparencyHandler::XRenderBlendToPixmap(const QWidget* p)
{
KPixmap renderPix;
renderPix.resize( pix.width(), pix.height() );
// Allow styles to define the blend pixmap - allows for some interesting effects.
- kstyle->renderMenuBlendPixmap( renderPix, p->colorGroup(), p );
+ if (::qt_cast(p))
+ kstyle->renderMenuBlendPixmap( renderPix, p->colorGroup(),
+ ::qt_cast(p) );
+ else
+ renderPix.fill(p->colorGroup().button()); // Just tint as the default behavior
Display* dpy = qt_xdisplay();
Pixmap alphaPixmap;
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org