rpms/kdebase/FC-4 kdebase-3.5.3-kfind-largefile.patch, NONE, 1.1 kdebase-3.5.3-kicker-panel.patch, NONE, 1.1 kdebase-3.5.3-kscreensaver.patch, NONE, 1.1 kdebase-3.5.3-kxkb-kcmlayout.patch, NONE, 1.1 kdebase.spec, 1.121, 1.122

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Wed Jun 14 22:55:06 UTC 2006


Author: than

Update of /cvs/dist/rpms/kdebase/FC-4
In directory cvs.devel.redhat.com:/tmp/cvs-serv6278

Modified Files:
	kdebase.spec 
Added Files:
	kdebase-3.5.3-kfind-largefile.patch 
	kdebase-3.5.3-kicker-panel.patch 
	kdebase-3.5.3-kscreensaver.patch 
	kdebase-3.5.3-kxkb-kcmlayout.patch 
Log Message:
add some upstream patches


kdebase-3.5.3-kfind-largefile.patch:
 kftabdlg.cpp |   49 ++++++++++++++++++++++++-------------------------
 kquery.cpp   |   31 +++++++++++++++++++++++--------
 kquery.h     |    7 ++++---
 3 files changed, 51 insertions(+), 36 deletions(-)

--- NEW FILE kdebase-3.5.3-kfind-largefile.patch ---
--- kdebase-3.5.3/kfind/kftabdlg.cpp.me	2006-06-10 01:00:47.000000000 +0200
+++ kdebase-3.5.3/kfind/kftabdlg.cpp	2006-06-10 01:01:31.000000000 +0200
@@ -183,6 +183,7 @@
     sizeUnitBox ->insertItem( i18n("Bytes") );
     sizeUnitBox ->insertItem( i18n("KB") );
     sizeUnitBox ->insertItem( i18n("MB") );
+    sizeUnitBox ->insertItem( i18n("GB") );
     sizeUnitBox ->setCurrentItem(1);
 
     int tmp = sizeEdit->fontMetrics().width(" 000000000 ");
@@ -574,7 +575,8 @@
 
 void KfindTabWidget::setQuery(KQuery *query)
 {
-	int size;
+  KIO::filesize_t size;
+  KIO::filesize_t sizeunit;
   bool itemAlreadyContained(false);
   // only start if we have valid dates
   if (!isDateValid()) return;
@@ -603,17 +605,25 @@
   switch (sizeUnitBox->currentItem())
   {
      case 0:
-         size = 1; //one byte
-			break;
+         sizeunit = 1; //one byte
+         break;
      case 2:
-         size = 1048576; //1M
-			break;
-		case 1:
-		default:
-			size=1024; //1k
-			break;
-  }
-  size = sizeEdit->value() * size;
+         sizeunit = 1048576; //1M
+         break;
+     case 3:
+         sizeunit = 1073741824; //1GB
+         break;
+     case 1: //fall to default case
+     default:
+         sizeunit = 1024; //1k
+         break;
+  }
+  size = sizeEdit->value() * sizeunit;
+
+// TODO: troeder: do we need this check since it is very unlikely-
+// to exceed ULLONG_MAX with INT_MAX * 1024^3.-
+// Or is there an arch where this can happen?
+#if 0
   if (size < 0)  // overflow
      if (KMessageBox::warningYesNo(this, i18n("Size is too big. Set maximum size value?"), i18n("Error"),i18n("Set"),i18n("Do Not Set"))
            == KMessageBox::Yes)
@@ -624,21 +634,10 @@
 		}
      else
         return;
+#endif
 
-  switch (sizeBox->currentItem())
-  {
-    case 1:
-      query->setSizeRange(size, -1);
-      break;
-    case 2:
-      query->setSizeRange(-1, size);
-      break;
-    case 3:
-      query->setSizeRange(size,size);
-      break;
-    default:
-      query->setSizeRange(-1, -1);
-  }
+  // set range mode and size value
+  query->setSizeRange(sizeBox->currentItem(),size,0);
 
   // dates
   QDateTime epoch;
--- kdebase-3.5.3/kfind/kquery.h.me	2006-06-10 01:01:11.000000000 +0200
+++ kdebase-3.5.3/kfind/kquery.h	2006-06-10 01:01:51.000000000 +0200
@@ -23,7 +23,7 @@
   KQuery(QObject *parent = 0, const char * name = 0);
   ~KQuery();
 
-  void setSizeRange( int min, int max );
+  void setSizeRange( int mode, KIO::filesize_t value1, KIO::filesize_t value2 );
   void setTimeRange( time_t from, time_t to );
   void setRegExp( const QString &regexp, bool caseSensitive );
   void setRecursive( bool recursive );
@@ -65,8 +65,9 @@
   void checkEntries();
 
   int m_filetype;
-  int m_minsize;
-  int m_maxsize;
+  int m_sizemode;
+  KIO::filesize_t m_sizeboundary1;
+  KIO::filesize_t m_sizeboundary2;
   KURL m_url;
   time_t m_timeFrom;
   time_t m_timeTo;
--- kdebase-3.5.3/kfind/kquery.cpp.me	2006-06-10 01:01:00.000000000 +0200
+++ kdebase-3.5.3/kfind/kquery.cpp	2006-06-10 01:01:50.000000000 +0200
@@ -14,7 +14,7 @@
 
 KQuery::KQuery(QObject *parent, const char * name)
   : QObject(parent, name),
-    m_minsize(-1), m_maxsize(-1),
+    m_sizemode(0), m_sizeboundary1(0), m_sizeboundary2(0),
     m_timeFrom(0), m_timeTo(0),
     job(0), m_insideCheckEntries(false), m_result(0)
 {
@@ -178,10 +178,24 @@
     if (!matched)
       return;
 
-    // make sure the files are in the correct range
-    if (  ( m_minsize >= 0 && (int)file->size() < m_minsize ) ||
-          ( m_maxsize >= 0 && (int)file->size() > m_maxsize ) )
-      return;
+    switch( m_sizemode )
+    {
+        case 1: // "at least"
+            if ( file->size() < m_sizeboundary1 ) return;
+            break;
+        case 2: // "at most"
+            if ( file->size() > m_sizeboundary1 ) return;
+            break;
+        case 3: // "equal"
+            if ( file->size() != m_sizeboundary1 ) return;
+            break;
+        case 4: // "between"
+            if ( (file->size() < m_sizeboundary1) || (file->size() > m_sizeboundary2) ) return;
+            break;
+        case 0: // "none" -> fall to default
+        default:
+            break;
+    }
 
     // make sure it's in the correct date range
     // what about 0 times?
@@ -403,10 +417,11 @@
   m_filetype = filetype;
 }
 
-void KQuery::setSizeRange(int min, int max)
+void KQuery::setSizeRange(int mode, KIO::filesize_t value1, KIO::filesize_t value2)
 {
-  m_minsize = min;
-  m_maxsize = max;
+  m_sizemode = mode;
+  m_sizeboundary1 = value1;
+  m_sizeboundary2 = value2;
 }
 
 void KQuery::setTimeRange(time_t from, time_t to)

kdebase-3.5.3-kicker-panel.patch:
 panelbutton.cpp |   11 ++++++++---
 1 files changed, 8 insertions(+), 3 deletions(-)

--- NEW FILE kdebase-3.5.3-kicker-panel.patch ---
--- kdebase-3.5.3/kicker/libkicker/panelbutton.cpp.orig	2006-06-10 00:46:06.000000000 +0200
+++ kdebase-3.5.3/kicker/libkicker/panelbutton.cpp	2006-06-10 00:46:21.000000000 +0200
@@ -631,7 +631,8 @@
     if (m_drawArrow && (m_highlight || active))
     {
         QStyle::PrimitiveElement e = QStyle::PE_ArrowUp;
-        QRect r(width() / 2 - 4, 0, 8, 8);
+        int arrowSize = style().pixelMetric(QStyle::PM_MenuButtonIndicator);
+        QRect r((width() - arrowSize)/2, 0, arrowSize, arrowSize);
 
         switch (m_arrowDirection)
         {
@@ -640,27 +641,31 @@
                 break;
             case KPanelExtension::Bottom:
                 e = QStyle::PE_ArrowDown;
-                r.moveBy(0, height() - 8);
+                r.moveBy(0, height() - arrowSize);
                 break;
             case KPanelExtension::Right:
                 e = QStyle::PE_ArrowRight;
-                r.moveBy(width() - 8 , 0);
+                r = QRect(width() - arrowSize, (height() - arrowSize)/2, arrowSize, arrowSize);
                 break;
             case KPanelExtension::Left:
                 e = QStyle::PE_ArrowLeft;
+                r = QRect(0, (height() - arrowSize)/2, arrowSize, arrowSize);
                 break;
             case KPanelExtension::Floating:
                 if (orientation() == Horizontal)
                 {
                     e = QStyle::PE_ArrowDown;
+                    r.moveBy(0, height() - arrowSize);
                 }
                 else if (QApplication::reverseLayout())
                 {
                     e = QStyle::PE_ArrowLeft;
+                    r = QRect(0, (height() - arrowSize)/2, arrowSize, arrowSize);
                 }
                 else
                 {
                     e = QStyle::PE_ArrowRight;
+                    r = QRect(width() - arrowSize, (height() - arrowSize)/2, arrowSize, arrowSize);
                 }
                 break;
         }

kdebase-3.5.3-kscreensaver.patch:
 lockeng.cc   |   12 ++++++++----
 xautolock.cc |   11 ++++++++---
 2 files changed, 16 insertions(+), 7 deletions(-)

--- NEW FILE kdebase-3.5.3-kscreensaver.patch ---
--- kdebase-3.5.3/kdesktop/lockeng.cc.orig	2006-06-10 00:11:36.000000000 +0200
+++ kdebase-3.5.3/kdesktop/lockeng.cc	2006-06-10 00:13:41.000000000 +0200
@@ -42,9 +42,6 @@
     XGetScreenSaver(qt_xdisplay(), &mXTimeout, &mXInterval,
                     &mXBlanking, &mXExposures);
 
-    // We'll handle blanking
-    XSetScreenSaver(qt_xdisplay(), 0, mXInterval, mXBlanking, mXExposures);
-
     mState = Waiting;
     mXAutoLock = 0;
     mEnabled = false;
@@ -158,6 +155,9 @@
         mXAutoLock->setDPMS(mDPMS);
 	//mXAutoLock->changeCornerLockStatus( mLockCornerTopLeft, mLockCornerTopRight, mLockCornerBottomLeft, mLockCornerBottomRight);
 
+        // We'll handle blanking 
+        XSetScreenSaver(qt_xdisplay(), mTimeout + 10, mXInterval, mXBlanking, mXExposures);
+
         mXAutoLock->start();
 
         kdDebug(1204) << "Saver Engine started, timeout: " << mTimeout << endl;
@@ -170,6 +170,7 @@
 	    mXAutoLock = 0;
 	}
 
+	XSetScreenSaver(qt_xdisplay(), 0, mXInterval, mXBlanking, mXExposures);
         kdDebug(1204) << "Saver Engine disabled" << endl;
     }
 
@@ -291,7 +292,6 @@
     kdDebug(1204) << "SaverEngine: stopping lock" << endl;
     emitDCOPSignal("KDE_stop_screensaver()", QByteArray());
 
-
     mLockProcess.kill();
 
     if (mXAutoLock)
@@ -300,6 +300,7 @@
     }
     processLockTransactions();
     mState = Waiting;
+    XSetScreenSaver(qt_xdisplay(), mTimeout + 10, mXInterval, mXBlanking, mXExposures);
 }
 
 void SaverEngine::lockProcessExited()
@@ -314,6 +315,7 @@
     }
     processLockTransactions();
     mState = Waiting;
+    XSetScreenSaver(qt_xdisplay(), mTimeout + 10, mXInterval, mXBlanking, mXExposures);
 }
 
 //---------------------------------------------------------------------------
@@ -322,6 +324,8 @@
 //
 void SaverEngine::idleTimeout()
 {
+    // disable X screensaver
+    XSetScreenSaver(qt_xdisplay(), 0, mXInterval, mXBlanking, mXExposures);
     startLockProcess( DefaultLock );
 }
 
--- kdebase-3.5.3/kdesktop/xautolock.cc.orig	2006-06-10 00:11:55.000000000 +0200
+++ kdebase-3.5.3/kdesktop/xautolock.cc	2006-06-10 00:13:59.000000000 +0200
@@ -192,6 +192,7 @@
 
     bool activate = false;
 
+    kdDebug() << now << " " << mTrigger << endl;
     if (now >= mTrigger)
     {
         resetTrigger();
@@ -202,6 +203,8 @@
     BOOL on;
     CARD16 state;
     DPMSInfo( qt_xdisplay(), &state, &on );
+
+    kdDebug() << "DPMSInfo " << state << " " << on << endl;
     // If DPMS is active, it makes XScreenSaverQueryInfo() report idle time
     // that is always smaller than DPMS timeout (X bug I guess). So if DPMS
     // saving is active, simply always activate our saving too, otherwise
@@ -217,9 +220,11 @@
 #ifdef HAVE_XSCREENSAVER
     static XScreenSaverInfo* mitInfo = 0;
     if (!mitInfo) mitInfo = XScreenSaverAllocInfo ();
-    XScreenSaverQueryInfo (qt_xdisplay(), DefaultRootWindow (qt_xdisplay()), mitInfo);
-    if (mitInfo->state == ScreenSaverDisabled)
-	activate = false;
+    if (XScreenSaverQueryInfo (qt_xdisplay(), DefaultRootWindow (qt_xdisplay()), mitInfo)) {
+        kdDebug() << "XScreenSaverQueryInfo " << mitInfo->state << " " << ScreenSaverDisabled << endl;
+        if (mitInfo->state == ScreenSaverDisabled)
+	    activate = false;
+    }
 #endif
 
     if(mActive && activate)

kdebase-3.5.3-kxkb-kcmlayout.patch:
 kcmlayout.cpp |    1 +
 1 files changed, 1 insertion(+)

--- NEW FILE kdebase-3.5.3-kxkb-kcmlayout.patch ---
--- kdebase-3.5.3/kxkb/kcmlayout.cpp.orig	2006-06-10 00:53:38.000000000 +0200
+++ kdebase-3.5.3/kxkb/kcmlayout.cpp	2006-06-10 00:54:08.000000000 +0200
@@ -186,6 +186,7 @@
 	widget->comboModel->setCurrentText(i18n(modelName));
 
 	QValueList<LayoutUnit> otherLayouts = m_kxkbConfig.m_layouts;
+	widget->listLayoutsDst->clear();
 // to optimize we should have gone from it.end to it.begin
 	QValueList<LayoutUnit>::ConstIterator it;
 	for (it = otherLayouts.begin(); it != otherLayouts.end(); ++it ) {


Index: kdebase.spec
===================================================================
RCS file: /cvs/dist/rpms/kdebase/FC-4/kdebase.spec,v
retrieving revision 1.121
retrieving revision 1.122
diff -u -r1.121 -r1.122
--- kdebase.spec	14 Jun 2006 22:21:44 -0000	1.121
+++ kdebase.spec	14 Jun 2006 22:55:04 -0000	1.122
@@ -56,9 +56,15 @@
 Patch16: kdebase-3.3.1-pam_krb5-bz#191049.patch
 Patch17: kdebase-3.5.2-kconf_update-klipper.patch
 
+# upstream patches
+Patch100: kdebase-3.5.3-kfind-largefile.patch
+Patch101: kdebase-3.5.3-kicker-panel.patch
+Patch102: kdebase-3.5.3-kscreensaver.patch
+Patch103: kdebase-3.5.3-kxkb-kcmlayout.patch
+
 # security fixes
-# Patch 100, KDE Security Advisory, CVE-2006-2449, kdm file disclosure
-Patch100: post-3.3.0-kdebase-kdm.diff
+# Patch 300, KDE Security Advisory, CVE-2006-2449, kdm file disclosure
+Patch300: post-3.3.0-kdebase-kdm.diff
 
 Requires: kdelibs >= 6:%{version}
 Requires: libxml2 >= 2.6.5
@@ -143,8 +149,14 @@
 %patch16 -p1 -b .pam_krb5-bz#191049
 %patch17 -p1 -b .klipper
 
+# upstream patches
+%patch100 -p1 -b .kfind-largefile
+%patch101 -p1 -b .kicker-panel
+%patch102 -p1 -b .kscreensaver
+%patch103 -p1 -b .kxkb-kcmlayout
+
 # security fixes
-%patch100 -p0 -b .CVE-2006-2449
+%patch300 -p0 -b .CVE-2006-2449
 
 %if %{rhel}
    rm -rf kdeprint/kdeprintfax
@@ -358,6 +370,7 @@
 
 %files
 %defattr(-,root,root)
+%doc AUTHORS COPYING README
 %doc %{_docdir}/HTML/en/*
 %config(noreplace) /etc/ksysguarddrc
 /etc/kde




More information about the fedora-cvs-commits mailing list