X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;f=src%2Fqtui%2Fchatline-old.cpp;h=0a0d0dbcf6546edeec34e6e769fff9cbed5beeab;hb=25d9ab403582dc24fffe7d4d38e92754898f7384;hp=017a4792d24199a71f7a2bcb63dcd140b54f0f98;hpb=d1b6499b0b848d4287efae89107576548533502c;p=quassel.git diff --git a/src/qtui/chatline-old.cpp b/src/qtui/chatline-old.cpp index 017a4792..0a0d0dbc 100644 --- a/src/qtui/chatline-old.cpp +++ b/src/qtui/chatline-old.cpp @@ -133,8 +133,8 @@ void ChatLine::setSelection(SelectionMode mode, int start, int end) { } } -uint ChatLine::msgId() const { - return msg.buffer().uid(); +MsgId ChatLine::msgId() const { + return msg.msgId(); } BufferInfo ChatLine::bufferInfo() const { @@ -345,6 +345,7 @@ void ChatLine::draw(QPainter *p, const QPointF &pos) { } QPointF tpos = pos + QPointF(tsWidth + QtUi::style()->sepTsSender() + senderWidth + QtUi::style()->sepSenderText(), 0); qreal h = 0; int l = 0; + if(lineLayouts.count() == 0) return; // how can this happen? rect = QRectF(tpos + QPointF(0, h), QSizeF(textWidth, lineLayouts[l].height)); int offset = 0; foreach(FormatRange fr, textFormat) {