summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoralbator <albator@arcadia.vtf>2011-11-19 23:17:31 +0100
committeralbator <albator@arcadia.vtf>2011-11-19 23:17:31 +0100
commit5a1d80efdaa4c2a716f7c8a6984dea6f2252a987 (patch)
treecf462d35c35cd390497398e5e8aae25cfc3cd950
parentb2e59abbbae6cb8854c3d3bb8a95432d319b7ba4 (diff)
downloadtde-packaging-5a1d80efdaa4c2a716f7c8a6984dea6f2252a987.tar.gz
tde-packaging-5a1d80efdaa4c2a716f7c8a6984dea6f2252a987.zip
RHEL/Fedora: fix kickoff menu in kdebase
-rw-r--r--redhat/kdebase/kdebase-3.5.12-kickoff_unstable.patch448
-rw-r--r--redhat/kdebase/trinity-kdebase-3.5.13.spec28
2 files changed, 460 insertions, 16 deletions
diff --git a/redhat/kdebase/kdebase-3.5.12-kickoff_unstable.patch b/redhat/kdebase/kdebase-3.5.12-kickoff_unstable.patch
index 2a58f0020..7b8b649e1 100644
--- a/redhat/kdebase/kdebase-3.5.12-kickoff_unstable.patch
+++ b/redhat/kdebase/kdebase-3.5.12-kickoff_unstable.patch
@@ -1,13 +1,443 @@
-Index: ui/k_new_mnu.cpp
-===================================================================
---- ui/k_new_mnu.cpp (revision 1259264)
-+++ ui/k_new_mnu.cpp (working copy)
-@@ -3502,6 +3502,8 @@
- descr, "system:/media/" + name, nId++, -1 );
+Binary files kdebase/kicker/data/kickoff/resize_handle.png and kdebase1/kicker/data/kickoff/resize_handle.png differ
+diff -ur kdebase/kicker/kicker/buttons/knewbutton.cpp kdebase1/kicker/kicker/buttons/knewbutton.cpp
+--- kdebase/kicker/kicker/buttons/knewbutton.cpp 2011-08-11 01:25:50.000000000 -0400
++++ kdebase1/kicker/kicker/buttons/knewbutton.cpp 2011-11-18 12:54:22.380404540 -0500
+@@ -55,26 +55,28 @@
+ : KButton( parent ),
+ m_oldPos(0,0)
+ {
++
++ setTitle(i18n("K Menu"));
+ Q_ASSERT( !m_self );
+ m_self = this;
+- m_hoverTimer = -1;
+ m_openTimer = -1;
+- m_active = false;
++ m_hoverTimer = -1;
+ m_mouseInside = false;
+ m_drag = false;
+-
+- setIconAlignment((TQ_Alignment)(AlignTop|AlignRight));
+- setAcceptDrops(true);
+- setIcon("kmenu-suse");
+- setDrawArrow(false);
+-
+- m_movie = new TQMovie(locate("data", "kicker/pics/kmenu_basic.mng"));
+- m_movie->connectUpdate(this, TQT_SLOT(updateMovie()));
+- m_movie->connectStatus(TQT_TQOBJECT(this), TQT_SLOT(slotStatus(int)));
+- m_movie->connectResize(this, TQT_SLOT(slotSetSize(const TQSize&)));
+-
++
++ setIcon("kmenu");
++ setIcon(KickerSettings::customKMenuIcon());
++
+ TQApplication::desktop()->screen()->installEventFilter(this);
+- setMouseTracking(true);
++
++ if (KickerSettings::showKMenuText())
++ {
++ setButtonText(KickerSettings::kMenuText());
++ setFont(KickerSettings::buttonFont());
++ setTextColor(KickerSettings::buttonTextColor());
++ }
++
++ tqrepaint();
+ }
- ++it; // skip separator
-+ ++it;
-+ ++it;
+ KNewButton::~KNewButton()
+@@ -82,28 +84,15 @@
+ if ( m_self == this )
+ m_self = 0;
+ setMouseTracking(false);
+- delete m_movie;
+ }
+
+-void KNewButton::slotStatus(int status)
+-{
+- if(status == TQMovie::EndOfLoop)
+- slotStopAnimation();
+-}
+
+-TQColor KNewButton::borderColor() const
++void KNewButton::drawButton(TQPainter *p)
+ {
+- TQImage img = m_active_pixmap.convertToImage();
+-
+- for (int i = 0; i < img.width(); ++i) {
+- QRgb rgb = img.pixel(orientation() == Qt::Horizontal ? img.width() - i - 1 :
+- i, 2);
+-
+- if (tqGreen(rgb) > 0x50)
+- return rgb;
+- }
+-
+- return img.pixel( orientation() == Qt::Horizontal ? img.width() - 2 : 2, 2);
++ if (KickerSettings::showDeepButtons())
++ PanelPopupButton::drawDeepButton(p);
++ else
++ PanelPopupButton::drawButton(p);
+ }
+
+ void KNewButton::show()
+@@ -111,103 +100,12 @@
+ KButton::show();
+
+ if (KickerSettings::firstRun()) {
+- TQTimer::singleShot(500,this,TQT_SLOT(slotExecMenu()));
++ TQTimer::singleShot(0,this,TQT_SLOT(slotExecMenu()));
+ KickerSettings::setFirstRun(false);
+ KickerSettings::writeConfig();
+ }
+ }
+
+-void KNewButton::updateMovie()
+-{
+- m_oldPos = TQPoint( -1, -1 );
+- drawEye();
+-
+- if (!m_active && m_movie->running())
+- m_movie->pause();
+-}
+-
+-void KNewButton::setPopupDirection(KPanelApplet::Direction d)
+-{
+- KButton::setPopupDirection(d);
+-
+- delete m_movie;
+-
+- switch (d) {
+- case KPanelApplet::Left:
+- setIconAlignment((TQ_Alignment)(AlignTop|AlignLeft));
+- m_movie = new TQMovie(locate("data", "kicker/pics/kmenu_vertical.mng"));
+- break;
+- case KPanelApplet::Right:
+- setIconAlignment((TQ_Alignment)(AlignTop|AlignRight));
+- m_movie = new TQMovie(locate("data", "kicker/pics/kmenu_vertical.mng"));
+- break;
+- case KPanelApplet::Up:
+- setIconAlignment((TQ_Alignment)(AlignTop|AlignHCenter));
+- m_movie = new TQMovie(locate("data", "kicker/pics/kmenu_basic.mng"));
+- break;
+- case KPanelApplet::Down:
+- setIconAlignment((TQ_Alignment)(AlignBottom|AlignHCenter));
+- m_movie = new TQMovie(locate("data", "kicker/pics/kmenu_flipped.mng"));
+- }
+-
+- m_movie->connectUpdate(this, TQT_SLOT(updateMovie()));
+- m_movie->connectStatus(TQT_TQOBJECT(this), TQT_SLOT(slotStatus(int)));
+- m_movie->connectResize(this, TQT_SLOT(slotSetSize(const TQSize&)));
+-}
+-
+-void KNewButton::slotSetSize(const TQSize& s)
+-{
+- m_iconSize = s;
+-}
+-
+-double KNewButton::buttonScaleFactor(const TQSize& s) const
+-{
+- double sf = 1.0;
+-
+- switch (popupDirection()) {
+- case KPanelApplet::Left:
+- case KPanelApplet::Right:
+-// sf = kMin(double(s.width()) / m_iconSize.height(), double(s.height()) / m_iconSize.width());
+-// break;
+- case KPanelApplet::Up:
+- case KPanelApplet::Down:
+- sf = kMin(double(s.width()) / m_iconSize.width(), double(s.height()) / m_iconSize.height());
+- break;
+- }
+-
+- if (sf > 0.8) sf = 1.0;
+- return sf;
+-}
+-
+-int KNewButton::widthForHeight(int height) const
+-{
+- int r = m_iconSize.width() * buttonScaleFactor(TQSize(m_iconSize.width(), height));
+-
+- if (!m_movie->running() && height != m_active_pixmap.height())
+- {
+- KNewButton* that = const_cast<KNewButton*>(this);
+- TQTimer::singleShot(0, that, TQT_SLOT(slotStopAnimation()));
+- }
+-
+- return r;
+-}
+-
+-int KNewButton::preferredDimension(int panelDim) const
+-{
+- return kMax(m_icon.width(), m_icon.height());
+-}
+-
+-int KNewButton::heightForWidth(int width) const
+-{
+- int r = m_iconSize.width() * buttonScaleFactor(TQSize(width, m_iconSize.height()));
+- if (!m_movie->running() && width != m_active_pixmap.width())
+- {
+- KNewButton* that = const_cast<KNewButton*>(this);
+- TQTimer::singleShot(0, that, TQT_SLOT(slotStopAnimation()));
+- }
+- return r;
+-}
+-
+ bool KNewButton::eventFilter(TQObject *o, TQEvent *e)
+ {
+ if (e->type() == TQEvent::MouseButtonRelease ||
+@@ -223,75 +121,9 @@
+ }
+ }
+
+- if (KickerSettings::kickoffDrawGeekoEye() && e->type() == TQEvent::MouseMove)
+- {
+- TQMouseEvent *me = TQT_TQMOUSEEVENT(e);
+- if ((me->state() & Qt::MouseButtonMask) == Qt::NoButton)
+- drawEye();
+- }
+-
+ return KButton::eventFilter(o, e);
+ }
+
+-void KNewButton::drawEye()
+-{
+-#define eye_x 62
+-#define eye_y 13
+- TQPoint mouse = TQCursor::pos();
+- TQPoint me = mapToGlobal(TQPoint(eye_x, eye_y));
+- double a = atan2(mouse.y() - me.y(), mouse.x() - me.x());
+- int dx = int(2.1 * cos(a));
+- int dy = int(2.1 * sin(a));
+-
+- TQPoint newpos(eye_x+dx,eye_y+dy);
+- if (newpos!=m_oldPos) {
+- m_oldPos = newpos;
+- TQPixmap pixmap = m_active_pixmap;
+-
+- double sf = 1.0;
+-
+- if(!m_movie->framePixmap().isNull())
+- {
+- pixmap = m_movie->framePixmap();
+- pixmap.detach();
+- m_iconSize = pixmap.size();
+- sf = buttonScaleFactor(size());
+-
+- if (KickerSettings::kickoffDrawGeekoEye()) {
+- TQPainter p(&pixmap);
+- p.setPen(white);
+- p.setBrush(white);
+- // p.setPen(TQColor(110,185,55));
+- p.drawRect(eye_x+dx, eye_y+dy, 2, 2);
+- p. end();
+- }
+- }
+-
+- TQWMatrix matrix;
+- switch (popupDirection()) {
+- case KPanelApplet::Left:
+- matrix.scale(sf, -sf);
+- matrix.rotate(90);
+- break;
+- case KPanelApplet::Up:
+- matrix.scale(sf, sf);
+- break;
+- case KPanelApplet::Right:
+- matrix.scale(sf, -sf);
+- matrix.rotate(90);
+- break;
+- case KPanelApplet::Down:
+- matrix.scale(sf, sf);
+- break;
+- }
+- m_active_pixmap = pixmap.xForm(matrix);
+-
+- tqrepaint(false);
+- }
+-#undef eye_x
+-#undef eye_y
+-}
+-
+ void KNewButton::enterEvent(TQEvent* e)
+ {
+ KButton::enterEvent(e);
+@@ -315,15 +147,8 @@
+ }
+
+ m_active = true;
+- m_movie->unpause();
+- m_movie->restart();
+ }
+
+-void KNewButton::rewindMovie()
+-{
+- m_oldPos = TQPoint( -1, -1 );
+- m_movie->unpause();
+-}
+
+ void KNewButton::dragEnterEvent(TQDragEnterEvent* /*e*/)
+ {
+@@ -369,31 +194,12 @@
+ }
+ }
+
+-void KNewButton::slotStopAnimation()
+-{
+- m_active = false;
+- m_movie->pause();
+- m_movie->restart();
+- TQTimer::singleShot(200, this, TQT_SLOT(rewindMovie()));
+-}
+-
+-const TQPixmap& KNewButton::labelIcon() const
+-{
+- return m_active_pixmap;
+-}
+-
+ void KNewButton::slotExecMenu()
+ {
+- if (m_openTimer != -1)
+- killTimer(m_openTimer);
+-
+- m_openTimer = startTimer(TQApplication::doubleClickInterval() * 3);
+
+ if (m_active)
+ {
+ m_active = false;
+- m_movie->pause();
+- m_movie->restart();
}
+
+ KButton::slotExecMenu();
+@@ -401,40 +207,12 @@
+ assert(!KickerTip::tippingEnabled());
+ assert(dynamic_cast<KMenu*>(m_popup));
+
+- disconnect(dynamic_cast<KMenu*>(m_popup), TQT_SIGNAL(aboutToHide()), this,
+- TQT_SLOT(slotStopAnimation()));
+- connect(dynamic_cast<KMenu*>(m_popup), TQT_SIGNAL(aboutToHide()),
+- TQT_SLOT(slotStopAnimation()));
+-
+ m_popup->move(KickerLib::popupPosition(popupDirection(), m_popup, this));
+ // I wish KMenu would properly done itself when it closes. But it doesn't.
+
+- bool useEffect = true; // could be TQApplication::isEffectEnabled()
+- useEffect = false; // too many TQt bugs to be useful
+- if (m_drag)
+- useEffect = false;
+-
+ m_drag = false; // once is enough
+
+- if (useEffect)
+- {
+- switch (popupDirection()) {
+- case KPanelApplet::Left:
+- qScrollEffect(m_popup, TQEffects::LeftScroll);
+- break;
+- case KPanelApplet::Up:
+- qScrollEffect(m_popup, TQEffects::UpScroll);
+- break;
+- case KPanelApplet::Right:
+- qScrollEffect(m_popup, TQEffects::RightScroll);
+- break;
+- case KPanelApplet::Down:
+- qScrollEffect(m_popup, TQEffects::DownScroll);
+- break;
+- }
+- }
+- else
+- static_cast<KMenu*>(m_popup)->show();
++ static_cast<KMenu*>(m_popup)->show();
}
+ void KNewButton::timerEvent(TQTimerEvent* e)
+@@ -447,9 +225,4 @@
+ killTimer(m_hoverTimer);
+ m_hoverTimer = -1;
+ }
+- if (e->timerId() == m_openTimer)
+- {
+- killTimer(m_openTimer);
+- m_openTimer = -1;
+- }
+ }
+diff -ur kdebase/kicker/kicker/buttons/knewbutton.h kdebase1/kicker/kicker/buttons/knewbutton.h
+--- kdebase/kicker/kicker/buttons/knewbutton.h 2011-03-12 01:58:13.000000000 -0500
++++ kdebase1/kicker/kicker/buttons/knewbutton.h 2011-11-18 09:31:03.163665964 -0500
+@@ -28,7 +28,6 @@
+
+ #include "kbutton.h"
+
+-#include <tqmovie.h>
+ #include <tqpoint.h>
+
+ /**
+@@ -43,25 +42,10 @@
+ ~KNewButton();
+
+ static KNewButton *self() { return m_self; }
+-
+ void loadConfig( const KConfigGroup& config );
+-
+- virtual const TQPixmap& labelIcon() const;
+-
+- virtual int widthForHeight(int height) const;
+- virtual int preferredDimension(int panelDim) const;
+- virtual int heightForWidth(int width) const;
+-
+ TQColor borderColor() const;
++ //virtual void setPopupDirection(KPanelApplet::Direction d);
+
+- virtual void setPopupDirection(KPanelApplet::Direction d);
+-
+-private slots:
+- void slotStatus(int);
+- void slotSetSize(const TQSize&);
+- void slotStopAnimation();
+- void rewindMovie();
+- void updateMovie();
+
+ protected:
+ virtual void show();
+@@ -78,17 +62,15 @@
+ void timerEvent(TQTimerEvent*);
+
+ private:
+- void drawEye();
+- double buttonScaleFactor(const TQSize& s) const;
+
+- TQMovie* m_movie;
++ void drawButton(TQPainter *p);
+ TQPixmap m_active_pixmap;
+ TQPoint m_oldPos;
+ TQSize m_iconSize;
+ TQRect m_sloppyRegion;
+- int m_hoverTimer;
+ int m_openTimer;
+- bool m_active;
++ int m_hoverTimer;
++ bool m_active;
+ bool m_mouseInside;
+ bool m_drag;
+
+diff -ur kdebase/kicker/kicker/ui/k_new_mnu.cpp kdebase1/kicker/kicker/ui/k_new_mnu.cpp
+--- kdebase/kicker/kicker/ui/k_new_mnu.cpp 2011-08-11 01:25:49.000000000 -0400
++++ kdebase1/kicker/kicker/ui/k_new_mnu.cpp 2011-11-18 15:02:51.565689119 -0500
+@@ -1700,8 +1700,6 @@
+ TQPixmap pix( 64, footer->height() );
+ TQPainter p( &pix );
+ p.fillRect( 0, 0, 64, footer->height(), m_branding->tqcolorGroup().brush( TQColorGroup::Base ) );
+- p.fillRect( 0, m_orientation == BottomUp ? footer->height() - 2 : 0,
+- 64, 3, KNewButton::self()->borderColor() );
+ p.end();
+ footer->setPaletteBackgroundPixmap( pix );
+ }
+@@ -3500,7 +3498,8 @@
+ }
+ m_systemView->insertItem( iconName, userLabel.isEmpty() ? label : userLabel,
+ descr, "system:/media/" + name, nId++, -1 );
+-
++ ++it;
++ ++it;
+ ++it; // skip separator
+ }
+ }
diff --git a/redhat/kdebase/trinity-kdebase-3.5.13.spec b/redhat/kdebase/trinity-kdebase-3.5.13.spec
index faf8d13ad..84d3c4d8c 100644
--- a/redhat/kdebase/trinity-kdebase-3.5.13.spec
+++ b/redhat/kdebase/trinity-kdebase-3.5.13.spec
@@ -2,7 +2,7 @@
%if "%{?version}" == ""
%define version 3.5.13
%endif
-%define release 7
+%define release 8
# If TDE is built in a specific prefix (e.g. /opt/trinity), the release will be suffixed with ".opt".
%if "%{?_prefix}" != "/usr"
@@ -61,11 +61,14 @@ Patch7: kdebase-3.5.13-genkdmconf_Xsession_location.patch
Patch8: kdebase-3.5.13-startkde_ldpreload.patch
## [kdebase/kioslave/media/mediamanager] FTBFS missing dbus-tqt includes
Patch9: kdebase-3.5.13-mediamanager_ftbfs.patch
-## [kdebase/kicker/kicker/ui]
-Patch10: kdebase-3.5.12-kickoff_unstable.patch
## [kdebase/startkde] Sets default Start Icon in 'kickerrc'
Patch11: kdebase-3.5.13-startkde_icon.patch
+# TDE 3.5.13 patches
+## [kdebase/kicker/kicker/ui]
+Patch10: kdebase-3.5.12-kickoff_unstable.patch
+## [kdebase/kdm] adds gcrypt support
+Patch12: kdebase-3.5.13-kdm-crypt.patch
# Fedora 15 Theme: "Lovelock"
%if 0%{?fedora} == 15
@@ -217,10 +220,9 @@ Protocol handlers (KIOslaves) for personal information management, including:
%patch7 -p1
%patch8 -p1
%patch9 -p1
-cd kicker/kicker
-%patch10 -p0
-cd -
+%patch10 -p1
%patch11 -p1
+%patch12 -p1
# Applies an optional distro-specific graphical theme
%if "%{?tde_bg}" != ""
@@ -317,9 +319,10 @@ cd build
%endif
# Moves the XDG configuration files to TDE directory
+%if "%{_prefix}" != "/usr"
%__mkdir_p "%{?buildroot}%{_prefix}/etc"
%__mv -f "%{?buildroot}%{_sysconfdir}/xdg" "%{?buildroot}%{_prefix}/etc"
-
+%endif
%clean
%__rm -rf %{?buildroot}
@@ -522,10 +525,17 @@ update-desktop-database %{_datadir}/applications > /dev/null 2>&1 || :
%{_datadir}/sounds/*
%{tde_libdir}/*
%{_libdir}/libkdeinit_*.*
+%if "%{_prefix}" != "/usr"
%{_prefix}/etc/xdg/menus/applications-merged/kde-essential.menu
%{_prefix}/etc/xdg/menus/kde-information.menu
%{_prefix}/etc/xdg/menus/kde-screensavers.menu
%{_prefix}/etc/xdg/menus/kde-settings.menu
+%else
+%{_sysconfdir}/xdg/menus/applications-merged/kde-essential.menu
+%{_sysconfdir}/xdg/menus/kde-information.menu
+%{_sysconfdir}/xdg/menus/kde-screensavers.menu
+%{_sysconfdir}/xdg/menus/kde-settings.menu
+%endif
/usr/share/xsessions/*.desktop
# Remove conflicts with redhat-menus
%if "%{?_prefix}" != "/usr"
@@ -583,6 +593,10 @@ update-desktop-database %{_datadir}/applications > /dev/null 2>&1 || :
%{_datadir}/cmake/*.cmake
%changelog
+* Fri Nov 18 2011 Francois Andriot <francois.andriot@free.fr> - 3.5.13-8
+- Updates Kickoff menu Fix [TDE Bugs #281, #508]
+- Adds KDM gcrypt dependency
+
* Sun Nov 13 2011 Francois Andriot <francois.andriot@free.fr> - 3.5.13-7
- Add distribution-specific start button icon