try harder to enforce a minimum size of 16x16
svn path=/trunk/KDE/kdelibs/; revision=1066278
This commit is contained in:
parent
b521f3e158
commit
a69bcc4827
@ -630,7 +630,7 @@ void AppletHandle::mouseMoveEvent(QGraphicsSceneMouseEvent *event)
|
|||||||
QSizeF min = m_applet->minimumSize();
|
QSizeF min = m_applet->minimumSize();
|
||||||
QSizeF max = m_applet->maximumSize();
|
QSizeF max = m_applet->maximumSize();
|
||||||
|
|
||||||
if (min.isEmpty()) {
|
if (min.width() < KIconLoader::SizeSmall || min.height() < KIconLoader::SizeSmall) {
|
||||||
min = m_applet->effectiveSizeHint(Qt::MinimumSize);
|
min = m_applet->effectiveSizeHint(Qt::MinimumSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -640,7 +640,7 @@ void AppletHandle::mouseMoveEvent(QGraphicsSceneMouseEvent *event)
|
|||||||
|
|
||||||
// If the applet doesn't have a minimum size, calculate based on a
|
// If the applet doesn't have a minimum size, calculate based on a
|
||||||
// minimum content area size of 16x16 (KIconLoader::SizeSmall)
|
// minimum content area size of 16x16 (KIconLoader::SizeSmall)
|
||||||
if (min.isEmpty()) {
|
if (min.width() < KIconLoader::SizeSmall || min.height() < KIconLoader::SizeSmall) {
|
||||||
min = m_applet->boundingRect().size() - m_applet->contentsRect().size();
|
min = m_applet->boundingRect().size() - m_applet->contentsRect().size();
|
||||||
min = QSizeF(KIconLoader::SizeSmall, KIconLoader::SizeSmall);
|
min = QSizeF(KIconLoader::SizeSmall, KIconLoader::SizeSmall);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user