[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [Amarok] f3480f4: labels applet: Minor layout fixes / remove dead co
From:       Daniel Faust <hessijames () gmail ! com>
Date:       2010-12-09 16:53:59
Message-ID: 20101209165359.CB4B6A60AE () git ! kde ! org
[Download RAW message or body]

commit f3480f45cb1f405b98832be5fdc6870fd9639577
branch master
Author: Daniel Faust <hessijames@gmail.com>
Date:   Thu Dec 9 17:52:50 2010 +0100

    labels applet: Minor layout fixes / remove dead code

diff --git a/src/context/applets/labels/LabelGraphicsItem.cpp \
b/src/context/applets/labels/LabelGraphicsItem.cpp index 7281335..494feb9 100644
--- a/src/context/applets/labels/LabelGraphicsItem.cpp
+++ b/src/context/applets/labels/LabelGraphicsItem.cpp
@@ -179,9 +179,9 @@ LabelGraphicsItem::updateGeometry()
     const int iconsSpace = qMin( iconsSpaceA, iconsSpaceB );
     // if there's enough space left, start the icons at the same position as the \
text  // align buttons left
-    const int offset = qRound( qMin( ( size.width() - iconsSize * iconsCount - \
iconsSpace * ( iconsCount - 1 ) ) / 2, m_textItem->boundingRect().height() / 4 ) ); \
+//     const int offset = qRound( qMin( ( size.width() - iconsSize * iconsCount - \
iconsSpace * ( iconsCount - 1 ) ) / 2, m_textItem->boundingRect().height() / 4 ) );  \
                // align buttons centered
-//     const int offset = qRound( ( size.width() - iconsSize * iconsCount - \
iconsSpace * ( iconsCount - 1 ) ) / 2 ); +    const int offset = qRound( ( \
size.width() - iconsSize * iconsCount - iconsSpace * ( iconsCount - 1 ) ) / 2 );  
     m_addLabelItem.data()->setSize( iconsSize );
     m_addLabelItem.data()->setPos( offset, ( size.height() - iconsSize ) / 2 );
diff --git a/src/context/applets/labels/LabelsApplet.cpp \
b/src/context/applets/labels/LabelsApplet.cpp index 7747ede..378705a 100644
--- a/src/context/applets/labels/LabelsApplet.cpp
+++ b/src/context/applets/labels/LabelsApplet.cpp
@@ -385,7 +385,7 @@ LabelsApplet::constraintsEvent( Plasma::Constraints constraints )
         const qreal horzontalPadding = standardPadding() / 2;
         const qreal verticalPadding = standardPadding() / 2;
         qreal x_pos;
-        qreal y_pos = m_header->boundingRect().bottom() + standardPadding();
+        qreal y_pos = m_header->boundingRect().bottom() + 1.5 * standardPadding();
         qreal width = 0;
         qreal height = 0;
         int start_index = 0;
diff --git a/src/context/engines/labels/LabelsEngine.cpp \
b/src/context/engines/labels/LabelsEngine.cpp index cb07644..f227f1e 100644
--- a/src/context/engines/labels/LabelsEngine.cpp
+++ b/src/context/engines/labels/LabelsEngine.cpp
@@ -67,7 +67,6 @@ bool
 LabelsEngine::sourceRequestEvent( const QString &name )
 {
     DEBUG_BLOCK
-//     Q_UNUSED( name )
 
     Collections::Collection *coll = \
CollectionManager::instance()->primaryCollection();  if( coll )
@@ -178,11 +177,6 @@ LabelsEngine::update( bool reload )
     varUser.setValue< QStringList >( m_userLabels );
     setData( "labels", "user", varUser );
 
-    // send the web labels too, because the labels applet clears all web labels if \
                user labels arrive
-    QVariant varWeb;
-    varWeb.setValue< QMap< QString, QVariant > >( m_webLabels );
-    setData( "labels", "web", varWeb );
-
     m_try = 0;
     fetchLastFm();
 }


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic