[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: extragear/multimedia/amarok/src/context
From: Leo Franchi <lfranchi () kde ! org>
Date: 2008-10-30 11:56:43
Message-ID: 1225367803.471613.6252.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 877797 by lfranchi:
fix large current track startup size. this was becuuse (i think) we were using the \
live CV width (which can be inaccurate *during* startup) instead of saved width for \
initial calculations.
BUG: 171510
M +1 -0 applets/currenttrack/CurrentTrack.cpp
M +9 -2 containments/ColumnContainment.cpp
--- trunk/extragear/multimedia/amarok/src/context/applets/currenttrack/CurrentTrack.cpp \
#877796:877797 @@ -376,6 +376,7 @@
//bail out if there is no room to paint. Prevents crashes and really there is no \
sense in painting if the //context view has been minimized completely
+ debug() << "current track painting in rect:" << contentsRect;
if( ( contentsRect.width() < 20 ) || ( contentsRect.height() < 20 ) )
{
foreach ( QGraphicsItem * childItem, QGraphicsItem::children() )
--- trunk/extragear/multimedia/amarok/src/context/containments/ColumnContainment.cpp \
#877796:877797 @@ -385,6 +385,7 @@
if( m_manageCurrentTrack )
{
debug() << "adding current track";
+ m_appletsFromConfigCount++;
Plasma::Containment::addApplet( "currenttrack" );
}
@@ -599,6 +600,7 @@
DEBUG_LINE_INFO
width = m_currentColumns ? m_width / m_currentColumns : m_width;
m_appletsFromConfigCount--;
+ debug() << "using false width of" << width << "instead of real:" << \
m_currentColumns << m_maxColumnWidth / m_currentColumns << m_maxColumnWidth; }
else
width = m_currentColumns ? m_maxColumnWidth / m_currentColumns : \
m_maxColumnWidth; @@ -609,20 +611,25 @@
qreal aspectRatio = height / (qreal)width;
int rowSpan = aspectRatio / 0.3;
+ /*
+ debug() << "calculating rowspan, aspectratio = height / width";
+ debug() << aspectRatio << " = " << height << " / " << width;
+ debug() << "rowspan = aspectRatio / 0.3";
+ debug() << rowSpan << " = " << aspectRatio << " / 3"; */
int colSpan = 1;
if( rowSpan == 0 || aspectRatio * 100 > 30 && ( int )( aspectRatio * 100 ) % 30 \
> 15 ) rowSpan += 1;
rowSpan = qMin( rowSpan, m_currentRows );
-
+ /*
debug() << "current columns: " << m_currentColumns;
debug() << "current rows: " << m_currentRows;
debug() << "applet: " << applet->pluginName();
debug() << "width: " << width;
debug() << "height: " << height;
debug() << "rowspan: " << rowSpan;
-
+ */
int col = 0;
int row = 0;
bool positionFound = false;
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic