X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fqtui%2Fchatitem.cpp;h=036a6e62b49cec2a401677ea7013ae22bb74fd3f;hp=7a11a6653a8c3cd863ce1cdabbc7757b03dfd83e;hb=5cb0dfcd0cb0d5ee49fc4ca0de6c0116134326a7;hpb=fd90abd3f3baa4fc98fa7e3df0e22e9bd3d77d95 diff --git a/src/qtui/chatitem.cpp b/src/qtui/chatitem.cpp index 7a11a665..036a6e62 100644 --- a/src/qtui/chatitem.cpp +++ b/src/qtui/chatitem.cpp @@ -60,11 +60,11 @@ QVariant ChatItem::data(int role) const { return model()->data(index, role); } -qreal ChatItem::setWidth(qreal w) { +qreal ChatItem::setGeometry(qreal w, qreal h) { if(w == _boundingRect.width()) return _boundingRect.height(); prepareGeometryChange(); _boundingRect.setWidth(w); - qreal h = computeHeight(); + if(h < 0) h = computeHeight(); _boundingRect.setHeight(h); if(haveLayout()) updateLayout(); return h;