Hello community,

here is the log from the commit of package ksnapshot for openSUSE:Factory 
checked in at 2012-01-27 15:21:00
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/ksnapshot (Old)
 and      /work/SRC/openSUSE:Factory/.ksnapshot.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "ksnapshot", Maintainer is "kde-maintain...@suse.de"

Changes:
--------
--- /work/SRC/openSUSE:Factory/ksnapshot/ksnapshot.changes      2011-12-08 
12:11:56.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.ksnapshot.new/ksnapshot.changes 2012-01-27 
15:21:26.000000000 +0100
@@ -1,0 +2,16 @@
+Wed Jan 18 20:59:00 CET 2012 - dmuel...@suse.de
+
+- update to 4.8.0
+  * first stable release of KDE 4.8 (only critical fixes over 4.7.98)
+  * see http://kde.org/announcements/4.8/ for details
+  
+
+-------------------------------------------------------------------
+Tue Jan 10 18:46:44 CET 2012 - dmuel...@suse.de
+
+- update to 4.7.98
+  * RC2+ milestone release of KDE 4.8
+  *  see http://kde.org/announcements/4.8/ for details
+  
+
+-------------------------------------------------------------------

Old:
----
  ksnapshot-4.7.4.tar.bz2

New:
----
  ksnapshot-4.8.0.tar.bz2

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ ksnapshot.spec ++++++
--- /var/tmp/diff_new_pack.mPadHu/_old  2012-01-27 15:21:27.000000000 +0100
+++ /var/tmp/diff_new_pack.mPadHu/_new  2012-01-27 15:21:27.000000000 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package ksnapshot
 #
-# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -27,7 +27,7 @@
 %else
 BuildRequires:  sane-backends
 %endif
-Version:        4.7.4
+Version:        4.8.0
 Release:        0
 Summary:        Screen Capture Program
 License:        GPL-2.0+

++++++ ksnapshot-4.7.4.tar.bz2 -> ksnapshot-4.8.0.tar.bz2 ++++++
Files old/ksnapshot-4.7.4/doc/index.cache.bz2 and 
new/ksnapshot-4.8.0/doc/index.cache.bz2 differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/ksnapshot-4.7.4/kbackgroundsnapshot.cpp 
new/ksnapshot-4.8.0/kbackgroundsnapshot.cpp
--- old/ksnapshot-4.7.4/kbackgroundsnapshot.cpp 2011-05-20 22:36:23.000000000 
+0200
+++ new/ksnapshot-4.8.0/kbackgroundsnapshot.cpp 2011-08-07 17:42:00.000000000 
+0200
@@ -105,8 +105,8 @@
     grabber->hide();
     if ( modeCapture == ChildWindow ) {
         WindowGrabber wndGrab;
-        connect( &wndGrab, SIGNAL( windowGrabbed( const QPixmap & ) ),
-                           SLOT( slotWindowGrabbed( const QPixmap & ) ) );
+        connect( &wndGrab, SIGNAL(windowGrabbed(QPixmap)),
+                           SLOT(slotWindowGrabbed(QPixmap)) );
         wndGrab.exec();
         savePictureOnDesktop();
     }
@@ -140,8 +140,8 @@
 void KBackgroundSnapshot::grabRegion()
 {
    rgnGrab = new RegionGrabber();
-   connect( rgnGrab, SIGNAL( regionGrabbed( const QPixmap & ) ),
-                     SLOT( slotRegionGrabbed( const QPixmap & ) ) );
+   connect( rgnGrab, SIGNAL(regionGrabbed(QPixmap)),
+                     SLOT(slotRegionGrabbed(QPixmap)) );
 
 }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/ksnapshot-4.7.4/ksnapshot.cpp 
new/ksnapshot-4.8.0/ksnapshot.cpp
--- old/ksnapshot-4.7.4/ksnapshot.cpp   2011-05-20 22:36:23.000000000 +0200
+++ new/ksnapshot-4.8.0/ksnapshot.cpp   2011-08-07 17:42:00.000000000 +0200
@@ -262,9 +262,9 @@
     setIncludeDecorations(conf.readEntry("includeDecorations",true));
     filename = KUrl( conf.readPathEntry( "filename", 
QDir::currentPath()+'/'+i18n("snapshot")+"1.png" ));
 
-    connect( &grabTimer, SIGNAL( timeout() ), this, SLOT(  grabTimerDone() ) );
-    connect( &updateTimer, SIGNAL( timeout() ), this, SLOT(  updatePreview() ) 
);
-    QTimer::singleShot( 0, this, SLOT( updateCaption() ) );
+    connect( &grabTimer, SIGNAL(timeout()), this, SLOT(grabTimerDone()) );
+    connect( &updateTimer, SIGNAL(timeout()), this, SLOT(updatePreview()) );
+    QTimer::singleShot( 0, this, SLOT(updateCaption()) );
 
     KHelpMenu *helpMenu = new KHelpMenu(this, 
KGlobal::mainComponent().aboutData(), true);
     setButtonMenu( Help, helpMenu->menu() );
@@ -639,16 +639,16 @@
 void KSnapshot::grabRegion()
 {
    rgnGrab = new RegionGrabber();
-   connect( rgnGrab, SIGNAL( regionGrabbed( const QPixmap & ) ),
-                     SLOT( slotRegionGrabbed( const QPixmap & ) ) );
+   connect( rgnGrab, SIGNAL(regionGrabbed(QPixmap)),
+                     SLOT(slotRegionGrabbed(QPixmap)) );
 
 }
 
 void KSnapshot::grabFreeRegion()
 {
    freeRgnGrab = new FreeRegionGrabber();
-   connect( freeRgnGrab, SIGNAL( freeRegionGrabbed( const QPixmap & ) ),
-                     SLOT( slotRegionGrabbed( const QPixmap & ) ) );
+   connect( freeRgnGrab, SIGNAL(freeRegionGrabbed(QPixmap)),
+                     SLOT(slotRegionGrabbed(QPixmap)) );
 
 }
 
@@ -680,8 +680,8 @@
 
     if ( mode() == ChildWindow ) {
         WindowGrabber wndGrab;
-        connect( &wndGrab, SIGNAL( windowGrabbed( const QPixmap & ) ),
-                           SLOT( slotWindowGrabbed( const QPixmap & ) ) );
+        connect( &wndGrab, SIGNAL(windowGrabbed(QPixmap)),
+                           SLOT(slotWindowGrabbed(QPixmap)) );
         wndGrab.exec();
         QPoint offset = wndGrab.lastWindowPosition();
         x = offset.x();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/ksnapshot-4.7.4/ksnapshot.desktop 
new/ksnapshot-4.8.0/ksnapshot.desktop
--- old/ksnapshot-4.7.4/ksnapshot.desktop       2011-10-28 09:44:57.000000000 
+0200
+++ new/ksnapshot-4.8.0/ksnapshot.desktop       2012-01-10 15:15:47.000000000 
+0100
@@ -17,7 +17,7 @@
 GenericName[es]=Capturador de pantalla
 GenericName[et]=Töölaua pildistamine
 GenericName[eu]=Pantailari argazkiak ateratzeko programa
-GenericName[fa]=برنامۀ گیراندازی پرده
+GenericName[fa]=برنامه گیراندازی پرده
 GenericName[fi]=Ruudunkaappausohjelma
 GenericName[fr]=Programme de capture d'écran
 GenericName[ga]=Clár gabhála scáileáin
@@ -51,7 +51,7 @@
 GenericName[se]=Šearbmagovvenprográmma
 GenericName[si]=තිරපිටපත් ගැණීමේ වැඩසටහන
 GenericName[sk]=Zachytenie obrazovky
-GenericName[sl]=Program za zajem zaslona
+GenericName[sl]=Program za zajemanje zaslona
 GenericName[sr]=Програм за снимање екрана
 GenericName[sr@ijekavian]=Програм за снимање екрана
 GenericName[sr@ijekavianlatin]=Program za snimanje ekrana
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/ksnapshot-4.7.4/snapshottimer.cpp 
new/ksnapshot-4.8.0/snapshottimer.cpp
--- old/ksnapshot-4.7.4/snapshottimer.cpp       2011-05-20 22:36:23.000000000 
+0200
+++ new/ksnapshot-4.8.0/snapshottimer.cpp       2011-10-11 16:47:35.000000000 
+0200
@@ -21,16 +21,20 @@
 #include <QPainter>
 #include <QPaintEvent>
 #include <QToolTip>
+#include <QApplication>
+#include <QDesktopWidget>
 
 #include <KDebug>
 #include <klocale.h>
 
-SnapshotTimer::SnapshotTimer() : QWidget(0)
+SnapshotTimer::SnapshotTimer()
+    : QWidget(0),
+      toggle(true)
 {
     setWindowFlags( Qt::WindowStaysOnTopHint | Qt::FramelessWindowHint | 
Qt::X11BypassWindowManagerHint);
     // The text is copied from paintEvent and the maximum number is used as %1 
argument + margins
-    resize( fontMetrics().width( i18np("Snapshot will be taken in 1 second",
-                                       "Snapshot will be taken in %1 seconds", 
99) ) + 6 , fontMetrics().height() + 4 );
+    resize(fontMetrics().width(i18np("Snapshot will be taken in 1 second",
+                                     "Snapshot will be taken in %1 seconds", 
99) ) + 6, fontMetrics().height() + 4);
     connect(&timer, SIGNAL(timeout()), this, SLOT(bell()));
 }
 
@@ -40,10 +44,13 @@
 
 void SnapshotTimer::start(int seconds)
 {
-    show();
+    const QRect screenGeom = qApp->desktop()->screenGeometry();
+    move(screenGeom.width() / 2 - size().width() / 2, screenGeom.top());
+    toggle = true;
     time = 0;
     length = seconds;
     timer.start(1000);
+    show();
 }
 
 void SnapshotTimer::stop()
@@ -57,16 +64,29 @@
 {
     if (time == length - 1) {
         hide();
-    } else {
+    }
+    else {
         if (time == length) {
             emit timeout();
             timer.stop();
         }
     }
     ++time;
+    toggle = !toggle;
     update();
 }
 
+void SnapshotTimer::enterEvent(QEvent *)
+{
+    const QRect screenGeom = qApp->desktop()->screenGeometry();
+    if (x() == screenGeom.left()) {
+        move(screenGeom.x() + (screenGeom.width() / 2 - size().width() / 2), 
screenGeom.top());
+    }
+    else {
+        move(screenGeom.topLeft());
+    }
+}
+
 void SnapshotTimer::paintEvent( QPaintEvent* e )
 {
     Q_UNUSED( e );
@@ -80,15 +100,17 @@
       QColor overlayColor( 0, 0, 0, 160 );
       QColor textColor = pal.color( QPalette::Active, QPalette::Text );
       QColor textBackgroundColor = pal.color( QPalette::Active, QPalette::Base 
);
-
+      if (toggle){
+          textColor = pal.color( QPalette::Active, QPalette::Text);
+      }
+      else {
+          textColor = pal.color( QPalette::Active, QPalette::Base);
+      }
       painter.setPen( textColor );
       painter.setBrush( textBackgroundColor );
-      QString helpText = i18np( "Snapshot will be taken in 1 second",
-                                "Snapshot will be taken in %1 seconds", ( 
length-time ) );
-      QRect textRect = painter.boundingRect( rect().adjusted( 2, 2, -2, -2 ), 
Qt::TextSingleLine, helpText );
-      textRect.adjust( -2, -2, 4, 2 );
-      painter.drawRect( rect().adjusted(0,0,-1,-1) );
-      textRect.moveTopLeft( QPoint( 3, 3 ) );
+      const QString helpText = i18np("Snapshot will be taken in 1 second",
+                                     "Snapshot will be taken in %1 seconds", 
length - time);
+      textRect = painter.boundingRect(rect().adjusted(2, 2, -2, -2), 
Qt::AlignHCenter | Qt::TextSingleLine, helpText);
       painter.drawText(textRect, helpText);
     }
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/ksnapshot-4.7.4/snapshottimer.h 
new/ksnapshot-4.8.0/snapshottimer.h
--- old/ksnapshot-4.7.4/snapshottimer.h 2011-05-20 22:36:23.000000000 +0200
+++ new/ksnapshot-4.8.0/snapshottimer.h 2011-10-11 16:47:35.000000000 +0200
@@ -40,12 +40,15 @@
     void bell();
 
   protected:
-    void paintEvent( QPaintEvent* e );
+    void paintEvent(QPaintEvent *e);
+    void enterEvent(QEvent *e);
 
   private:
     QTimer timer;
+    QRect textRect;
     int time;
     int length;
+    bool toggle;
 };
 
 #endif

-- 
To unsubscribe, e-mail: opensuse-commit+unsubscr...@opensuse.org
For additional commands, e-mail: opensuse-commit+h...@opensuse.org

Reply via email to