rev 12104 - in branches/kde4/packages/kdebase-workspace/debian: . patches

Armin Berres trigger-guest at alioth.debian.org
Sat Sep 6 09:31:02 UTC 2008


Author: trigger-guest
Date: 2008-09-06 09:31:02 +0000 (Sat, 06 Sep 2008)
New Revision: 12104

Added:
   branches/kde4/packages/kdebase-workspace/debian/patches/22_execute_ktrash4.diff
   branches/kde4/packages/kdebase-workspace/debian/patches/50_icon_in_oxygen_title_bar.diff
Removed:
   branches/kde4/packages/kdebase-workspace/debian/patches/22_icon_in_oxygen_title_bar.diff
Modified:
   branches/kde4/packages/kdebase-workspace/debian/changelog
   branches/kde4/packages/kdebase-workspace/debian/patches/series
Log:
add patch for #494427

Modified: branches/kde4/packages/kdebase-workspace/debian/changelog
===================================================================
--- branches/kde4/packages/kdebase-workspace/debian/changelog	2008-09-06 06:52:56 UTC (rev 12103)
+++ branches/kde4/packages/kdebase-workspace/debian/changelog	2008-09-06 09:31:02 UTC (rev 12104)
@@ -1,3 +1,10 @@
+kdebase-workspace (4:4.1.1-2) experimental; urgency=low
+
+  * Make the plasma trash applet call KDE 4's and not KDE 3's ktrash.
+    Thanks to George Kiagiadakis for the patch (Closes: #494427).
+
+ -- Armin Berres <trigger+debian at space-based.de>  Sat, 06 Sep 2008 11:27:22 +0200
+
 kdebase-workspace (4:4.1.1-1) experimental; urgency=low
 
   * New upstream release.

Added: branches/kde4/packages/kdebase-workspace/debian/patches/22_execute_ktrash4.diff
===================================================================
--- branches/kde4/packages/kdebase-workspace/debian/patches/22_execute_ktrash4.diff	                        (rev 0)
+++ branches/kde4/packages/kdebase-workspace/debian/patches/22_execute_ktrash4.diff	2008-09-06 09:31:02 UTC (rev 12104)
@@ -0,0 +1,14 @@
+We renamed ktrash to ktrash4. See bug #494427.
+Index: kdebase-workspace/plasma/applets/trash/trash.cpp
+===================================================================
+--- kdebase-workspace.orig/plasma/applets/trash/trash.cpp	2008-09-06 11:24:09.000000000 +0200
++++ kdebase-workspace/plasma/applets/trash/trash.cpp	2008-09-06 11:24:40.000000000 +0200
+@@ -193,7 +193,7 @@
+         // we can simply call ktrash.
+         //KonqOperations::emptyTrash(&m_menu);
+         KProcess process;
+-        process << KStandardDirs::findExe("ktrash") << "--empty";
++        process << KStandardDirs::findExe("ktrash4") << "--empty";
+         process.execute();
+ 
+     }

Deleted: branches/kde4/packages/kdebase-workspace/debian/patches/22_icon_in_oxygen_title_bar.diff

Copied: branches/kde4/packages/kdebase-workspace/debian/patches/50_icon_in_oxygen_title_bar.diff (from rev 12103, branches/kde4/packages/kdebase-workspace/debian/patches/22_icon_in_oxygen_title_bar.diff)
===================================================================
--- branches/kde4/packages/kdebase-workspace/debian/patches/50_icon_in_oxygen_title_bar.diff	                        (rev 0)
+++ branches/kde4/packages/kdebase-workspace/debian/patches/50_icon_in_oxygen_title_bar.diff	2008-09-06 09:31:02 UTC (rev 12104)
@@ -0,0 +1,90 @@
+We planned once to add a debioan icon in the titlebar of active windows.
+Unused right now.
+--- a/kwin/clients/oxygen/oxygenclient.cpp
++++ b/kwin/clients/oxygen/oxygenclient.cpp
+@@ -57,6 +57,9 @@
+ #include "oxygenbutton.h"
+ #include "oxygen.h"
+ 
++#define logourl "/usr/share/kde4/apps/kwin/titlebar_decor.png"
++#define logoOffset 9
++
+ namespace Oxygen
+ {
+ 
+@@ -73,6 +76,7 @@
+     , colorCacheInvalid_(true)
+     , helper_(*globalHelper)
+ {
++    logo.load(logourl);
+ }
+ 
+ OxygenClient::~OxygenClient()
+@@ -237,9 +241,9 @@
+ }
+ 
+ 
+-QColor OxygenClient::titlebarTextColor(const QPalette &palette)
++QColor OxygenClient::titlebarTextColor(const QPalette &palette, bool active)
+ {
+-    if (isActive())
++    if (active)
+         return palette.color(QPalette::Active, QPalette::WindowText);
+     else {
+         if(colorCacheInvalid_) {
+@@ -255,6 +259,9 @@
+     }
+ }
+ 
++QColor OxygenClient::titlebarTextColor(const QPalette &palette) {
++    return titlebarTextColor(palette, isActive());
++}
+ 
+ void OxygenClient::paintEvent(QPaintEvent *e)
+ {
+@@ -280,12 +287,14 @@
+     const int titleEdgeLeft = layoutMetric(LM_TitleEdgeLeft);
+     const int marginLeft = layoutMetric(LM_TitleBorderLeft);
+     const int marginRight = layoutMetric(LM_TitleBorderRight);
++    const int borderLeft = layoutMetric(LM_BorderLeft, true) + (layoutMetric(LM_BorderLeft, true) == 0 ? -1 : 0);
+ 
+     const int titleLeft = frame.left() + titleEdgeLeft + buttonsLeftWidth() + marginLeft;
++    const int fullLogoOffset = (logo.isNull() ? 0 : logo.width() + logoOffset - borderLeft);
+     const int titleWidth = frame.width() -
+             titleEdgeLeft - layoutMetric(LM_TitleEdgeRight) -
+             buttonsLeftWidth() - buttonsRightWidth() -
+-            marginLeft - marginRight;
++            marginLeft - marginRight - fullLogoOffset;
+ 
+ 
+     int splitY = qMin(300, 3*frame.height()/4);
+@@ -317,6 +326,15 @@
+     painter.drawText(titleLeft, titleTop-1, titleWidth, titleHeight,  // -1 is to go into top resizearea
+               OxygenFactory::titleAlign() | Qt::AlignVCenter, caption());
+ 
++    if (!logo.isNull() && isActive()) {
++        QPixmap pix(logo.width(),logo.height());
++        pix.fill(titlebarTextColor(palette, false));
++        pix.setAlphaChannel(logo.alphaChannel());
++        QFontMetrics fm(options()->font(isActive(), false));
++        painter.drawPixmap(titleEdgeLeft + layoutMetric(LM_TitleEdgeRight) + buttonsLeftWidth()
++          + qMin(fm.width(caption()), titleWidth) + logoOffset - borderLeft, titleTop, pix);
++    }
++
+     painter.setRenderHint(QPainter::Antialiasing);
+ 
+     // Draw dividing line
+--- a/kwin/clients/oxygen/oxygenclient.h
++++ b/kwin/clients/oxygen/oxygenclient.h
+@@ -53,9 +53,11 @@
+ 
+ private:
+     void paintEvent(QPaintEvent *e);
++    QColor titlebarTextColor(const QPalette &palette, bool active);
+     QColor titlebarTextColor(const QPalette &palette);
+     bool colorCacheInvalid_;
+     QColor cachedTitlebarTextColor_;
++    QPixmap logo;
+ 
+ protected:
+     friend class OxygenButton;


Property changes on: branches/kde4/packages/kdebase-workspace/debian/patches/50_icon_in_oxygen_title_bar.diff
___________________________________________________________________
Name: svn:mergeinfo
   + 

Modified: branches/kde4/packages/kdebase-workspace/debian/patches/series
===================================================================
--- branches/kde4/packages/kdebase-workspace/debian/patches/series	2008-09-06 06:52:56 UTC (rev 12103)
+++ branches/kde4/packages/kdebase-workspace/debian/patches/series	2008-09-06 09:31:02 UTC (rev 12104)
@@ -8,3 +8,4 @@
 16_kdm_consolekit.diff
 20_use_dejavu_as_default_font.diff
 21_kdm_doesnt_use_kstandarddirs.diff
+22_execute_ktrash4.diff




More information about the pkg-kde-commits mailing list